Merge "Delay the write-back of misc_info in sign_target_files_apks.py." into oc-dr1-dev
diff --git a/core/Makefile b/core/Makefile
index bcd1abd..fadcae0 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -78,8 +78,13 @@
endif
# -----------------------------------------------------------------
-# default.prop
+# prop.default
+ifdef property_overrides_split_enabled
+INSTALLED_DEFAULT_PROP_TARGET := $(TARGET_OUT)/etc/prop.default
+else
+# legacy path
INSTALLED_DEFAULT_PROP_TARGET := $(TARGET_ROOT_OUT)/default.prop
+endif
ALL_DEFAULT_INSTALLED_MODULES += $(INSTALLED_DEFAULT_PROP_TARGET)
FINAL_DEFAULT_PROPERTIES := \
$(call collapse-pairs, $(ADDITIONAL_DEFAULT_PROPERTIES))
@@ -95,6 +100,7 @@
$(INSTALLED_DEFAULT_PROP_TARGET): $(intermediate_system_build_prop)
@echo Target buildinfo: $@
@mkdir -p $(dir $@)
+ @rm -f $@
$(hide) echo "#" > $@; \
echo "# ADDITIONAL_DEFAULT_PROPERTIES" >> $@; \
echo "#" >> $@;
@@ -107,6 +113,10 @@
$(hide) echo ro.bootimage.build.date.utc=`$(DATE_FROM_FILE) +%s`>>$@
$(hide) echo ro.bootimage.build.fingerprint="$(BUILD_FINGERPRINT_FROM_FILE)">>$@
$(hide) build/tools/post_process_props.py $@
+ifdef property_overrides_split_enabled
+ $(hide) mkdir -p $(TARGET_ROOT_OUT)
+ $(hide) ln -sf system/etc/prop.default $(TARGET_ROOT_OUT)/default.prop
+endif
# -----------------------------------------------------------------
# vendor default.prop
@@ -1196,12 +1206,13 @@
$(hide) cp -f $(recovery_wipe) $(TARGET_RECOVERY_ROOT_OUT)/etc/recovery.wipe)
$(hide) cp $(RECOVERY_INSTALL_OTA_KEYS) $(TARGET_RECOVERY_ROOT_OUT)/res/keys
$(hide) cat $(INSTALLED_DEFAULT_PROP_TARGET) \
- > $(TARGET_RECOVERY_ROOT_OUT)/default.prop
+ > $(TARGET_RECOVERY_ROOT_OUT)/prop.default
$(if $(INSTALLED_VENDOR_DEFAULT_PROP_TARGET), \
$(hide) cat $(INSTALLED_VENDOR_DEFAULT_PROP_TARGET) \
- >> $(TARGET_RECOVERY_ROOT_OUT)/default.prop)
+ >> $(TARGET_RECOVERY_ROOT_OUT)/prop.default)
$(hide) cat $(recovery_build_props) \
- >> $(TARGET_RECOVERY_ROOT_OUT)/default.prop
+ >> $(TARGET_RECOVERY_ROOT_OUT)/prop.default
+ $(hide) ln -sf prop.default $(TARGET_RECOVERY_ROOT_OUT)/default.prop
$(BOARD_RECOVERY_IMAGE_PREPARE)
$(if $(filter true,$(BOARD_BUILD_SYSTEM_ROOT_IMAGE)), \
$(hide) mkdir -p $(TARGET_RECOVERY_ROOT_OUT)/system_root; \
diff --git a/target/product/aosp_arm64_a.mk b/target/product/aosp_arm64_a.mk
index 535b3a4..4258f04 100644
--- a/target/product/aosp_arm64_a.mk
+++ b/target/product/aosp_arm64_a.mk
@@ -23,7 +23,6 @@
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base_telephony.mk)
-$(call inherit-product, $(SRC_TARGET_DIR)/product/verity.mk)
PRODUCT_NAME := aosp_arm64_a
PRODUCT_DEVICE := generic_arm64_a
diff --git a/target/product/aosp_arm64_ab.mk b/target/product/aosp_arm64_ab.mk
index fe3afb7..ae50c42 100644
--- a/target/product/aosp_arm64_ab.mk
+++ b/target/product/aosp_arm64_ab.mk
@@ -29,7 +29,6 @@
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base_telephony.mk)
-$(call inherit-product, $(SRC_TARGET_DIR)/product/verity.mk)
PRODUCT_NAME := aosp_arm64_ab
PRODUCT_DEVICE := generic_arm64_ab
diff --git a/target/product/aosp_arm_a.mk b/target/product/aosp_arm_a.mk
index c3188e0..6be8e82 100644
--- a/target/product/aosp_arm_a.mk
+++ b/target/product/aosp_arm_a.mk
@@ -22,7 +22,6 @@
include build/make/target/product/treble_common.mk
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base_telephony.mk)
-$(call inherit-product, $(SRC_TARGET_DIR)/product/verity.mk)
PRODUCT_NAME := aosp_arm_a
PRODUCT_DEVICE := generic_arm_a
diff --git a/target/product/treble_common.mk b/target/product/treble_common.mk
index ebedb3f..a4bcad6 100644
--- a/target/product/treble_common.mk
+++ b/target/product/treble_common.mk
@@ -72,6 +72,8 @@
android.hardware.radio.deprecated@1.0 \
android.hardware.sensors@1.0 \
android.hardware.soundtrigger@2.0 \
+ android.hardware.tetheroffload.config@1.0 \
+ android.hardware.tetheroffload.control@1.0 \
android.hardware.thermal@1.0 \
android.hardware.tv.cec@1.0 \
android.hardware.tv.input@1.0 \
@@ -187,8 +189,6 @@
libsync \
libvulkan \
-PRODUCT_SYSTEM_VERITY_PARTITION := /dev/block/bootdevice/by-name/system
-
# Audio:
USE_XML_AUDIO_POLICY_CONF := 1
# The following policy XML files are used as fallback for
diff --git a/tools/post_process_props.py b/tools/post_process_props.py
index 83c6f9a..9355e4b 100755
--- a/tools/post_process_props.py
+++ b/tools/post_process_props.py
@@ -35,7 +35,7 @@
def mangle_default_prop_override(prop):
pass
-# Put the modifications that you need to make into the /default.prop into this
+# Put the modifications that you need to make into the /system/etc/prop.default into this
# function. The prop object has get(name) and put(name,value) methods.
def mangle_default_prop(prop):
# If ro.debuggable is 1, then enable adb on USB by default
@@ -122,7 +122,8 @@
elif (filename.endswith("/vendor/default.prop") or
filename.endswith("/odm/default.prop")):
mangle_default_prop_override(properties)
- elif filename.endswith("/default.prop"):
+ elif (filename.endswith("/default.prop") or # legacy
+ filename.endswith("/prop.default")):
mangle_default_prop(properties)
else:
sys.stderr.write("bad command line: " + str(argv) + "\n")
diff --git a/tools/releasetools/sign_target_files_apks.py b/tools/releasetools/sign_target_files_apks.py
index cabceec..9cdaa18 100755
--- a/tools/releasetools/sign_target_files_apks.py
+++ b/tools/releasetools/sign_target_files_apks.py
@@ -212,11 +212,17 @@
# System properties.
elif info.filename in ("SYSTEM/build.prop",
"VENDOR/build.prop",
- "BOOT/RAMDISK/default.prop",
- "ROOT/default.prop",
- "RECOVERY/RAMDISK/default.prop"):
+ "SYSTEM/etc/prop.default",
+ "BOOT/RAMDISK/prop.default",
+ "BOOT/RAMDISK/default.prop", # legacy
+ "ROOT/default.prop", # legacy
+ "RECOVERY/RAMDISK/prop.default",
+ "RECOVERY/RAMDISK/default.prop"): # legacy
print "rewriting %s:" % (info.filename,)
- new_data = RewriteProps(data, misc_info)
+ if stat.S_ISLNK(info.external_attr >> 16):
+ new_data = data
+ else:
+ new_data = RewriteProps(data, misc_info)
common.ZipWriteStr(output_tf_zip, out_info, new_data)
elif info.filename.endswith("mac_permissions.xml"):