Zoltan Demant
04/08/2025, 4:27 PMZoltan Demant
04/08/2025, 4:29 PMbuild.gradle.kts
file:
plugins {
alias(config.plugins.multiplatform.android)
alias(config.plugins.multiplatform.jvm)
}
kotlin {
sourceSets.commonMain.dependencies {
api(config.aggregate.core)
implementation(libs.coroutines)
}
}
config.plugins.multiplatform.x
are convention plugins that I share between my projects, containing stuff like:
configure<KotlinMultiplatformExtension> {
applyDefaultHierarchyTemplate()
compilerOptions {
freeCompilerArgs.addAll(CompilerArgs)
}
}
val CompilerArgs =
listOf(
"-Xskip-prerelease-check",
"-Xexpect-actual-classes",
"-Xcontext-receivers",
"-opt-in=kotlinx.coroutines.ExperimentalCoroutinesApi",
)
And jvm() android()
etc.
Im really clueless unfortunately, this project is even just a subset of the whole project - ironically to speed up build times when developing a subset of its features.Andrey Beryukhov
04/08/2025, 5:00 PMZoltan Demant
04/08/2025, 5:11 PMephemient
04/08/2025, 5:50 PMZoltan Demant
04/09/2025, 2:55 AMkotlin.compiler.execution.strategy=in-process
(I added this yesterday after asking AI about the issues).
One of my convention plugins for multiplatform adds (by mistake) android-library to every module its applied to. Ive been using this for a lot of projects, I think the extra time just grows exponentially due to this project being ridiculous in size.
These two tweaks brought the build time down from 5 minutes to 5 seconds. thank you color