From e4d70d8c50a9e2279bd799f88daca116c99d2cfb Mon Sep 17 00:00:00 2001 From: samsvp <50253175+samsvp@users.noreply.github.com> Date: Wed, 25 Sep 2024 19:44:53 -0300 Subject: [PATCH] Targetting android 29 issues a warning on new device that the apk contains security breaches. I've updated the target to Android 34 and made the necessary changes to build the apk. We still install build-tools and platform version 29 because version 34 has a bug in `dx` (renamed to `d8`) where it fails to link classes.dex --- Working-for-Android-(on-Linux).md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/Working-for-Android-(on-Linux).md b/Working-for-Android-(on-Linux).md index e78c539..392d285 100644 --- a/Working-for-Android-(on-Linux).md +++ b/Working-for-Android-(on-Linux).md @@ -109,13 +109,14 @@ public class NativeLoader extends android.app.NativeActivity { - + @@ -254,14 +255,15 @@ for ABI in $ABIS; do done cd ../.. -# Sign and zipalign APK +# Zipalign APK and sign # NOTE: If you changed the storepass and keypass in the setup process, change them here too -jarsigner -keystore android/raylib.keystore -storepass raylib -keypass raylib \ - -signedjar game.apk game.apk projectKey - $BUILD_TOOLS/zipalign -f 4 game.apk game.final.apk mv -f game.final.apk game.apk +# Install apksigner with `sudo apt install apksigner` +apksigner sign --ks android/raylib.keystore --out my-app-release.apk --ks-pass pass:raylib game.apk +mv my-app-release.apk game.apk + # Install to device or emulator android/sdk/platform-tools/adb install -r game.apk ```