Skip to content

Commit

Permalink
chore(build): add more build variants
Browse files Browse the repository at this point in the history
Add x86 and universal variants
  • Loading branch information
iovxw committed Oct 30, 2021
1 parent f323fd5 commit e45801a
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/commit-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
- name: Upload Trime artifact
uses: actions/upload-artifact@v2
with:
name: trime-debug.apk
path: app/build/outputs/apk/debug/app-debug.apk
name: outputs
path: app/build/outputs/apk/**/*.apk
# keep 360 days
retention-days: 360
4 changes: 2 additions & 2 deletions .github/workflows/pull-request-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
- name: Upload Trime artifact
uses: actions/upload-artifact@v2
with:
name: trime-debug.apk
path: app/build/outputs/apk/debug/app-debug.apk
name: outputs
path: app/build/outputs/apk/**/*.apk
# keep 30 days
retention-days: 30
2 changes: 1 addition & 1 deletion .github/workflows/release-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ jobs:
- name: Create release
uses: ncipollo/release-action@v1
with:
artifacts: "app/build/outputs/apk/debug/app-debug.apk"
artifacts: "app/build/outputs/apk/**/*.apk"
body: |
${{ steps.release_log.outputs.changelog }}
token: ${{ secrets.GITHUB_TOKEN }}
26 changes: 22 additions & 4 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,14 @@ apply plugin: 'kotlin-android'

android {
compileSdkVersion 30
ndkVersion "23.0.7599858"

defaultConfig {
applicationId "com.osfans.trime"
minSdkVersion 21 // 21 is required for `readlinkat` for capnpproto
targetSdkVersion 29
versionCode 20211130
versionName "3.2.4"
ndk {
abiFilters "armeabi-v7a", "arm64-v8a"
}
}

signingConfigs {
Expand Down Expand Up @@ -54,7 +52,27 @@ android {
version "3.10.2"
}
}
ndkVersion "23.0.7599858"

flavorDimensions 'cpuArch'
productFlavors {
arm {
dimension 'cpuArch'
ndk {
abiFilters 'arm64-v8a', 'armeabi-v7a'
}
}
x86 {
dimension 'cpuArch'
ndk {
abiFilters 'x86_64', 'x86'
}
}
universal {
dimension 'cpuArch'
// include all default ABIs. with NDK-r16, it is:
// armeabi-v7a, arm64-v8a, x86, x86_64
}
}
}

dependencies {
Expand Down

0 comments on commit e45801a

Please sign in to comment.