2022-06-07 09:17:21 +00:00
|
|
|
apply plugin: 'com.getkeepsafe.dexcount'
|
|
|
|
|
|
|
|
android {
|
|
|
|
ext {
|
|
|
|
jvmKotlinFolderFile = {
|
|
|
|
String sep = File.separator
|
|
|
|
return new File("${project.projectDir}${sep}src${sep}jvmMain${sep}kotlin")
|
|
|
|
}
|
|
|
|
|
|
|
|
enableIncludingJvmCodeInAndroidPart = {
|
|
|
|
File jvmKotlinFolder = jvmKotlinFolderFile()
|
|
|
|
if (jvmKotlinFolder.exists()) {
|
|
|
|
android.sourceSets.main.java.srcDirs += jvmKotlinFolder.path
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
disableIncludingJvmCodeInAndroidPart = {
|
|
|
|
File jvmKotlinFolder = jvmKotlinFolderFile()
|
|
|
|
String[] oldDirs = android.sourceSets.main.java.srcDirs
|
|
|
|
android.sourceSets.main.java.srcDirs = []
|
|
|
|
for (oldDir in oldDirs) {
|
|
|
|
if (oldDir != jvmKotlinFolder.path) {
|
|
|
|
android.sourceSets.main.java.srcDirs += oldDir
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2023-09-20 15:39:01 +00:00
|
|
|
compileSdk libs.versions.android.compileSdk.get().toInteger()
|
|
|
|
buildToolsVersion = libs.versions.android.buildTools.get()
|
|
|
|
namespace "${group}.${project.name}"
|
2022-06-07 09:17:21 +00:00
|
|
|
|
|
|
|
defaultConfig {
|
|
|
|
minSdkVersion libs.versions.android.minSdk.get().toInteger()
|
|
|
|
targetSdkVersion libs.versions.android.compileSdk.get().toInteger()
|
|
|
|
versionCode "${android_code_version}".toInteger()
|
|
|
|
versionName "$version"
|
|
|
|
}
|
|
|
|
buildTypes {
|
|
|
|
release {
|
|
|
|
minifyEnabled false
|
|
|
|
}
|
|
|
|
debug {
|
|
|
|
debuggable true
|
|
|
|
}
|
|
|
|
}
|
2023-10-22 20:12:38 +00:00
|
|
|
publishing {
|
|
|
|
multipleVariants {
|
|
|
|
allVariants()
|
|
|
|
withSourcesJar()
|
|
|
|
withJavadocJar()
|
|
|
|
}
|
|
|
|
}
|
2022-06-07 09:17:21 +00:00
|
|
|
|
|
|
|
packagingOptions {
|
|
|
|
exclude 'META-INF/kotlinx-serialization-runtime.kotlin_module'
|
|
|
|
exclude 'META-INF/kotlinx-serialization-cbor.kotlin_module'
|
|
|
|
exclude 'META-INF/kotlinx-serialization-properties.kotlin_module'
|
|
|
|
}
|
|
|
|
|
|
|
|
compileOptions {
|
|
|
|
sourceCompatibility JavaVersion.VERSION_1_8
|
|
|
|
targetCompatibility JavaVersion.VERSION_1_8
|
|
|
|
}
|
|
|
|
|
|
|
|
sourceSets {
|
|
|
|
String sep = File.separator
|
|
|
|
main.java.srcDirs += "src${sep}main${sep}kotlin"
|
|
|
|
}
|
|
|
|
}
|