Merge "Account for multiple BOARD_PLAT_PUBLIC[PRIVATE]_SEPOLICY_DIR dirs"
diff --git a/CleanSpec.mk b/CleanSpec.mk
index 043aa60..beca20b 100644
--- a/CleanSpec.mk
+++ b/CleanSpec.mk
@@ -476,6 +476,9 @@
$(call add-clean-step, rm -rf $(TARGET_COMMON_OUT_ROOT)/obj_asan/APPS/*_intermediates/java-source-list)
$(call add-clean-step, rm -rf $(TARGET_COMMON_OUT_ROOT)/obj_asan/JAVA_LIBRARIES/*_intermediates/java-source-list)
+# Remove stale init.noenforce.rc
+$(call add-clean-step, rm -rf $(PRODUCT_OUT)/system/etc/init/gsi/init.noenforce.rc)
+
# ************************************************
# NEWER CLEAN STEPS MUST BE AT THE END OF THE LIST
# ************************************************
diff --git a/core/Makefile b/core/Makefile
index 002e955..882dc9f 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -125,8 +125,12 @@
else
FINAL_VENDOR_DEFAULT_PROPERTIES := ro.vndk.version=$(BOARD_VNDK_VERSION)
endif
+ ifdef BOARD_VNDK_RUNTIME_DISABLE
+ FINAL_VENDOR_DEFAULT_PROPERTIES += ro.vndk.lite=true
+ endif
else
- FINAL_VENDOR_DEFAULT_PROPERTIES :=
+ FINAL_VENDOR_DEFAULT_PROPERTIES := ro.vndk.version=$(PLATFORM_VNDK_VERSION)
+ FINAL_VENDOR_DEFAULT_PROPERTIES += ro.vndk.lite=true
endif
FINAL_VENDOR_DEFAULT_PROPERTIES += \
$(call collapse-pairs, $(PRODUCT_DEFAULT_PROPERTY_OVERRIDES))
diff --git a/core/force_aapt2.mk b/core/force_aapt2.mk
index 6901116..9ca0749 100644
--- a/core/force_aapt2.mk
+++ b/core/force_aapt2.mk
@@ -17,7 +17,7 @@
# Including this makefile will force AAPT2 on if FORCE_AAPT2==true,
# rewriting some properties to convert standard AAPT usage to AAPT2.
-ifeq ($(FORCE_AAPT2),true)
+ifneq ($(FORCE_AAPT2),false)
ifeq ($(LOCAL_USE_AAPT2),)
# Force AAPT2 on
LOCAL_USE_AAPT2 := true
@@ -50,7 +50,6 @@
ifeq (,$(strip $(LOCAL_MANIFEST_FILE)$(LOCAL_FULL_MANIFEST_FILE)))
ifeq (,$(wildcard $(LOCAL_PATH)/AndroidManifest.xml))
# work around missing manifests by creating a default one
- $(call pretty-warning, Missing manifest file)
LOCAL_FULL_MANIFEST_FILE := $(call local-intermediates-dir,COMMON)/DefaultManifest.xml
$(call create-default-manifest-file,$(LOCAL_FULL_MANIFEST_FILE))
endif
diff --git a/target/product/core.mk b/target/product/core.mk
index bbc2b75..90e15db 100644
--- a/target/product/core.mk
+++ b/target/product/core.mk
@@ -46,7 +46,6 @@
ManagedProvisioning \
MtpDocumentsProvider \
PacProcessor \
- libpac \
PrintSpooler \
PrintRecommendationService \
ProxyHandler \
diff --git a/target/product/treble_common.mk b/target/product/treble_common.mk
index 5352e77..7e0e2ae 100644
--- a/target/product/treble_common.mk
+++ b/target/product/treble_common.mk
@@ -76,15 +76,11 @@
PRODUCT_COPY_FILES += \
device/generic/common/nfc/libnfc-nci.conf:system/etc/libnfc-nci.conf
-# Support for the devices with no VNDK enforcing
+# Support for the O-MR1 devices
PRODUCT_COPY_FILES += \
build/make/target/product/vndk/init.gsi.rc:system/etc/init/init.gsi.rc \
- build/make/target/product/vndk/init.noenforce.rc:system/etc/init/gsi/init.noenforce.rc
+ build/make/target/product/vndk/init.vndk-27.rc:system/etc/init/gsi/init.vndk-27.rc
# Name space configuration file for non-enforcing VNDK
PRODUCT_PACKAGES += \
- ld.config.noenforce.txt
-
-# Set current VNDK version for GSI
-PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \
- ro.gsi.vndk.version=$(PLATFORM_VNDK_VERSION)
+ ld.config.vndk_lite.txt
diff --git a/target/product/vndk/init.gsi.rc b/target/product/vndk/init.gsi.rc
index 3e6b1fb..0150b1a 100644
--- a/target/product/vndk/init.gsi.rc
+++ b/target/product/vndk/init.gsi.rc
@@ -1,2 +1,2 @@
-# If ro.vndk.version is not defined, import init.noenforce.rc
-import /system/etc/init/gsi/init.${ro.vndk.version:-noenforce}.rc
+# If ro.vndk.version is not defined, import init.vndk-27.rc.
+import /system/etc/init/gsi/init.vndk-${ro.vndk.version:-27}.rc
diff --git a/target/product/vndk/init.noenforce.rc b/target/product/vndk/init.noenforce.rc
deleted file mode 100644
index 6cf1df7..0000000
--- a/target/product/vndk/init.noenforce.rc
+++ /dev/null
@@ -1,5 +0,0 @@
-on early-init
- # If ro.vndk.version is not set, use ld.config.nonenforce.txt
- export LD_CONFIG_FILE /system/etc/ld.config.noenforce.txt
- # To use current VNDK libs, set ro.vndk.version to system vndk version
- setprop ro.vndk.version ${ro.gsi.vndk.version}
diff --git a/target/product/vndk/init.vndk-27.rc b/target/product/vndk/init.vndk-27.rc
new file mode 100644
index 0000000..d464a2f
--- /dev/null
+++ b/target/product/vndk/init.vndk-27.rc
@@ -0,0 +1,3 @@
+on early-init
+ # Set ro.vndk.version to 27 so that O-MR1-VENDOR can run latest GSI.
+ setprop ro.vndk.version 27