Merge pull request #858 from amnezia-vpn/fdroid

This commit is contained in:
pokamest 2024-06-19 10:41:32 +01:00 committed by GitHub
commit 130fc8277d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 25 additions and 6 deletions

View file

@ -69,6 +69,12 @@ android {
} }
signingConfig = signingConfigs["release"] signingConfig = signingConfigs["release"]
} }
create("fdroid") {
initWith(getByName("release"))
signingConfig = null
matchingFallbacks += "release"
}
} }
splits { splits {

View file

@ -22,6 +22,7 @@ Options:
-b, --build-platform <platform> The SDK platform used for building the Java code of the application -b, --build-platform <platform> The SDK platform used for building the Java code of the application
By default, the latest available platform is used By default, the latest available platform is used
-m, --move Move the build result to the root of the build directory -m, --move Move the build result to the root of the build directory
-f, --fdroid Build for F-Droid
-h, --help Display this help -h, --help Display this help
EOT EOT
@ -29,7 +30,7 @@ EOT
BUILD_TYPE="release" BUILD_TYPE="release"
opts=$(getopt -l debug,aab,apk:,build-platform:,move,help -o "dua:b:mh" -- "$@") opts=$(getopt -l debug,aab,apk:,build-platform:,move,fdroid,help -o "dua:b:mfh" -- "$@")
eval set -- "$opts" eval set -- "$opts"
while true; do while true; do
case "$1" in case "$1" in
@ -38,6 +39,7 @@ while true; do
-a | --apk) ABIS=$2; shift 2;; -a | --apk) ABIS=$2; shift 2;;
-b | --build-platform) ANDROID_BUILD_PLATFORM=$2; shift 2;; -b | --build-platform) ANDROID_BUILD_PLATFORM=$2; shift 2;;
-m | --move) MOVE_RESULT=1; shift;; -m | --move) MOVE_RESULT=1; shift;;
-f | --fdroid) FDROID=1; shift;;
-h | --help) usage; exit 0;; -h | --help) usage; exit 0;;
--) shift; break;; --) shift; break;;
esac esac
@ -143,6 +145,10 @@ $QT_HOST_PATH/bin/androiddeployqt \
# run gradle # run gradle
gradle_opts=() gradle_opts=()
if [ -v FDROID ]; then
BUILD_TYPE="fdroid"
fi
if [ -v AAB ]; then if [ -v AAB ]; then
gradle_opts+=(bundle"${BUILD_TYPE^}") gradle_opts+=(bundle"${BUILD_TYPE^}")
fi fi
@ -167,10 +173,15 @@ if [[ -v CI || -v MOVE_RESULT ]]; then
ABIS="x86;x86_64;armeabi-v7a;arm64-v8a" ABIS="x86;x86_64;armeabi-v7a;arm64-v8a"
fi fi
suffix=$BUILD_TYPE
if [ -v FDROID ]; then
suffix+="-unsigned"
fi
IFS=';' read -r -a abi_array <<< "$ABIS" IFS=';' read -r -a abi_array <<< "$ABIS"
for ABI in "${abi_array[@]}" for ABI in "${abi_array[@]}"
do do
mv -u $OUT_APP_DIR/android-build/build/outputs/apk/$BUILD_TYPE/AmneziaVPN-$ABI-$BUILD_TYPE.apk \ mv -u $OUT_APP_DIR/android-build/build/outputs/apk/$BUILD_TYPE/AmneziaVPN-$ABI-$suffix.apk \
$PROJECT_DIR/deploy/build/ $PROJECT_DIR/deploy/build/
done done
fi fi

View file

@ -1,4 +0,0 @@
What's Changed:
* Added app split tunneling
* Added a tile to the quick settings panel
* Bug fixes and improvements

View file

@ -0,0 +1,6 @@
What's Changed:
* Added XRay protocol support
* Added app split tunneling
* Added a notification to the status bar when VPN is running
* Added a tile to the quick settings panel
* Bug fixes and improvements