Don't set up the prebuilt apk rule twice.
For apps, we don't want to set up the prebuilt apk rule twice even if
"LOCAL_MULTILIB := both", which for apps really means to set up only the
jni library rules twice. See also build/core/install_jni_libs.mk.
Change-Id: Id0406c3c605c6ede613dba06178a1710590c09b3
diff --git a/core/prebuilt.mk b/core/prebuilt.mk
index ba0e757..d3f9d1a 100644
--- a/core/prebuilt.mk
+++ b/core/prebuilt.mk
@@ -25,6 +25,10 @@
ifneq ($(my_module_multilib),both)
my_skip_non_preferred_arch := true
endif # $(my_module_multilib)
+# For apps, we don't want to set up the prebuilt apk rule twice even if "LOCAL_MULTILIB := both".
+ifeq (APPS,$(LOCAL_MODULE_CLASS))
+my_skip_non_preferred_arch := true
+endif
endif # $(my_module_arch_supported)
ifndef my_skip_non_preferred_arch