You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tasks/data/build.gradle.kts

72 lines
1.8 KiB
Kotlin

@file:OptIn(ExperimentalKotlinGradlePluginApi::class)
import org.jetbrains.kotlin.gradle.ExperimentalKotlinGradlePluginApi
plugins {
alias(libs.plugins.android.library)
alias(libs.plugins.kotlin.multiplatform)
alias(libs.plugins.kotlin.parcelize)
alias(libs.plugins.kotlin.serialization)
alias(libs.plugins.ksp)
}
kotlin {
applyDefaultHierarchyTemplate()
androidTarget {
compilerOptions {
freeCompilerArgs.addAll("-P", "plugin:org.jetbrains.kotlin.parcelize:additionalAnnotation=org.tasks.CommonParcelize")
}
compilations.all {
kotlinOptions {
jvmTarget = "17"
}
}
}
jvm()
sourceSets {
commonMain.dependencies {
implementation(libs.androidx.room)
implementation(libs.kotlinx.serialization)
implementation(libs.kermit)
}
}
task("testClasses")
}
android {
namespace = "org.tasks.data"
compileSdk = 34
buildFeatures {
buildConfig = true
}
defaultConfig {
minSdk = 24
testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
consumerProguardFiles("consumer-rules.pro")
ksp {
arg("room.schemaLocation", "$projectDir/schemas")
arg("room.incremental", "true")
arg("room.generateKotlin", "true")
}
}
buildTypes {
release {
isMinifyEnabled = false
proguardFiles(
getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro"
)
}
}
compileOptions {
sourceCompatibility = JavaVersion.VERSION_17
targetCompatibility = JavaVersion.VERSION_17
}
}
dependencies {
add("kspAndroid", libs.androidx.room.compiler)
}