xmrwallet/app/build.gradle

144 lines
4.7 KiB
Groovy
Raw Normal View History

apply plugin: 'com.android.application'
android {
2018-11-20 10:20:42 -07:00
compileSdkVersion 28
2020-06-05 00:56:02 -06:00
buildToolsVersion '29.0.2'
defaultConfig {
applicationId "com.m2049r.xmrwallet"
minSdkVersion 21
2018-11-20 10:20:42 -07:00
targetSdkVersion 28
versionCode 502
versionName "1.15.2 'Dark Fork'"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
externalNativeBuild {
cmake {
cppFlags "-std=c++11"
arguments '-DANDROID_STL=c++_shared'
}
}
}
bundle {
language {
enableSplit = false
}
}
2018-11-20 10:20:42 -07:00
flavorDimensions 'type', 'net'
2018-09-26 10:55:33 -06:00
productFlavors {
2018-11-20 10:20:42 -07:00
mainnet {
dimension 'net'
}
stagenet {
dimension 'net'
applicationIdSuffix '.stage'
versionNameSuffix ' (stage)'
2018-11-20 10:20:42 -07:00
}
devnet {
dimension 'net'
applicationIdSuffix '.test'
versionNameSuffix ' (test)'
}
2018-09-26 10:55:33 -06:00
alpha {
2018-11-20 10:20:42 -07:00
dimension 'type'
applicationIdSuffix '.alpha'
versionNameSuffix ' (alpha)'
2018-09-26 10:55:33 -06:00
}
prod {
2018-11-20 10:20:42 -07:00
dimension 'type'
2018-09-26 10:55:33 -06:00
}
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
applicationIdSuffix ".debug"
}
}
2018-09-26 10:55:33 -06:00
externalNativeBuild {
cmake {
path "CMakeLists.txt"
}
}
2018-01-23 13:35:26 -07:00
splits {
abi {
enable true
reset()
2018-09-27 10:24:22 -06:00
include 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
universalApk true
2018-01-23 13:35:26 -07:00
}
}
// Map for the version code that gives each ABI a value.
def abiCodes = ['armeabi-v7a': 1, 'arm64-v8a': 2, 'x86': 3, 'x86_64': 4]
// Enumerate translated locales
def availableLocales = ["en"]
new File("app/src/main/res/").eachFileMatch(~/^values-.*/) { file ->
def languageTag = file.name.substring(7).replace("-r", "-")
if (languageTag != "night")
availableLocales.add(languageTag)
}
// APKs for the same app that all have the same version information.
android.applicationVariants.all { variant ->
// Update string resource: available_locales
variant.resValue("string", "available_locales", availableLocales.join(","))
// Assigns a different version code for each output APK.
variant.outputs.all {
output ->
def abiName = output.getFilter(com.android.build.OutputFile.ABI)
output.versionCodeOverride = abiCodes.get(abiName, 0) + 10 * variant.versionCode
2018-09-26 10:55:33 -06:00
//def flavor = output.getFilter(flavor)
if (abiName == null) abiName = "universal"
2018-09-26 10:55:33 -06:00
def v = "${variant.versionName}".replaceFirst(" '.*' ?", "")
.replace(".", "x")
.replace("(", "-")
.replace(")", "")
outputFileName = "$rootProject.ext.apkName-" + v + "_" + abiName + ".apk"
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies {
implementation 'androidx.core:core:1.3.2'
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation group: 'com.google.android.material', name: 'material', version: '1.3.0-alpha03'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'androidx.recyclerview:recyclerview:1.1.0'
implementation 'androidx.cardview:cardview:1.0.0'
implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.2.0-alpha01'
implementation 'androidx.constraintlayout:constraintlayout:2.0.1'
implementation 'me.dm7.barcodescanner:zxing:1.9.8'
implementation "com.squareup.okhttp3:okhttp:$rootProject.ext.okHttpVersion"
implementation "com.burgstaller:okhttp-digest:2.0"
implementation "com.jakewharton.timber:timber:$rootProject.ext.timberVersion"
implementation 'com.nulab-inc:zxcvbn:1.3.0'
2017-09-08 14:14:09 -06:00
implementation 'dnsjava:dnsjava:2.1.9'
implementation 'org.jitsi:dnssecjava:1.2.0'
implementation 'org.slf4j:slf4j-nop:1.7.30'
2019-01-10 10:58:37 -07:00
implementation 'com.github.brnunes:swipeablerecyclerview:1.0.2'
2019-03-08 16:02:58 -07:00
// https://mvnrepository.com/artifact/com.github.aelstad/keccakj
implementation 'com.github.aelstad:keccakj:1.1.0'
testImplementation "junit:junit:$rootProject.ext.junitVersion"
testImplementation "org.mockito:mockito-all:$rootProject.ext.mockitoVersion"
testImplementation "com.squareup.okhttp3:mockwebserver:$rootProject.ext.okHttpVersion"
2019-01-10 11:30:59 -07:00
testImplementation 'org.json:json:20180813'
testImplementation 'net.jodah:concurrentunit:0.4.4'
2017-09-08 14:14:09 -06:00
}