2017-07-29 06:10:37 +02:00
|
|
|
apply plugin: 'com.android.application'
|
2018-07-13 02:10:35 +02:00
|
|
|
apply from: 'nonnull.gradle'
|
2017-07-29 06:10:37 +02:00
|
|
|
|
2018-06-05 16:24:53 +02:00
|
|
|
// Create a variable called keystorePropertiesFile, and initialize it to your
|
|
|
|
// keystore.properties file, in the rootProject folder.
|
|
|
|
final def keystorePropertiesFile = rootProject.file("keystore.properties")
|
|
|
|
|
2017-07-29 06:10:37 +02:00
|
|
|
android {
|
2018-10-01 16:02:55 +02:00
|
|
|
buildToolsVersion '28.0.3'
|
2017-12-26 21:06:32 +01:00
|
|
|
compileOptions {
|
|
|
|
sourceCompatibility JavaVersion.VERSION_1_8
|
|
|
|
targetCompatibility JavaVersion.VERSION_1_8
|
|
|
|
}
|
2018-08-12 13:09:20 +02:00
|
|
|
compileSdkVersion 28
|
2018-06-19 11:53:59 +02:00
|
|
|
dataBinding.enabled true
|
2017-07-29 06:10:37 +02:00
|
|
|
defaultConfig {
|
2017-11-29 03:15:40 +01:00
|
|
|
applicationId 'com.wireguard.android'
|
2017-07-29 06:10:37 +02:00
|
|
|
minSdkVersion 21
|
2018-08-12 13:09:20 +02:00
|
|
|
targetSdkVersion 28
|
2018-12-11 02:35:16 +01:00
|
|
|
versionCode 445
|
|
|
|
versionName '0.0.20181210'
|
2018-07-28 18:27:45 +02:00
|
|
|
buildConfigField 'int', 'MIN_SDK_VERSION', "$minSdkVersion.apiLevel"
|
2017-07-29 06:10:37 +02:00
|
|
|
}
|
2018-06-05 16:24:53 +02:00
|
|
|
// If the keystore file exists
|
|
|
|
if (keystorePropertiesFile.exists()) {
|
|
|
|
// Initialize a new Properties() object called keystoreProperties.
|
|
|
|
final def keystoreProperties = new Properties()
|
|
|
|
|
|
|
|
// Load your keystore.properties file into the keystoreProperties object.
|
|
|
|
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
|
|
|
|
|
|
|
signingConfigs {
|
|
|
|
release {
|
|
|
|
keyAlias keystoreProperties['keyAlias']
|
|
|
|
keyPassword keystoreProperties['keyPassword']
|
|
|
|
storeFile file(keystoreProperties['storeFile'])
|
|
|
|
storePassword keystoreProperties['storePassword']
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
buildTypes {
|
|
|
|
release {
|
|
|
|
if (keystorePropertiesFile.exists()) signingConfig signingConfigs.release
|
2018-07-24 13:52:18 +02:00
|
|
|
externalNativeBuild {
|
|
|
|
cmake {
|
|
|
|
arguments "-DANDROID_PACKAGE_NAME=${android.defaultConfig.applicationId}"
|
|
|
|
}
|
|
|
|
}
|
2018-06-05 16:24:53 +02:00
|
|
|
}
|
2018-07-07 19:04:34 +02:00
|
|
|
debug {
|
|
|
|
applicationIdSuffix ".debug"
|
|
|
|
versionNameSuffix "-debug"
|
2018-07-24 13:52:18 +02:00
|
|
|
externalNativeBuild {
|
|
|
|
cmake {
|
|
|
|
arguments "-DANDROID_PACKAGE_NAME=${android.defaultConfig.applicationId}${applicationIdSuffix}"
|
|
|
|
}
|
|
|
|
}
|
2018-07-07 19:04:34 +02:00
|
|
|
}
|
2018-06-05 16:24:53 +02:00
|
|
|
}
|
2017-12-05 03:50:36 +01:00
|
|
|
externalNativeBuild {
|
|
|
|
cmake {
|
|
|
|
path 'tools/CMakeLists.txt'
|
|
|
|
}
|
|
|
|
}
|
2017-07-29 06:10:37 +02:00
|
|
|
}
|
2018-06-19 07:36:24 +02:00
|
|
|
|
2018-04-27 16:55:42 +02:00
|
|
|
ext {
|
2018-06-19 07:36:24 +02:00
|
|
|
databindingVersion = '3.1.3'
|
2018-07-13 02:10:35 +02:00
|
|
|
jsr305Version = '3.0.2'
|
2018-09-06 03:17:14 +02:00
|
|
|
streamsupportVersion = '1.6.0'
|
2018-12-08 03:19:54 +01:00
|
|
|
supportLibsVersion = '27.1.1'
|
2018-09-06 03:17:14 +02:00
|
|
|
threetenabpVersion = '1.1.1'
|
2018-07-24 19:32:40 +02:00
|
|
|
zxingEmbeddedVersion = '3.6.0'
|
2018-04-27 16:55:42 +02:00
|
|
|
}
|
2017-07-29 06:10:37 +02:00
|
|
|
|
|
|
|
dependencies {
|
2018-04-27 16:55:42 +02:00
|
|
|
implementation "com.android.databinding:library:$databindingVersion"
|
2018-04-27 18:59:27 +02:00
|
|
|
implementation "com.android.support:appcompat-v7:$supportLibsVersion"
|
2018-05-02 08:03:03 +02:00
|
|
|
implementation "com.android.support:cardview-v7:$supportLibsVersion"
|
2018-04-29 07:11:08 +02:00
|
|
|
implementation "com.android.support:design:$supportLibsVersion"
|
2018-04-30 15:35:21 +02:00
|
|
|
implementation "com.android.support:preference-v14:$supportLibsVersion"
|
2018-04-30 18:35:46 +02:00
|
|
|
implementation "com.android.support:support-annotations:$supportLibsVersion"
|
2018-07-13 02:10:35 +02:00
|
|
|
implementation "com.google.code.findbugs:jsr305:$jsr305Version"
|
2018-09-06 03:17:14 +02:00
|
|
|
implementation "com.jakewharton.threetenabp:threetenabp:$threetenabpVersion"
|
2018-07-24 19:32:40 +02:00
|
|
|
implementation "com.journeyapps:zxing-android-embedded:$zxingEmbeddedVersion"
|
2018-07-31 23:17:34 +02:00
|
|
|
implementation "net.sourceforge.streamsupport:android-retrofuture:$streamsupportVersion"
|
|
|
|
implementation "net.sourceforge.streamsupport:android-retrostreams:$streamsupportVersion"
|
2017-07-29 06:10:37 +02:00
|
|
|
}
|
2018-05-29 18:37:14 +02:00
|
|
|
|
|
|
|
tasks.withType(JavaCompile) {
|
|
|
|
options.compilerArgs << '-Xlint:unchecked'
|
|
|
|
options.deprecation = true
|
2018-05-29 19:08:55 +02:00
|
|
|
}
|