diff options
Diffstat (limited to 'ui/build.gradle')
-rw-r--r-- | ui/build.gradle | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/ui/build.gradle b/ui/build.gradle index 1ac42e58..61c06f2a 100644 --- a/ui/build.gradle +++ b/ui/build.gradle @@ -1,3 +1,5 @@ +import org.jetbrains.kotlin.gradle.tasks.KotlinCompile + plugins { id 'com.android.application' id 'org.jetbrains.kotlin.android' @@ -12,16 +14,17 @@ group groupName final def keystorePropertiesFile = rootProject.file("keystore.properties") android { - compileSdkVersion 31 + compileSdk 33 buildFeatures { buildConfig = true dataBinding = true viewBinding = true } + namespace = 'com.wireguard.android' defaultConfig { applicationId 'eu.m7n.wireguard.android' minSdkVersion 21 - targetSdkVersion 30 + targetSdkVersion 33 versionCode wireguardVersionCode versionName wireguardVersionName buildConfigField 'int', 'MIN_SDK_VERSION', "$minSdkVersion.apiLevel" @@ -59,6 +62,9 @@ android { } } buildTypes { + all { + buildConfigField("boolean", "IS_GOOGLE_PLAY", (System.getenv("WG_BUILD_FOR_GOOGLE_PLAY") == "true").toString()) + } release { if (keystorePropertiesFile.exists()) signingConfig signingConfigs.release minifyEnabled true @@ -69,10 +75,9 @@ android { versionNameSuffix "-debug" } } - lintOptions { - disable('LongLogTag') - warning('MissingTranslation') - warning('ImpliedQuantity') + lint { + disable 'LongLogTag' + warning 'MissingTranslation', 'ImpliedQuantity' } } @@ -96,14 +101,11 @@ dependencies { coreLibraryDesugaring "com.android.tools:desugar_jdk_libs:$desugarVersion" } -tasks.withType(JavaCompile) { +tasks.withType(JavaCompile).configureEach { options.compilerArgs << '-Xlint:unchecked' options.deprecation = true } -tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all { - kotlinOptions { - jvmTarget = JavaVersion.VERSION_1_8 - useIR = true - } +tasks.withType(KotlinCompile).configureEach { + kotlinOptions.jvmTarget = JavaVersion.VERSION_1_8 } |