2017-07-29 06:10:37 +02:00
|
|
|
apply plugin: 'com.android.application'
|
2020-02-14 10:57:17 +01:00
|
|
|
apply plugin: 'kotlin-android'
|
2020-03-09 14:33:06 +01:00
|
|
|
apply from: rootProject.file('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 {
|
2020-02-28 07:58:02 +01:00
|
|
|
buildToolsVersion '29.0.3'
|
2017-12-26 21:06:32 +01:00
|
|
|
compileOptions {
|
|
|
|
sourceCompatibility JavaVersion.VERSION_1_8
|
|
|
|
targetCompatibility JavaVersion.VERSION_1_8
|
|
|
|
}
|
2020-02-23 14:49:25 +01:00
|
|
|
tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all {
|
|
|
|
kotlinOptions {
|
|
|
|
jvmTarget = '1.8'
|
|
|
|
}
|
|
|
|
}
|
2019-09-30 08:59:06 +02:00
|
|
|
compileSdkVersion 29
|
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
|
2019-09-30 08:59:06 +02:00
|
|
|
targetSdkVersion 29
|
2020-02-06 21:58:40 +01:00
|
|
|
versionCode 464
|
|
|
|
versionName '0.0.20200206'
|
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-12-18 17:48:00 +01:00
|
|
|
minifyEnabled true
|
|
|
|
proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
|
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
|
|
|
}
|
2018-04-27 16:55:42 +02:00
|
|
|
}
|
2017-07-29 06:10:37 +02:00
|
|
|
|
|
|
|
dependencies {
|
2020-03-09 14:30:14 +01:00
|
|
|
implementation project(":tunnel")
|
2018-12-18 11:45:37 +01:00
|
|
|
implementation "androidx.annotation:annotation:$annotationsVersion"
|
|
|
|
implementation "androidx.appcompat:appcompat:$appcompatVersion"
|
|
|
|
implementation "androidx.cardview:cardview:$cardviewVersion"
|
2020-03-09 05:50:14 +01:00
|
|
|
implementation "androidx.constraintlayout:constraintlayout:$constraintLayoutVersion"
|
|
|
|
implementation "androidx.coordinatorlayout:coordinatorlayout:$coordinatorLayoutVersion"
|
2020-02-23 15:30:03 +01:00
|
|
|
implementation "androidx.core:core-ktx:$coreKtxVersion"
|
2020-03-09 14:30:14 +01:00
|
|
|
implementation "androidx.databinding:databinding-runtime:$agpVersion"
|
2020-02-23 15:36:15 +01:00
|
|
|
implementation "androidx.fragment:fragment:$fragmentVersion"
|
2018-12-18 11:45:37 +01:00
|
|
|
implementation "androidx.preference:preference:$preferenceVersion"
|
|
|
|
implementation "com.google.android.material:material:$materialComponentsVersion"
|
2018-07-24 19:32:40 +02:00
|
|
|
implementation "com.journeyapps:zxing-android-embedded:$zxingEmbeddedVersion"
|
2019-10-13 20:48:09 +02:00
|
|
|
implementation "net.i2p.crypto:eddsa:$eddsaVersion"
|
2020-02-14 10:57:17 +01:00
|
|
|
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlinVersion"
|
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
|
|
|
}
|