Fix minijail issue on pie vendors

This commit is contained in:
Pierre-Hugues Husson 2020-06-17 16:34:17 +02:00
parent 51dc96a900
commit 4943b6a93e
2 changed files with 14 additions and 0 deletions

View File

@ -40,6 +40,15 @@ if [ "$vndk" = 27 ] && getprop init.svc.mediacodec |grep -q restarting;then
mount /system/lib/vndk-27/libminijail.so /vendor/lib/libminijail_vendor.so mount /system/lib/vndk-27/libminijail.so /vendor/lib/libminijail_vendor.so
fi fi
if [ "$vndk" = 28 ] && getprop |grep init.svc | grep media |grep -q restarting;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
#Clear looping services #Clear looping services
sleep 30 sleep 30
getprop | \ getprop | \

View File

@ -1,5 +1,8 @@
#!/system/bin/sh #!/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 if getprop persist.sys.phh.no_vendor_overlay |grep -q true;then
for part in odm vendor;do for part in odm vendor;do
mount /mnt/phh/empty_dir/ /$part/overlay mount /mnt/phh/empty_dir/ /$part/overlay
@ -20,4 +23,6 @@ if [ "$vndk" = 28 ] && getprop |grep init.svc | grep media |grep -q restarting;t
mount /system/lib/vndk-27/libminijail.so /vendor/lib/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/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/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 fi