plugins { alias(libs.plugins.kotlinMultiplatform) alias(libs.plugins.jetbrainsCompose) alias(libs.plugins.composeCompiler) alias(libs.plugins.kotlinSerialization) alias(libs.plugins.androidKotlinMultiplatformLibrary) } kotlin { android { namespace = "com.sangita.grantha.shared.presentation" compileSdk = 37 minSdk = 24 withHostTest {} compilerOptions { jvmTarget.set(org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_17) } } // Fast presenter tests without a device. UI execution remains Android/iOS hosts. jvm() // iosX64 (Intel simulator) dropped: Compose Multiplatform 1.11+ no longer // publishes x64 iOS artifacts. iosArm64() iosSimulatorArm64() jvmToolchain(25) // -Xexplicit-backing-fields removed: part of the language since Kotlin 2.4 // (the flag now only emits a redundancy warning — zero-warnings target). sourceSets { commonMain.dependencies { api(project(":modules:shared:domain")) api(project(":modules:shared:mobile-data")) implementation(libs.compose.runtime) implementation(libs.compose.foundation) implementation(libs.compose.material3) implementation(libs.compose.material.icons.extended) implementation(libs.compose.ui) implementation(libs.compose.components.resources) implementation(libs.compose.ui.backhandler) implementation(libs.androidx.lifecycle.runtime.compose) implementation(libs.androidx.navigationevent.compose) implementation(libs.kotlinx.coroutines.core) implementation(libs.kotlinx.datetime) implementation(libs.kotlinx.serialization.json) } commonTest.dependencies { implementation(kotlin("test")) implementation(libs.kotlinx.coroutines.test) } androidMain.dependencies { implementation(libs.ktor.client.okhttp) implementation(libs.androidx.activity.compose) implementation(libs.androidx.core.ktx) } } targets.withType(org.jetbrains.kotlin.gradle.plugin.mpp.KotlinNativeTarget::class.java) .configureEach { binaries.framework { baseName = "presentation" isStatic = false } binaries.all { if (buildType.name.equals("DEBUG", ignoreCase = true)) { // 'none' renamed to 'noop' in Kotlin/Native 2.4 freeCompilerArgs += listOf("-Xbinary=sourceInfoType=noop") } } } } compose { resources { publicResClass = true packageOfResClass = "com.sangita.grantha.shared.presentation" } }