2019-09-19 22:41:31 +02:00
|
|
|
#!/bin/sh
|
2016-08-31 23:39:18 +02:00
|
|
|
|
2018-05-01 10:42:31 +02:00
|
|
|
unset LD_LIBRARY_PATH LD_PRELOAD
|
2016-03-23 17:45:54 +01:00
|
|
|
|
2018-12-04 03:42:57 +01:00
|
|
|
for p in /sbin/su /system/sbin/su /system/bin/su /system/xbin/su /su/bin/su /magisk/.core/bin/su
|
2016-03-28 19:07:00 +02:00
|
|
|
do
|
|
|
|
if [ -x $p ]; then
|
2016-08-31 23:39:18 +02:00
|
|
|
# The su tool may require programs in PATH:
|
2019-10-06 01:24:07 +02:00
|
|
|
PATH=/sbin:/sbin/su:/su/bin:/su/xbin:/system/bin:/system/xbin \
|
2017-01-25 11:50:20 +01:00
|
|
|
exec $p "$@"
|
2016-03-28 19:07:00 +02:00
|
|
|
fi
|
|
|
|
done
|
|
|
|
|
2016-09-12 12:11:18 +02:00
|
|
|
echo "No su program found on this device. Termux"
|
2016-03-28 19:07:00 +02:00
|
|
|
echo "does not supply tools for rooting, see e.g."
|
|
|
|
echo "http://www.androidcentral.com/root for"
|
|
|
|
echo "information about rooting Android."
|
|
|
|
exit 1
|