diff --git a/lambda-runtime/build.gradle.kts b/lambda-runtime/build.gradle.kts index f88b250..51af335 100644 --- a/lambda-runtime/build.gradle.kts +++ b/lambda-runtime/build.gradle.kts @@ -12,21 +12,14 @@ plugins { } kotlin { - listOf( - macosArm64(), - macosX64(), - //linuxArm64() // https://youtrack.jetbrains.com/issue/KT-36871/Support-Aarch64-Linux-as-a-host-for-the-Kotlin-Native - linuxX64(), - ).forEach { - it.compilations.configureEach { - compileTaskProvider.configure { - compilerOptions { - freeCompilerArgs.addAll(listOf("-Xallocator=std", "-Xruntime-logs=gc=info")) + macosArm64() + macosX64() + //linuxArm64() // https://youtrack.jetbrains.com/issue/KT-36871/Support-Aarch64-Linux-as-a-host-for-the-Kotlin-Native + linuxX64() - //freeCompilerArgs = freeCompilerArgs + listOf("-Xallocator=std", "-Xruntime-logs=gc=info",) - } - } - } + @OptIn(ExperimentalKotlinGradlePluginApi::class) + compilerOptions { + freeCompilerArgs.addAll(listOf("-Xallocator=std", "-Xruntime-logs=gc=info")) } sourceSets { diff --git a/sample/build.gradle.kts b/sample/build.gradle.kts index 7550ee1..c7db8ff 100644 --- a/sample/build.gradle.kts +++ b/sample/build.gradle.kts @@ -14,6 +14,7 @@ kotlin { it.binaries { executable { entryPoint = "com.github.trueangle.knative.lambda.runtime.sample.main" + freeCompilerArgs += listOf("-Xallocator=std", "-Xruntime-logs=gc=info") } } }