2018-02-16 22:41:03 +01:00
|
|
|
#!/system/bin/sh
|
|
|
|
|
|
|
|
grep -oE 'init_[0-9_]+' /vendor/etc/selinux/nonplat_sepolicy.cil | \
|
|
|
|
uniq | \
|
|
|
|
sort -n | \
|
|
|
|
head -n 1 | \
|
|
|
|
sed -E 's/.*init_([0-9]+).*/\1/g' | \
|
|
|
|
while read version;do
|
|
|
|
setprop persist.sys.vndk $version
|
|
|
|
done
|
2018-02-19 00:06:31 +01:00
|
|
|
|
2018-12-03 21:16:52 +01:00
|
|
|
if [ -d /sys/module/five ];then
|
2019-07-17 20:11:56 +02:00
|
|
|
if mount -o bind /system/phh/empty /sbin/adbd;then
|
|
|
|
setprop sys.phh.five true
|
|
|
|
fi
|
2019-07-19 10:18:26 +02:00
|
|
|
elif [ -f /sbin/adbd ];then
|
2018-12-03 21:16:52 +01:00
|
|
|
mount -o bind /system/bin/adbd /sbin/adbd
|
|
|
|
fi
|
2018-05-27 13:14:50 +02:00
|
|
|
if ( getprop ro.hardware | grep -qE '(kirin970|hi3660|hi6250|hi3670)' );then
|
2018-05-02 23:38:24 +02:00
|
|
|
FOUND_HUAWEI=1
|
2018-02-20 23:03:30 +01:00
|
|
|
fi
|
2018-05-02 23:38:24 +02:00
|
|
|
|
2018-12-26 22:54:22 +01:00
|
|
|
if getprop ro.vendor.build.fingerprint |grep -qiE '(huawei|honor|hi3660)';then
|
2018-05-02 23:38:24 +02:00
|
|
|
FOUND_HUAWEI=1
|
|
|
|
fi
|
2018-05-26 13:32:44 +02:00
|
|
|
|
2018-05-27 13:14:50 +02:00
|
|
|
if [ -n "$FOUND_HUAWEI" ];then
|
2018-12-26 22:54:22 +01:00
|
|
|
setprop persist.sys.overlay.huawei true
|
|
|
|
setprop persist.sys.bt_acl_bypass true
|
|
|
|
setprop persist.sys.camera.huawei true
|
2018-11-17 18:47:03 +00:00
|
|
|
setprop persist.sys.radio.ussd.fix true
|
2019-02-17 13:18:57 +01:00
|
|
|
setprop persist.sys.radio.huawei true
|
2018-05-27 13:14:50 +02:00
|
|
|
setprop debug.hwui.profile true
|
|
|
|
fi
|
|
|
|
|
2018-12-21 12:18:01 -05:00
|
|
|
if getprop ro.hardware |grep -qiE -e qcom -e judyln -e judypn;then
|
2018-05-26 13:32:44 +02:00
|
|
|
FOUND_QCOM=1
|
2019-01-25 16:51:31 +01:00
|
|
|
if getprop ro.vendor.build.fingerprint |grep -qiE '^samsung';then
|
|
|
|
setprop persist.sys.overlay.devinputjack false
|
|
|
|
else
|
|
|
|
setprop persist.sys.overlay.devinputjack true
|
|
|
|
fi
|
2018-05-26 13:32:44 +02:00
|
|
|
fi
|