From 1936b6256e0fd3d58601f425372f5f680d192dd5 Mon Sep 17 00:00:00 2001 From: Pierre-Hugues Husson Date: Sat, 19 May 2018 13:40:50 +0200 Subject: [PATCH] Include consumerir feature, disable dynamically if not present --- base.mk | 4 ++-- rw-system.sh | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/base.mk b/base.mk index 993c762..bacc80a 100644 --- a/base.mk +++ b/base.mk @@ -1,8 +1,8 @@ #Huawei devices don't declare fingerprint and telephony hardware feature -#TODO: Proper detection 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 + frameworks/native/data/etc/android.hardware.telephony.gsm.xml:system/etc/permissions/android.hardware.telephony.gsm.xml \ + frameworks/native/data/etc/android.hardware.consumerir.xml:system/etc/permissions/android.hardware.consumerir.xml #Use a more decent APN config PRODUCT_COPY_FILES += \ diff --git a/rw-system.sh b/rw-system.sh index 1e25e2d..8f63bed 100644 --- a/rw-system.sh +++ b/rw-system.sh @@ -53,6 +53,10 @@ if ! grep android.hardware.biometrics.fingerprint /vendor/manifest.xml;then mount -o bind system/phh/empty /system/etc/permissions/android.hardware.fingerprint.xml fi +if ! grep android.hardware.ir /vendor/manifest.xml;then + mount -o bind system/phh/empty /system/etc/permissions/android.hardware.consumerir.xml +fi + #Disable trustkernel keystore, because it doesn't work for the moment #Found on MTK devices mount -o bind /system/phh/empty /vendor/lib/hw/keystore.trustkernel.so || true