Zhang Zihan
04/26/2025, 6:51 AMcom.android.kotlin.multiplatform.library
incompatible with applyDefaultHierarchyTemplate
? I used the following code:
kotlin {
@OptIn(ExperimentalKotlinGradlePluginApi::class)
applyDefaultHierarchyTemplate {
common {
group("java") {
withAndroidTarget()
withJvm()
}
}
}
}
But it doesn't seem to work, androidMain
is not successfully included in javaMain
. I can't import the dependencies added to javaMain
in androidMain
.
kotlin {
sourceSets {
getByName("javaMain").dependencies {
implementation(libs.jna.platform)
}
}
}