device_phh_treble/base.mk

255 lines
10 KiB
Makefile
Raw Normal View History

#Huawei devices don't declare fingerprint and telephony hardware feature
#TODO: Proper detection
2017-12-17 16:46:37 +00:00
PRODUCT_COPY_FILES := \
frameworks/native/data/etc/android.hardware.fingerprint.xml:system/etc/permissions/android.hardware.fingerprint.xml \
frameworks/native/data/etc/android.hardware.telephony.gsm.xml:system/etc/permissions/android.hardware.telephony.gsm.xml \
2020-04-28 15:34:06 +00:00
frameworks/native/data/etc/android.hardware.telephony.ims.xml:system/etc/permissions/android.hardware.telephony.ims.xml \
frameworks/native/data/etc/android.hardware.bluetooth.xml:system/etc/permissions/android.hardware.bluetooth.xml \
frameworks/native/data/etc/android.hardware.bluetooth_le.xml:system/etc/permissions/android.hardware.bluetooth_le.xml \
frameworks/native/data/etc/android.hardware.usb.host.xml:system/etc/permissions/android.hardware.usb.host.xml \
2017-12-17 16:46:37 +00:00
gsi: Initial implementation of sysbta, a system-side bluetooth audio HAL On platform release T, the legacy `audio.a2dp.default` HAL no longer exists, and cannot be trivially restored for generic system-side A2DP audio support. Rather than trying to cling on to its existence (which does not even work anymore even if one did so), it is time to come up with a new solution. This commit introduces a system-side implementation of the generic bluetooth audio HAL. The HAL itself is modelled after the default bluetooth audio HAL, while substantial components of the default audio HAL are also included as it has to also implement the audio HAL interfaces. The audio HAL implementation is delegated to `audio.sysbta.default`, forked from `audio.bluetooth.default` from the Bluetooth apex package. It then communicates with the bluetooth audio HAL interfaces, which need to live in the same process (in this case, the process of the sysbta HAL). This is why we cannot just load `audio.sysbta.default` into the default audio HAL or the audioserver process directly, but rather have to include our own simplistic audio HAL implementation. For now, the audio HAL implementation only includes one for the 6.0 version, but technically, an interface for *every* audio HAL version needs to exist. This, along with other messiness in the sysbta implementation, will be addressed in a future commit. Note that to actually make use of the sysbta audio hal, patches in frameworks/av and packages/modules/Bluetooth are required to introduce support for the property `persist.bluetooth.system_audio_hal.enabled`.
2022-08-24 19:47:06 +00:00
# Bluetooth Audio (System-side HAL, sysbta)
PRODUCT_PACKAGES += \
audio.sysbta.default \
android.hardware.bluetooth.audio-service-system
PRODUCT_COPY_FILES += \
device/phh/treble/bluetooth/audio/config/sysbta_audio_policy_configuration.xml:$(TARGET_COPY_OUT_SYSTEM)/etc/sysbta_audio_policy_configuration.xml \
device/phh/treble/bluetooth/audio/config/sysbta_audio_policy_configuration_7_0.xml:$(TARGET_COPY_OUTY_SYSTEM)/etc/sysbta_audio_policy_configuration_7_0.xml
2017-12-17 16:46:37 +00:00
#Use a more decent APN config
PRODUCT_COPY_FILES += \
2017-12-17 16:46:37 +00:00
device/sample/etc/apns-full-conf.xml:system/etc/apns-conf.xml
BOARD_PLAT_PRIVATE_SEPOLICY_DIR += device/phh/treble/sepolicy
PRODUCT_PACKAGE_OVERLAYS += device/phh/treble/overlay
2017-12-17 16:46:37 +00:00
$(call inherit-product, vendor/hardware_overlay/overlay.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base_telephony.mk)
#Those overrides are here because Huawei's init read properties
#from /system/etc/prop.default, then /vendor/build.prop, then /system/build.prop
#So we need to set our props in prop.default
PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \
ro.build.version.sdk=$(PLATFORM_SDK_VERSION) \
ro.build.version.codename=$(PLATFORM_VERSION_CODENAME) \
ro.build.version.all_codenames=$(PLATFORM_VERSION_ALL_CODENAMES) \
ro.build.version.release=$(PLATFORM_VERSION) \
ro.build.version.security_patch=$(PLATFORM_SECURITY_PATCH) \
ro.adb.secure=0 \
ro.logd.auditd=true
#Huawei HiSuite (also other OEM custom programs I guess) it's of no use in AOSP builds
PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \
persist.sys.usb.config=adb \
ro.cust.cdrom=/dev/null
2018-02-14 21:05:41 +00:00
#VNDK config files
PRODUCT_COPY_FILES += \
device/phh/treble/vndk-detect:system/bin/vndk-detect \
2018-02-14 21:05:41 +00:00
device/phh/treble/vndk.rc:system/etc/init/vndk.rc \
#USB Audio
PRODUCT_COPY_FILES += \
2021-03-28 16:55:25 +00:00
frameworks/av/services/audiopolicy/config/usb_audio_policy_configuration.xml:system/etc/usb_audio_policy_configuration.xml \
device/phh/treble/files/fake_audio_policy_volume.xml:system/etc/fake_audio_policy_volume.xml \
# NFC:
# Provide default libnfc-nci.conf file for devices that does not have one in
# vendor/etc
PRODUCT_COPY_FILES += \
2019-01-08 13:39:22 +00:00
device/phh/treble/nfc/libnfc-nci.conf:system/phh/libnfc-nci-oreo.conf \
device/phh/treble/nfc/libnfc-nci-huawei.conf:system/phh/libnfc-nci-huawei.conf
# LineageOS build may need this to make NFC work
PRODUCT_PACKAGES += \
NfcNci \
PRODUCT_COPY_FILES += \
device/phh/treble/rw-system.sh:system/bin/rw-system.sh \
device/phh/treble/phh-on-data.sh:system/bin/phh-on-data.sh \
device/phh/treble/phh-prop-handler.sh:system/bin/phh-prop-handler.sh \
device/phh/treble/fixSPL/getSPL.arm:system/bin/getSPL
PRODUCT_COPY_FILES += \
device/phh/treble/empty:system/phh/empty \
device/phh/treble/phh-on-boot.sh:system/bin/phh-on-boot.sh
PRODUCT_PACKAGES += \
treble-environ-rc \
2018-05-26 11:30:17 +00:00
2018-06-06 13:28:28 +00:00
PRODUCT_PACKAGES += \
bootctl \
vintf \
# Fix Offline Charging on Huawmeme
PRODUCT_PACKAGES += \
huawei-charger
PRODUCT_COPY_FILES += \
$(call find-copy-subdir-files,*,device/phh/treble/huawei_charger/files,system/etc/charger)
PRODUCT_COPY_FILES += \
device/phh/treble/twrp/twrp.rc:system/etc/init/twrp.rc \
device/phh/treble/twrp/twrp.sh:system/bin/twrp.sh \
2018-07-23 19:37:40 +00:00
device/phh/treble/twrp/busybox-armv7l:system/bin/busybox_phh
2018-08-16 15:00:28 +00:00
PRODUCT_PACKAGES += \
2020-05-09 18:02:48 +00:00
simg2img_simple \
lptools
2018-08-16 15:29:55 +00:00
ifneq (,$(wildcard external/exfat))
2018-08-16 15:00:28 +00:00
PRODUCT_PACKAGES += \
mkfs.exfat \
fsck.exfat
endif
PRODUCT_PACKAGES += \
android.hidl.manager-V1.0-java \
2018-09-09 22:32:11 +00:00
android.hardware.wifi.hostapd-V1.0-java \
vendor.huawei.hardware.biometrics.fingerprint-V2.1-java \
vendor.huawei.hardware.tp-V1.0-java \
vendor.qti.hardware.radio.am-V1.0-java \
vendor.qti.qcril.am-V1.0-java \
vendor.xiaomi.hardware.displayfeature-V1.0-java
PRODUCT_COPY_FILES += \
device/phh/treble/interfaces.xml:system/etc/permissions/interfaces.xml
PRODUCT_COPY_FILES += \
device/phh/treble/files/samsung-gpio_keys.kl:system/phh/samsung-gpio_keys.kl \
2018-09-09 22:32:11 +00:00
device/phh/treble/files/samsung-sec_touchscreen.kl:system/phh/samsung-sec_touchscreen.kl \
device/phh/treble/files/samsung-sec_touchkey.kl:system/phh/samsung-sec_touchkey.kl \
2018-09-09 22:32:11 +00:00
device/phh/treble/files/oneplus6-synaptics_s3320.kl:system/phh/oneplus6-synaptics_s3320.kl \
device/phh/treble/files/huawei-fingerprint.kl:system/phh/huawei/fingerprint.kl \
device/phh/treble/files/samsung-sec_e-pen.idc:system/usr/idc/sec_e-pen.idc \
device/phh/treble/files/samsung-9810-floating_feature.xml:system/ph/sam-9810-flo_feat.xml \
2019-10-26 19:05:56 +00:00
device/phh/treble/files/mimix3-gpio-keys.kl:system/phh/mimix3-gpio-keys.kl \
2019-11-01 17:30:18 +00:00
device/phh/treble/files/nokia-soc_gpio_keys.kl:system/phh/nokia-soc_gpio_keys.kl \
device/phh/treble/files/lenovo-synaptics_dsx.kl:system/phh/lenovo-synaptics_dsx.kl \
device/phh/treble/files/oppo-touchpanel.kl:system/phh/oppo-touchpanel.kl \
2020-02-27 13:46:38 +00:00
device/phh/treble/files/google-uinput-fpc.kl:system/phh/google-uinput-fpc.kl \
device/phh/treble/files/moto-uinput-egis.kl:system/phh/moto-uinput-egis.kl \
device/phh/treble/files/daisy-buttonJack.kl:system/phh/daisy-buttonJack.kl \
device/phh/treble/files/daisy-uinput-fpc.kl:system/phh/daisy-uinput-fpc.kl \
2020-06-20 18:11:04 +00:00
device/phh/treble/files/daisy-uinput-goodix.kl:system/phh/daisy-uinput-goodix.kl \
2020-08-05 18:38:12 +00:00
device/phh/treble/files/nubia-nubia_synaptics_dsx.kl:system/phh/nubia-nubia_synaptics_dsx.kl \
device/phh/treble/files/unihertz-mtk-kpd.kl:system/phh/unihertz-mtk-kpd.kl \
device/phh/treble/files/unihertz-mtk-tpd.kl:system/phh/unihertz-mtk-tpd.kl \
device/phh/treble/files/unihertz-mtk-tpd-kpd.kl:system/phh/unihertz-mtk-tpd-kpd.kl \
device/phh/treble/files/unihertz-fingerprint_key.kl:system/phh/unihertz-fingerprint_key.kl \
2020-08-05 18:38:12 +00:00
device/phh/treble/files/zf6-goodixfp.kl:system/phh/zf6-goodixfp.kl \
device/phh/treble/files/zf6-googlekey_input.kl:system/phh/zf6-googlekey_input.kl \
2021-04-16 11:23:32 +00:00
device/phh/treble/files/teracube2e-mtk-kpd.kl:system/phh/teracube2e-mtk-kpd.kl \
2021-11-15 06:00:07 +00:00
device/phh/treble/files/bv9500plus-mtk-kpd.kl:system/phh/bv9500plus-mtk-kpd.kl \
2022-07-07 16:12:53 +00:00
device/phh/treble/files/moto-liber-gpio-keys.kl:system/phh/moto-liber-gpio-keys.kl \
device/phh/treble/files/tecno-touchpanel.kl:system/phh/tecno-touchpanel.kl \
device/phh/treble/files/rosemary-excluded-input-devices.xml:system/phh/rosemary-excluded-input-devices.xml
2018-09-09 22:32:11 +00:00
SELINUX_IGNORE_NEVERALLOWS := true
2018-10-21 22:11:36 +00:00
# Universal NoCutoutOverlay
PRODUCT_PACKAGES += \
NoCutoutOverlay
PRODUCT_PACKAGES += \
lightsctl \
2022-05-09 21:37:15 +00:00
lightsctl-aidl \
uevent
PRODUCT_COPY_FILES += \
device/phh/treble/files/adbd.rc:system/etc/init/adbd.rc
#MTK incoming SMS fix
PRODUCT_PACKAGES += \
mtk-sms-fwk-ready
2019-03-14 11:59:54 +00:00
# Helper to debug Xiaomi motorized camera
PRODUCT_PACKAGES += \
2020-04-05 11:15:49 +00:00
xiaomi-motor \
oneplus-motor
2019-03-14 11:59:54 +00:00
PRODUCT_PACKAGES += \
Stk
PRODUCT_PACKAGES += \
resetprop_phh
PRODUCT_COPY_FILES += \
device/phh/treble/phh-securize.sh:system/bin/phh-securize.sh \
2020-06-06 16:12:37 +00:00
device/phh/treble/files/ota.sh:system/bin/ota.sh \
PRODUCT_COPY_FILES += \
device/phh/treble/remove-telephony.sh:system/bin/remove-telephony.sh \
PRODUCT_COPY_FILES += \
frameworks/native/data/etc/android.software.secure_lock_screen.xml:system/etc/permissions/android.software.secure_lock_screen.xml \
device/phh/treble/files/android.software.controls.xml:system/etc/permissions/android.software.controls.xml \
PRODUCT_COPY_FILES += \
device/phh/treble/ld.config.26.txt:system/etc/ld.config.26.txt \
PRODUCT_PACKAGES += \
asus-motor
# Privapp-permissions whitelist for PhhTrebleApp
PRODUCT_COPY_FILES += \
device/phh/treble/privapp-permissions-me.phh.treble.app.xml:system/etc/permissions/privapp-permissions-me.phh.treble.app.xml
# Remote debugging
PRODUCT_COPY_FILES += \
device/phh/treble/remote/dbclient:system/bin/dbclient \
device/phh/treble/remote/phh-remotectl.rc:system/etc/init/phh-remotectl.rc \
device/phh/treble/remote/phh-remotectl.sh:system/bin/phh-remotectl.sh \
PRODUCT_PACKAGES += \
android.hardware.biometrics.fingerprint@2.1-service.oppo.compat \
android.hardware.biometrics.fingerprint@2.1-service.oplus.compat \
PRODUCT_PACKAGES += \
2020-06-06 16:12:37 +00:00
vr_hwc \
curl \
healthd \
PRODUCT_SYSTEM_DEFAULT_PROPERTIES += \
debug.fdsan=warn_once \
ro.apex.updatable=false \
2021-11-03 21:42:09 +00:00
persist.sys.fflag.override.settings_provider_model=false \
ro.setupwizard.mode=OPTIONAL \
PRODUCT_PRODUCT_PROPERTIES += \
ro.setupwizard.mode=OPTIONAL \
# AOSP overlays
PRODUCT_PACKAGES += \
NavigationBarMode2ButtonOverlay
2022-06-07 09:10:57 +00:00
# ThemePicker
PRODUCT_PACKAGES += \
ThemePicker
PRODUCT_PACKAGES += \
oplus-alert-slider
2021-10-13 15:00:32 +00:00
PRODUCT_COPY_FILES += \
device/phh/treble/empty:system/etc/smartpa_params/empty \
device/phh/treble/proprietary-files/gome/fs16xx_01s_left.preset:system/phh/gome/fs16xx_01s_left.preset \
device/phh/treble/proprietary-files/gome/fs16xx_01s_mono.preset:system/phh/gome/fs16xx_01s_mono.preset \
device/phh/treble/proprietary-files/gome/fs16xx_01s_right.preset:system/phh/gome/fs16xx_01s_right.preset \
device/phh/treble/proprietary-files/umidigi/fs16xx_01s_mono.preset:system/phh/umidigi/fs16xx_01s_mono.preset
PRODUCT_PACKAGES += phh-ota
PRODUCT_PACKAGES += \
xiaomi-touch
2022-04-05 19:07:53 +00:00
PRODUCT_COPY_FILES += \
frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration_7_0.xml:system/etc/a2dp_audio_policy_configuration_7_0.xml \
frameworks/av/services/audiopolicy/config/a2dp_audio_policy_configuration.xml:system/etc/a2dp_audio_policy_configuration.xml \
2021-10-13 15:00:32 +00:00
include build/make/target/product/gsi_release.mk
# Protect deskclock from power save
PRODUCT_COPY_FILES += \
device/phh/treble/files/com.android.deskclock_whitelist.xml:system/etc/sysconfig/com.android.deskclock_whitelist.xml