diff --git a/README.md b/README.md index 9fa1511..b2b59cb 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,7 @@ If you wish to include/exclude some patches to your liking: * Grab your module from [releases](../../releases) # Building the Magisk Modules +If you are going to build locally, make sure you have [Azul Zulu distribution of OpenJDK 17](https://www.azul.com/downloads/?version=java-17-lts&os=linux&architecture=x86-64-bit&package=jdk) ```console $ ./build.sh all diff --git a/build.sh b/build.sh index 42d6a65..38ca1e7 100755 --- a/build.sh +++ b/build.sh @@ -2,11 +2,12 @@ set -euo pipefail -source utils.sh - YT_PATCHER_ARGS="-e microg-support -e swipe-controls" MUSIC_PATCHER_ARGS="-e microg-support" +# dont change anything after this point ↓ +source utils.sh + BUILD_YT=false BUILD_MUSIC=false diff --git a/utils.sh b/utils.sh index 2128070..52f73dd 100755 --- a/utils.sh +++ b/utils.sh @@ -96,14 +96,14 @@ build_yt() { echo "Supported versions of the YouTube patch: $supported_versions" last_ver=$(echo "$supported_versions" | awk -F, '{ print $NF }') echo "Choosing '${last_ver}'" - local yt_base_apk="${TEMP_DIR}/base-v${last_ver}.apk" + local yt_base_apk="${TEMP_DIR}/yt-stock-v${last_ver}.apk" if [ ! -f "$yt_base_apk" ]; then dl_yt "$last_ver" "$yt_base_apk" fi local yt_patched_apk="${TEMP_DIR}/yt-revanced-base.apk" - java -jar $RV_CLI_JAR -a $yt_base_apk -c -o $yt_patched_apk -b $RV_PATCHES_JAR -m $RV_INTEGRATIONS_APK $1 + java -jar "$RV_CLI_JAR" -a "$yt_base_apk" -c -o "$yt_patched_apk" -b "$RV_PATCHES_JAR" -m "$RV_INTEGRATIONS_APK" "$1" mv -f "$yt_patched_apk" "${MODULE_TEMPLATE_DIR}/base.apk" echo "Creating the magisk module for YouTube..." @@ -136,7 +136,7 @@ build_music() { fi local music_patched_apk="${TEMP_DIR}/music-revanced-base.apk" - java -jar $RV_CLI_JAR -a $music_apk -c -o $music_patched_apk -b $RV_PATCHES_JAR -m $RV_INTEGRATIONS_APK $1 + java -jar "$RV_CLI_JAR" -a "$music_apk" -c -o "$music_patched_apk" -b "$RV_PATCHES_JAR" -m "$RV_INTEGRATIONS_APK" "$1" mv -f "$music_patched_apk" "${MODULE_TEMPLATE_DIR}/base.apk" echo "Creating the magisk module for YouTube Music ($arch)"