diff --git a/Changes.md b/Changes.md index 2720a0f40..453ea6c7e 100644 --- a/Changes.md +++ b/Changes.md @@ -1,5 +1,18 @@ # Build System Changes for Android.mk Writers +## ELF prebuilts in PRODUCT_COPY_FILES + +ELF prebuilts in PRODUCT_COPY_FILES that are installed into these paths are an +error: + +* `/bin/*` +* `/lib/*` +* `/lib64/*` + +Define prebuilt modules and add them to PRODUCT_PACKAGES instead. +To temporarily relax this check and restore the behavior prior to this change, +set `BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES := true` in `BoardConfig.mk`. + ## COPY_HEADERS usage now produces warnings {#copy_headers} We've considered `BUILD_COPY_HEADERS`/`LOCAL_COPY_HEADERS` to be deprecated for diff --git a/core/Makefile b/core/Makefile index 69ee80ff1..f09c75bd7 100644 --- a/core/Makefile +++ b/core/Makefile @@ -40,11 +40,9 @@ $(if $(filter true,$(BUILD_BROKEN_VINTF_PRODUCT_COPY_FILES)),, \ ) endef -# TODO(b/140560012): Flip BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES to default -# false after all problematic devices are tagged. -check_elf_prebuilt_product_copy_files := -ifneq (,$(filter false,$(BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES))) check_elf_prebuilt_product_copy_files := true +ifneq (,$(filter true,$(BUILD_BROKEN_ELF_PREBUILT_PRODUCT_COPY_FILES))) +check_elf_prebuilt_product_copy_files := endif check_elf_prebuilt_product_copy_files_hint := \ found ELF prebuilt in PRODUCT_COPY_FILES, use cc_prebuilt_binary / cc_prebuilt_library_shared instead.