diff --git a/target/board/generic_arm64/device.mk b/target/board/generic_arm64/device.mk index 2004624ca3..e5d8e61d02 100644 --- a/target/board/generic_arm64/device.mk +++ b/target/board/generic_arm64/device.mk @@ -14,15 +14,6 @@ # limitations under the License. # -# NFC: -# Provide default libnfc-nci.conf file for devices that does not have one in -# vendor/etc because aosp system image (of aosp_$arch products) is going to -# be used as GSI. -# May need to remove the following for newly launched devices in P since this -# NFC configuration file should be in vendor/etc, instead of system/etc -PRODUCT_COPY_FILES += \ - device/generic/common/nfc/libnfc-nci.conf:system/etc/libnfc-nci.conf - # Adjust the Dalvik heap to be appropriate for a tablet. $(call inherit-product-if-exists, frameworks/base/build/tablet-dalvik-heap.mk) $(call inherit-product-if-exists, frameworks/native/build/tablet-dalvik-heap.mk) diff --git a/target/board/generic_x86/device.mk b/target/board/generic_x86/device.mk index 0a3241511a..a31058dd31 100644 --- a/target/board/generic_x86/device.mk +++ b/target/board/generic_x86/device.mk @@ -14,11 +14,11 @@ # limitations under the License. # -# NFC: -# Provide default libnfc-nci.conf file for devices that does not have one in -# vendor/etc because aosp system image (of aosp_$arch products) is going to -# be used as GSI. -# May need to remove the following for newly launched devices in P since this -# NFC configuration file should be in vendor/etc, instead of system/etc -PRODUCT_COPY_FILES += \ - device/generic/common/nfc/libnfc-nci.conf:system/etc/libnfc-nci.conf +ifdef NET_ETH0_STARTONBOOT + PRODUCT_PROPERTY_OVERRIDES += net.eth0.startonboot=1 +endif + +# Ensure we package the BIOS files too. +PRODUCT_PACKAGES += \ + bios.bin \ + vgabios-cirrus.bin \ diff --git a/target/board/generic_x86_64/device.mk b/target/board/generic_x86_64/device.mk index 0a3241511a..a31058dd31 100755 --- a/target/board/generic_x86_64/device.mk +++ b/target/board/generic_x86_64/device.mk @@ -14,11 +14,11 @@ # limitations under the License. # -# NFC: -# Provide default libnfc-nci.conf file for devices that does not have one in -# vendor/etc because aosp system image (of aosp_$arch products) is going to -# be used as GSI. -# May need to remove the following for newly launched devices in P since this -# NFC configuration file should be in vendor/etc, instead of system/etc -PRODUCT_COPY_FILES += \ - device/generic/common/nfc/libnfc-nci.conf:system/etc/libnfc-nci.conf +ifdef NET_ETH0_STARTONBOOT + PRODUCT_PROPERTY_OVERRIDES += net.eth0.startonboot=1 +endif + +# Ensure we package the BIOS files too. +PRODUCT_PACKAGES += \ + bios.bin \ + vgabios-cirrus.bin \ diff --git a/target/product/aosp_arm.mk b/target/product/aosp_arm.mk index 98114c15a4..400fa6abf4 100644 --- a/target/product/aosp_arm.mk +++ b/target/product/aosp_arm.mk @@ -21,29 +21,20 @@ # - VNDK enforcement # - compatible property override enabled --include device/generic/goldfish/arm32-vendor.mk +# GSI for system/product +$(call inherit-product, $(SRC_TARGET_DIR)/product/gsi_common.mk) -include $(SRC_TARGET_DIR)/product/full.mk +# Enable mainline checking for excat this product name +ifeq (aosp_arm,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif -# Enable dynamic partition size -PRODUCT_USE_DYNAMIC_PARTITION_SIZE := true - -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier - -# Needed by Pi newly launched device to pass VtsTrebleSysProp on GSI -PRODUCT_COMPATIBLE_PROPERTY_OVERRIDE := true - -# GSI specific tasks on boot -PRODUCT_COPY_FILES += \ - build/make/target/product/gsi/skip_mount.cfg:system/etc/init/config/skip_mount.cfg \ - build/make/target/product/gsi/init.gsi.rc:system/etc/init/init.gsi.rc \ - -# Support addtional P vendor interface -PRODUCT_EXTRA_VNDK_VERSIONS := 28 +# Emulator for vendor +$(call inherit-product-if-exists, device/generic/goldfish/arm32-vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/emulator_vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/board/generic_x86/device.mk) PRODUCT_NAME := aosp_arm +PRODUCT_DEVICE := generic +PRODUCT_BRAND := Android +PRODUCT_MODEL := AOSP on ARM32 diff --git a/target/product/aosp_arm64.mk b/target/product/aosp_arm64.mk index 87e14d7c2e..aa6ec4d0d2 100644 --- a/target/product/aosp_arm64.mk +++ b/target/product/aosp_arm64.mk @@ -26,7 +26,23 @@ # build quite specifically for the emulator, and might not be # entirely appropriate to inherit from for on-device configurations. --include device/generic/goldfish/arm64-vendor.mk +# GSI for system/product +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/gsi_common.mk) + +# Emulator for vendor +$(call inherit-product-if-exists, device/generic/goldfish/arm64-vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/emulator_vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/board/generic_arm64/device.mk) + +# Enable mainline checking for excat this product name +ifeq (aosp_arm64,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif + +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ + root/init.zygote32_64.rc \ + root/init.zygote64_32.rc \ # Copy different zygote settings for vendor.img to select by setting property # ro.zygote=zygote64_32 or ro.zygote=zygote32_64: @@ -36,33 +52,7 @@ PRODUCT_COPY_FILES += \ system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc -$(call inherit-product, $(SRC_TARGET_DIR)/product/emulator.mk) -$(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)/board/generic_arm64/device.mk) - -# Enable dynamic partition size -PRODUCT_USE_DYNAMIC_PARTITION_SIZE := true - -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier - -# Needed by Pi newly launched device to pass VtsTrebleSysProp on GSI -PRODUCT_COMPATIBLE_PROPERTY_OVERRIDE := true - -# GSI specific tasks on boot -PRODUCT_COPY_FILES += \ - build/make/target/product/gsi/skip_mount.cfg:system/etc/init/config/skip_mount.cfg \ - build/make/target/product/gsi/init.gsi.rc:system/etc/init/init.gsi.rc \ - -# Support addtional P vendor interface -PRODUCT_EXTRA_VNDK_VERSIONS := 28 - PRODUCT_NAME := aosp_arm64 PRODUCT_DEVICE := generic_arm64 PRODUCT_BRAND := Android -PRODUCT_MODEL := AOSP on ARM arm64 Emulator +PRODUCT_MODEL := AOSP on ARM64 diff --git a/target/product/aosp_arm64_a.mk b/target/product/aosp_arm64_a.mk index b1c4b7dba2..e45229d08c 100644 --- a/target/product/aosp_arm64_a.mk +++ b/target/product/aosp_arm64_a.mk @@ -19,7 +19,25 @@ # on the generic system image, place them in build/make/target/board/ # gsi_system.prop. -include build/make/target/product/treble_common_64.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) + +# Enable mainline checking for excat this product name +ifeq (aosp_arm64_a,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif + +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ + root/init.zygote32_64.rc \ + root/init.zygote64_32.rc \ + +# Copy different zygote settings for vendor.img to select by setting property +# ro.zygote=zygote64_32 or ro.zygote=zygote32_64: +# 1. 64-bit primary, 32-bit secondary OR +# 2. 32-bit primary, 64-bit secondary +# init.zygote64_32.rc is in the core_64_bit.mk below +PRODUCT_COPY_FILES += \ + system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc 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 92f50553a3..f707a39dd2 100644 --- a/target/product/aosp_arm64_ab.mk +++ b/target/product/aosp_arm64_ab.mk @@ -24,14 +24,25 @@ # - 64 bits binder interface # - system-as-root -include build/make/target/product/treble_common_64.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier +# Enable mainline checking for excat this product name +ifeq (aosp_arm64_ab,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif + +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ + root/init.zygote32_64.rc \ + root/init.zygote64_32.rc \ + +# Copy different zygote settings for vendor.img to select by setting property +# ro.zygote=zygote64_32 or ro.zygote=zygote32_64: +# 1. 64-bit primary, 32-bit secondary OR +# 2. 32-bit primary, 64-bit secondary +# init.zygote64_32.rc is in the core_64_bit.mk below +PRODUCT_COPY_FILES += \ + system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc 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 d89a326c96..249ad2c40e 100644 --- a/target/product/aosp_arm_a.mk +++ b/target/product/aosp_arm_a.mk @@ -19,7 +19,12 @@ # on the generic system image, place them in build/make/target/board/ # gsi_system.prop. -include build/make/target/product/treble_common_32.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) + +# Enable mainline checking for excat this product name +ifeq (aosp_arm_a,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif PRODUCT_NAME := aosp_arm_a PRODUCT_DEVICE := generic_arm_a diff --git a/target/product/aosp_arm_ab.mk b/target/product/aosp_arm_ab.mk index b35e517759..e760932675 100644 --- a/target/product/aosp_arm_ab.mk +++ b/target/product/aosp_arm_ab.mk @@ -24,14 +24,12 @@ # - 32 bits binder interface # - system-as-root -include build/make/target/product/treble_common_32.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier +# Enable mainline checking for excat this product name +ifeq (aosp_arm_ab,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif PRODUCT_NAME := aosp_arm_ab PRODUCT_DEVICE := generic_arm_ab diff --git a/target/product/aosp_x86.mk b/target/product/aosp_x86.mk index 50d7355564..b16b5edde4 100644 --- a/target/product/aosp_x86.mk +++ b/target/product/aosp_x86.mk @@ -21,29 +21,20 @@ # - VNDK enforcement # - compatible property override enabled --include device/generic/goldfish/x86-vendor.mk +# GSI for system/product +$(call inherit-product, $(SRC_TARGET_DIR)/product/gsi_common.mk) -include $(SRC_TARGET_DIR)/product/full_x86.mk +# Emulator for vendor +$(call inherit-product-if-exists, device/generic/goldfish/x86-vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/emulator_vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/board/generic_x86/device.mk) -# Enable dynamic partition size -PRODUCT_USE_DYNAMIC_PARTITION_SIZE := true - -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier - -# Needed by Pi newly launched device to pass VtsTrebleSysProp on GSI -PRODUCT_COMPATIBLE_PROPERTY_OVERRIDE := true - -# GSI specific tasks on boot -PRODUCT_COPY_FILES += \ - build/make/target/product/gsi/skip_mount.cfg:system/etc/init/config/skip_mount.cfg \ - build/make/target/product/gsi/init.gsi.rc:system/etc/init/init.gsi.rc \ - -# Support addtional P vendor interface -PRODUCT_EXTRA_VNDK_VERSIONS := 28 +# Enable mainline checking for excat this product name +ifeq (aosp_x86,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif PRODUCT_NAME := aosp_x86 +PRODUCT_DEVICE := generic_x86 +PRODUCT_BRAND := Android +PRODUCT_MODEL := AOSP on x86 diff --git a/target/product/aosp_x86_64.mk b/target/product/aosp_x86_64.mk index 499831b3ce..f7e205691f 100644 --- a/target/product/aosp_x86_64.mk +++ b/target/product/aosp_x86_64.mk @@ -26,7 +26,23 @@ # build quite specifically for the emulator, and might not be # entirely appropriate to inherit from for on-device configurations. --include device/generic/goldfish/x86_64-vendor.mk +# GSI for system/product +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/gsi_common.mk) + +# Emulator for vendor +$(call inherit-product-if-exists, device/generic/goldfish/x86_64-vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/emulator_vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/board/generic_x86_64/device.mk) + +# Enable mainline checking for excat this product name +ifeq (aosp_x86_64,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif + +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ + root/init.zygote32_64.rc \ + root/init.zygote64_32.rc \ # Copy different zygote settings for vendor.img to select by setting property # ro.zygote=zygote64_32 or ro.zygote=zygote32_64: @@ -36,43 +52,7 @@ PRODUCT_COPY_FILES += \ system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc -$(call inherit-product, $(SRC_TARGET_DIR)/product/emulator.mk) -$(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)/board/generic_x86_64/device.mk) - -# Enable dynamic partition size -PRODUCT_USE_DYNAMIC_PARTITION_SIZE := true - -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier - -# Needed by Pi newly launched device to pass VtsTrebleSysProp on GSI -PRODUCT_COMPATIBLE_PROPERTY_OVERRIDE := true - -# GSI specific tasks on boot -PRODUCT_COPY_FILES += \ - build/make/target/product/gsi/skip_mount.cfg:system/etc/init/config/skip_mount.cfg \ - build/make/target/product/gsi/init.gsi.rc:system/etc/init/init.gsi.rc \ - -# Support addtional P vendor interface -PRODUCT_EXTRA_VNDK_VERSIONS := 28 - -ifdef NET_ETH0_STARTONBOOT - PRODUCT_PROPERTY_OVERRIDES += net.eth0.startonboot=1 -endif - -# Ensure we package the BIOS files too. -PRODUCT_PACKAGES += \ - bios.bin \ - vgabios-cirrus.bin \ - -# Overrides PRODUCT_NAME := aosp_x86_64 PRODUCT_DEVICE := generic_x86_64 PRODUCT_BRAND := Android -PRODUCT_MODEL := AOSP on IA x86_64 Emulator +PRODUCT_MODEL := AOSP on x86_64 diff --git a/target/product/aosp_x86_64_a.mk b/target/product/aosp_x86_64_a.mk index 6b6785a492..f40b9a900b 100644 --- a/target/product/aosp_x86_64_a.mk +++ b/target/product/aosp_x86_64_a.mk @@ -19,7 +19,25 @@ # on the generic system image, place them in build/make/target/board/ # gsi_system.prop. -include build/make/target/product/treble_common_64.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) + +# Enable mainline checking for excat this product name +ifeq (aosp_x86_64_a,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif + +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ + root/init.zygote32_64.rc \ + root/init.zygote64_32.rc \ + +# Copy different zygote settings for vendor.img to select by setting property +# ro.zygote=zygote64_32 or ro.zygote=zygote32_64: +# 1. 64-bit primary, 32-bit secondary OR +# 2. 32-bit primary, 64-bit secondary +# init.zygote64_32.rc is in the core_64_bit.mk below +PRODUCT_COPY_FILES += \ + system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc PRODUCT_NAME := aosp_x86_64_a PRODUCT_DEVICE := generic_x86_64_a diff --git a/target/product/aosp_x86_64_ab.mk b/target/product/aosp_x86_64_ab.mk index 35bf61a1fa..dfb7b49ff5 100644 --- a/target/product/aosp_x86_64_ab.mk +++ b/target/product/aosp_x86_64_ab.mk @@ -24,14 +24,25 @@ # - 64 bits binder interface # - system-as-root -include build/make/target/product/treble_common_64.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier +# Enable mainline checking for excat this product name +ifeq (aosp_x86_64_ab,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif + +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ + root/init.zygote32_64.rc \ + root/init.zygote64_32.rc \ + +# Copy different zygote settings for vendor.img to select by setting property +# ro.zygote=zygote64_32 or ro.zygote=zygote32_64: +# 1. 64-bit primary, 32-bit secondary OR +# 2. 32-bit primary, 64-bit secondary +# init.zygote64_32.rc is in the core_64_bit.mk below +PRODUCT_COPY_FILES += \ + system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc PRODUCT_NAME := aosp_x86_64_ab PRODUCT_DEVICE := generic_x86_64_ab diff --git a/target/product/aosp_x86_a.mk b/target/product/aosp_x86_a.mk index 99ed7e441e..743e0b9bcd 100644 --- a/target/product/aosp_x86_a.mk +++ b/target/product/aosp_x86_a.mk @@ -19,7 +19,12 @@ # on the generic system image, place them in build/make/target/board/ # gsi_system.prop. -include build/make/target/product/treble_common_32.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) + +# Enable mainline checking for excat this product name +ifeq (aosp_x86_a,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif PRODUCT_NAME := aosp_x86_a PRODUCT_DEVICE := generic_x86_a diff --git a/target/product/aosp_x86_ab.mk b/target/product/aosp_x86_ab.mk index 185e2f0a34..d07351cca8 100644 --- a/target/product/aosp_x86_ab.mk +++ b/target/product/aosp_x86_ab.mk @@ -24,14 +24,12 @@ # - 32 bits binder interface # - system-as-root -include build/make/target/product/treble_common_32.mk +$(call inherit-product, $(SRC_TARGET_DIR)/product/legacy_gsi_common.mk) -# Enable A/B update -AB_OTA_UPDATER := true -AB_OTA_PARTITIONS := system -PRODUCT_PACKAGES += \ - update_engine \ - update_verifier +# Enable mainline checking for excat this product name +ifeq (aosp_x86_ab,$(TARGET_PRODUCT)) +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +endif PRODUCT_NAME := aosp_x86_ab PRODUCT_DEVICE := generic_x86_ab diff --git a/target/product/emulator_vendor.mk b/target/product/emulator_vendor.mk new file mode 100644 index 0000000000..f0a5354803 --- /dev/null +++ b/target/product/emulator_vendor.mk @@ -0,0 +1,70 @@ +# +# Copyright (C) 2012 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# +# This file is included by other product makefiles to add all the +# emulator-related modules to PRODUCT_PACKAGES. +# + +$(call inherit-product, $(SRC_TARGET_DIR)/product/handheld_vendor.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/telephony_vendor.mk) + +# TODO(b/123495142): these files should be clean up +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST := \ + system/bin/vintf \ + system/etc/permissions/android.software.verified_boot.xml \ + system/etc/permissions/privapp-permissions-goldfish.xml \ + system/lib/egl/libGLES_android.so \ + system/lib64/egl/libGLES_android.so \ + system/priv-app/SdkSetup/SdkSetup.apk \ + +# Device modules +PRODUCT_PACKAGES += \ + libGLES_android \ + vintf \ + +# need this for gles libraries to load properly +# after moving to /vendor/lib/ +PRODUCT_PACKAGES += \ + vndk-sp + +PRODUCT_PACKAGE_OVERLAYS := device/generic/goldfish/overlay + +PRODUCT_CHARACTERISTICS := emulator + +PRODUCT_FULL_TREBLE_OVERRIDE := true + +# goldfish vendor partition configurations +$(call inherit-product-if-exists, device/generic/goldfish/vendor.mk) + +#watchdog tiggers reboot because location service is not +#responding, disble it for now. +#still keep it on internal master as it is still working +#once it is fixed in aosp, remove this block of comment. +#PRODUCT_DEFAULT_PROPERTY_OVERRIDES += \ +#config.disable_location=true + +# Enable Perfetto traced +PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \ + persist.traced.enable=1 + +# enable Google-specific location features, +# like NetworkLocationProvider and LocationCollector +PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \ + ro.com.google.locationfeatures=1 + +# disable setupwizard +PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \ + ro.setupwizard.mode=DISABLED diff --git a/target/product/gsi_arm64.mk b/target/product/gsi_arm64.mk index cf4babadb7..b711d88c08 100644 --- a/target/product/gsi_arm64.mk +++ b/target/product/gsi_arm64.mk @@ -17,6 +17,8 @@ $(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) $(call inherit-product, $(SRC_TARGET_DIR)/product/gsi_common.mk) +# Enable mainline checking +PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ root/init.zygote32_64.rc \ root/init.zygote64_32.rc \ @@ -33,4 +35,3 @@ PRODUCT_NAME := gsi_arm64 PRODUCT_DEVICE := gsi_arm64 PRODUCT_BRAND := generic PRODUCT_MODEL := GSI on ARM64 - diff --git a/target/product/gsi_common.mk b/target/product/gsi_common.mk index 0006e62cf7..e87309bf1b 100644 --- a/target/product/gsi_common.mk +++ b/target/product/gsi_common.mk @@ -28,15 +28,15 @@ PRODUCT_PROPERTY_OVERRIDES := \ ro.config.ringtone=Ring_Synth_04.ogg \ ro.config.notification_sound=pixiedust.ogg - -# Enable mainline checking and the whitelist for GSI -PRODUCT_ENFORCE_ARTIFACT_PATH_REQUIREMENTS := relaxed +# The mainline checking whitelist, should be clean up PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST := \ system/app/messaging/messaging.apk \ system/app/PhotoTable/PhotoTable.apk \ system/app/WAPPushManager/WAPPushManager.apk \ system/bin/healthd \ system/etc/init/healthd.rc \ + system/etc/seccomp_policy/crash_dump.%.policy \ + system/etc/seccomp_policy/mediacodec.policy \ system/etc/vintf/manifest/manifest_healthd.xml \ system/lib/libframesequence.so \ system/lib/libgiftranscode.so \ @@ -52,9 +52,10 @@ PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ system/etc/init/config/skip_mount.cfg \ system/etc/init/init.gsi.rc \ -# Exclude all files under system/product +# Exclude all files under system/product and system/product_services PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ - system/product/% + system/product/% \ + system/product_services/% # Split selinux policy diff --git a/target/product/legacy_gsi_common.mk b/target/product/legacy_gsi_common.mk new file mode 100644 index 0000000000..fdae6eb16a --- /dev/null +++ b/target/product/legacy_gsi_common.mk @@ -0,0 +1,37 @@ +# +# Copyright (C) 2019 The Android Open-Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +include $(SRC_TARGET_DIR)/product/gsi_common.mk + +PRODUCT_ARTIFACT_PATH_REQUIREMENT_WHITELIST += \ + system/etc/init/init.legacy-gsi.rc \ + system/etc/init/gsi/init.vndk-27.rc \ + system/etc/ld.config.vndk_lite.txt \ + +# Legacy GSI support addtional O-MR1 interface +PRODUCT_EXTRA_VNDK_VERSIONS += 27 + +# Support for the O-MR1 devices +PRODUCT_COPY_FILES += \ + build/make/target/product/gsi/init.legacy-gsi.rc:system/etc/init/init.legacy-gsi.rc \ + build/make/target/product/gsi/init.vndk-27.rc:system/etc/init/gsi/init.vndk-27.rc + +# Name space configuration file for non-enforcing VNDK +PRODUCT_PACKAGES += \ + ld.config.vndk_lite.txt + +# Legacy GSI relax the compatible property checking +PRODUCT_COMPATIBLE_PROPERTY_OVERRIDE := false diff --git a/target/product/treble_common.mk b/target/product/treble_common.mk deleted file mode 100644 index 7e4a98e984..0000000000 --- a/target/product/treble_common.mk +++ /dev/null @@ -1,63 +0,0 @@ -# -# Copyright (C) 2017 The Android Open-Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# PRODUCT_PROPERTY_OVERRIDES cannot be used here because sysprops will be at -# /vendor/[build|default].prop when build split is on. In order to have sysprops -# on the generic system image, place them in build/make/target/board/ -# treble_system.prop. - -# Generic system image inherits from AOSP with telephony -$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base.mk) -$(call inherit-product, $(SRC_TARGET_DIR)/product/telephony.mk) - -# Enable dynamic partition size -PRODUCT_USE_DYNAMIC_PARTITION_SIZE := true - -# Split selinux policy -PRODUCT_FULL_TREBLE_OVERRIDE := true - -# The Messaging app: -# Needed for android.telecom.cts.ExtendedInCallServiceTest#testOnCannedTextResponsesLoaded -PRODUCT_PACKAGES += \ - messaging - -# Telephony: -# Provide a default APN configuration -PRODUCT_COPY_FILES += \ - device/sample/etc/apns-full-conf.xml:system/etc/apns-conf.xml - -# NFC: -# Provide default libnfc-nci.conf file for devices that does not have one in -# vendor/etc -PRODUCT_COPY_FILES += \ - device/generic/common/nfc/libnfc-nci.conf:system/etc/libnfc-nci.conf - -# GSI specific tasks on boot -PRODUCT_COPY_FILES += \ - build/make/target/product/gsi/skip_mount.cfg:system/etc/init/config/skip_mount.cfg \ - build/make/target/product/gsi/init.gsi.rc:system/etc/init/init.gsi.rc \ - -# Support for the O-MR1 devices -PRODUCT_COPY_FILES += \ - build/make/target/product/gsi/init.legacy-gsi.rc:system/etc/init/init.legacy-gsi.rc \ - build/make/target/product/gsi/init.vndk-27.rc:system/etc/init/gsi/init.vndk-27.rc - -# Name space configuration file for non-enforcing VNDK -PRODUCT_PACKAGES += \ - ld.config.vndk_lite.txt - -# Support addtional O-MR1 and P vendor interface -PRODUCT_EXTRA_VNDK_VERSIONS := 27 28 diff --git a/target/product/treble_common_32.mk b/target/product/treble_common_32.mk deleted file mode 100644 index 0023c3b6e8..0000000000 --- a/target/product/treble_common_32.mk +++ /dev/null @@ -1,22 +0,0 @@ -# -# Copyright (C) 2017 The Android Open-Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# PRODUCT_PROPERTY_OVERRIDES cannot be used here because sysprops will be at -# /vendor/[build|default].prop when build split is on. In order to have sysprops -# on the generic system image, place them in build/make/target/board/ -# treble_system.prop. - -include build/make/target/product/treble_common.mk diff --git a/target/product/treble_common_64.mk b/target/product/treble_common_64.mk deleted file mode 100644 index fc3c16f8c2..0000000000 --- a/target/product/treble_common_64.mk +++ /dev/null @@ -1,37 +0,0 @@ -# -# Copyright (C) 2017 The Android Open-Source Project -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -# PRODUCT_PROPERTY_OVERRIDES cannot be used here because sysprops will be at -# /vendor/[build|default].prop when build split is on. In order to have sysprops -# on the generic system image, place them in build/make/target/board/ -# treble_system.prop. - -include build/make/target/product/treble_common.mk - -# For now this will allow 64-bit apps, but still compile all apps with JNI -# for 32-bit only. - -# Copy different zygote settings for vendor.img to select by setting property -# ro.zygote=zygote64_32 or ro.zygote=zygote32_64: -# 1. 64-bit primary, 32-bit secondary OR -# 2. 32-bit primary, 64-bit secondary -# 3. 64-bit only is currently forbidden (b/64280459#comment6) -PRODUCT_COPY_FILES += \ - system/core/rootdir/init.zygote64_32.rc:root/init.zygote64_32.rc \ - system/core/rootdir/init.zygote32_64.rc:root/init.zygote32_64.rc - -TARGET_SUPPORTS_32_BIT_APPS := true -TARGET_SUPPORTS_64_BIT_APPS := true