mirror of
https://github.com/nextcloud/android.git
synced 2024-11-21 12:45:32 +03:00
Centralize NDK and CMAKE versions
Signed-off-by: Álvaro Brey Vilas <alvaro.brey@nextcloud.com>
This commit is contained in:
parent
3b5d9ddabf
commit
ec98c5db52
3 changed files with 13 additions and 2 deletions
4
.github/workflows/qa.yml
vendored
4
.github/workflows/qa.yml
vendored
|
@ -20,7 +20,9 @@ jobs:
|
||||||
distribution: "temurin"
|
distribution: "temurin"
|
||||||
java-version: 11
|
java-version: 11
|
||||||
- name: Install NDK and cmake
|
- name: Install NDK and cmake
|
||||||
run: /usr/local/lib/android/sdk/tools/bin/sdkmanager 'ndk;21.4.7075529' 'cmake;3.18.1'
|
run: |
|
||||||
|
source ndk.env
|
||||||
|
/usr/local/lib/android/sdk/tools/bin/sdkmanager "ndk;${NDK_VERSION}" "cmake;${CMAKE_VERSION}"
|
||||||
- name: Build QA
|
- name: Build QA
|
||||||
if: ${{ steps.check-secrets.outputs.ok == 'true' }}
|
if: ${{ steps.check-secrets.outputs.ok == 'true' }}
|
||||||
env:
|
env:
|
||||||
|
|
|
@ -69,11 +69,18 @@ def versionMinor = 20
|
||||||
def versionPatch = 0
|
def versionPatch = 0
|
||||||
def versionBuild = 0 // 0-50=Alpha / 51-98=RC / 90-99=stable
|
def versionBuild = 0 // 0-50=Alpha / 51-98=RC / 90-99=stable
|
||||||
|
|
||||||
|
|
||||||
|
def ndkEnv = new HashMap<String, String>()
|
||||||
|
file("$project.rootDir/ndk.env").readLines().each() {
|
||||||
|
def (key, value) = it.tokenize('=')
|
||||||
|
ndkEnv.put(key, value)
|
||||||
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
|
|
||||||
compileSdkVersion 31
|
compileSdkVersion 31
|
||||||
// install this NDK version and Cmake to produce smaller APKs. Build will still work if not installed
|
// install this NDK version and Cmake to produce smaller APKs. Build will still work if not installed
|
||||||
ndkVersion "21.4.7075529"
|
ndkVersion "${ndkEnv.get("NDK_VERSION")}"
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
minSdkVersion 23
|
minSdkVersion 23
|
||||||
|
|
2
ndk.env
Normal file
2
ndk.env
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
NDK_VERSION=21.4.7075529
|
||||||
|
CMAKE_VERSION=3.18.1
|
Loading…
Reference in a new issue