2018-02-16 21:41:03 +00: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-18 23:06:31 +00:00
|
|
|
|
|
|
|
mount -o bind /system/bin/adbd /sbin/adbd
|
2018-05-27 11:14:50 +00:00
|
|
|
if ( getprop ro.hardware | grep -qE '(kirin970|hi3660|hi6250|hi3670)' );then
|
2018-05-02 21:38:24 +00:00
|
|
|
FOUND_HUAWEI=1
|
2018-02-20 22:03:30 +00:00
|
|
|
setprop persist.sys.bt_acl_bypass true
|
2018-09-25 12:56:06 +00:00
|
|
|
setprop persist.sys.camera.huawei true
|
|
|
|
setprop persist.sys.radio.huawei true
|
2018-02-20 22:03:30 +00:00
|
|
|
fi
|
2018-05-02 21:38:24 +00:00
|
|
|
|
|
|
|
if getprop ro.vendor.build.fingerprint |grep -qiE '(huawei|honor|hi3660)' || [ -n "$FOUND_HUAWEI" ];then
|
|
|
|
FOUND_HUAWEI=1
|
2018-05-27 11:16:13 +00:00
|
|
|
setprop persist.sys.overlay.huawei true
|
2018-05-02 21:38:24 +00:00
|
|
|
fi
|
2018-05-26 11:32:44 +00:00
|
|
|
|
2018-05-27 11:14:50 +00:00
|
|
|
if [ -n "$FOUND_HUAWEI" ];then
|
|
|
|
setprop debug.hwui.profile true
|
|
|
|
fi
|
|
|
|
|
2018-09-19 12:55:16 +00:00
|
|
|
if getprop ro.hardware |grep -qiE -e qcom -e judyln;then
|
2018-05-26 11:32:44 +00:00
|
|
|
FOUND_QCOM=1
|
|
|
|
setprop persist.sys.overlay.devinputjack true
|
|
|
|
fi
|
2018-07-09 06:29:30 +00:00
|
|
|
|
|
|
|
if ( getprop ro.hardware | grep -qE '(hi6250)' );then
|
|
|
|
setprop QC.HI6250 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
if ( getprop ro.hardware | grep -qE '(hi3660|hi3670|kirin970)' );then
|
|
|
|
setprop QC.HI36x0 1
|
|
|
|
fi
|