device_phh_treble/phh-on-data.sh
darkestDark 9221314a7e
libminijail.so error
check for vndk only to mount
2020-08-05 20:04:01 +02:00

30 lines
1.1 KiB
Bash

#!/system/bin/sh
vndk="$(getprop persist.sys.vndk)"
[ -z "$vndk" ] && vndk="$(getprop ro.vndk.version |grep -oE '^[0-9]+')"
if getprop persist.sys.phh.no_vendor_overlay |grep -q true;then
for part in odm vendor;do
mount /mnt/phh/empty_dir/ /$part/overlay
done
fi
if getprop persist.sys.phh.caf.media_profile |grep -q true;then
setprop media.settings.xml "/vendor/etc/media_profiles_vendor.xml"
fi
if [ "$vndk" = 27 ];then
mount /system/lib64/vndk-27/libminijail.so /vendor/lib64/libminijail_vendor.so
mount /system/lib/vndk-27/libminijail.so /vendor/lib/libminijail_vendor.so
fi
if [ "$vndk" = 28 ];then
mount /system/lib64/vndk-27/libminijail.so /vendor/lib64/libminijail_vendor.so
mount /system/lib/vndk-27/libminijail.so /vendor/lib/libminijail_vendor.so
mount /system/lib64/vndk-27/libminijail.so /system/lib64/vndk-28/libminijail.so
mount /system/lib/vndk-27/libminijail.so /system/lib/vndk-28/libminijail.so
mount /system/lib64/vndk-27/libminijail.so /vendor/lib64/libminijail.so
mount /system/lib/vndk-27/libminijail.so /vendor/lib/libminijail.so
fi