Skip to content

Commit

Permalink
add tag checking to subm
Browse files Browse the repository at this point in the history
  • Loading branch information
= mlm-games committed Sep 10, 2024
1 parent c5af05c commit 65f61dc
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions kernel/setup-subm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@ setup_kernelsu() {
test -d "$KERNEL_DIR/KernelSU"
git submodule add https://github.com/mlm-games/KernelSU-Non-GKI KernelSU
git submodule update --init --recursive

if [ -n "$1" ]; then
(cd KernelSU && git checkout "$1") && echo "[-] Checked out $1." || echo "[-] Failed to checkout $1."
else

# Add entries in Makefile and Kconfig if not already existing
grep -q "kernelsu" "$DRIVER_MAKEFILE" || printf "\nobj-\$(CONFIG_KSU) += kernelsu/\n" >> "$DRIVER_MAKEFILE" && echo "[+] Modified Makefile."
grep -q "source \"drivers/kernelsu/Kconfig\"" "$DRIVER_KCONFIG" || sed -i "/endmenu/i\source \"drivers/kernelsu/Kconfig\"" "$DRIVER_KCONFIG" && echo "[+] Modified Kconfig."
Expand Down

0 comments on commit 65f61dc

Please sign in to comment.