kernelSU's su now has -M

This commit is contained in:
j-hc 2023-08-12 15:02:51 +03:00
parent 467a447e58
commit 44aa8c732d
3 changed files with 9 additions and 7 deletions

View File

@ -80,7 +80,6 @@ for table_name in $(toml_get_table_names); do
enabled=$(toml_get "$t" enabled) && vtf "$enabled" "enabled" || enabled=true
if [ "$enabled" = false ]; then continue; fi
if ((idx >= PARALLEL_JOBS)); then wait -n; else idx=$((idx + 1)); fi
declare -A app_args
patches_src=$(toml_get "$t" patches-source) || patches_src=$DEF_PATCHES_SRC
patches_ver=$(toml_get "$t" patches-version) || patches_ver=$DEF_PATCHES_VER
@ -139,12 +138,15 @@ for table_name in $(toml_get_table_names); do
app_args[table]="$table_name (arm64-v8a)"
app_args[module_prop_name]="${app_args[module_prop_name]}-arm64"
app_args[arch]="arm64-v8a"
if ((idx >= PARALLEL_JOBS)); then wait -n; else idx=$((idx + 1)); fi
build_rv_w
app_args[table]="$table_name (arm-v7a)"
app_args[module_prop_name]="${app_args[module_prop_name]}-arm"
app_args[arch]="arm-v7a"
if ((idx >= PARALLEL_JOBS)); then wait -n; else idx=$((idx + 1)); fi
build_rv_w
else
if ((idx >= PARALLEL_JOBS)); then wait -n; else idx=$((idx + 1)); fi
build_rv_w
fi
done
@ -166,7 +168,7 @@ if [ "$youtube_mode" != module ] || [ "$music_mode" != module ]; then
log "\nInstall [Vanced Microg](https://github.com/TeamVanced/VancedMicroG/releases) for non-root YouTube or YT Music"
fi
log "\n[revanced-magisk-module](https://github.com/j-hc/revanced-magisk-module)"
log "\n---\nChangelog:"
log "---\nChangelog:"
log "$(cat $TEMP_DIR/*-rv/changelog.md)"
pr "Done"

View File

@ -14,11 +14,11 @@ else
fi
set_perm_recursive $MODPATH/bin 0 0 0755 0777
nsenter -t1 -m -- grep __PKGNAME /proc/mounts | while read -r line; do
su -M -c grep __PKGNAME /proc/mounts | while read -r line; do
ui_print "* Un-mount"
mp=${line#* }
mp=${mp%% *}
nsenter -t1 -m -- umount -l "${mp%%\\*}"
su -M -c umount -l "${mp%%\\*}"
done
am force-stop __PKGNAME
@ -97,7 +97,7 @@ mkdir -p $NVBASE/rvhc
RVPATH=$NVBASE/rvhc/${MODPATH##*/}.apk
mv -f $MODPATH/base.apk $RVPATH
if ! op=$(nsenter -t1 -m -- mount -o bind $RVPATH $BASEPATH/base.apk 2>&1); then
if ! op=$(su -M -c mount -o bind $RVPATH $BASEPATH/base.apk 2>&1); then
ui_print "ERROR: Mount failed!"
ui_print "$op"
fi

View File

@ -1,8 +1,8 @@
#!/system/bin/sh
{
MODDIR=${0%/*}
rm $NVBASE/rvhc/${MODDIR##*/}.apk
rmdir $NVBASE/rvhc
rm "$NVBASE/rvhc/${MODDIR##*/}".apk
rmdir --ignore-fail-on-non-empty "$NVBASE/rvhc"
# if __ISBNDL; then
# until [ "$(getprop sys.boot_completed)" = 1 ]; do sleep 1; done
# sleep 15