Account for different property names returned by getprop

This commit is contained in:
Anton Liaposhchenko 2024-05-18 22:18:52 +03:00
parent e9e167f3af
commit dc5dd9433e
2 changed files with 6 additions and 2 deletions

View File

@ -1,8 +1,10 @@
#!/system/bin/sh
BASE_DIR=$(dirname $0)
ABIS=$(getprop ro.system.product.cpu.abilist)
ABIS=${ABIS:-$(getprop ro.product.cpu.abilist)}
for LIB_DIR in $BASE_DIR/lib/{$(getprop ro.system.product.cpu.abilist)}; do
for LIB_DIR in $BASE_DIR/lib/{$ABIS}; do
[ -d "$LIB_DIR" ] && break
unset -v LIB_DIR
done

View File

@ -1,8 +1,10 @@
#!/system/bin/sh
BASE_DIR=$(dirname $0)
ABIS=$(getprop ro.system.product.cpu.abilist)
ABIS=${ABIS:-$(getprop ro.product.cpu.abilist)}
for LIB_DIR in $BASE_DIR/lib/{$(getprop ro.system.product.cpu.abilist)}; do
for LIB_DIR in $BASE_DIR/lib/{$ABIS}; do
[ -d "$LIB_DIR" ] && break
unset -v LIB_DIR
done