plugins { kotlin("multiplatform") version "1.6.10" } group = "fi.schro" version = "0.0.1" repositories { mavenCentral() } kotlin { val hostOs = System.getProperty("os.name") val isMingwX64 = hostOs.startsWith("Windows") val nativeTarget = when { hostOs == "Mac OS X" -> macosX64("native") hostOs == "Linux" -> linuxX64("native") isMingwX64 -> mingwX64("native") else -> throw GradleException("Host OS is not supported in Kotlin/Native.") } nativeTarget.apply { binaries { executable { entryPoint = "fi.schro.main" } } } sourceSets { val nativeMain by getting { dependencies { implementation("io.insert-koin:koin-core:3.1.5") implementation("com.github.ajalt.clikt:clikt:3.4.0") } } val nativeTest by getting } }