[Build] Update native targets to target specific native targets instead of basing it of the host

* For now this includes windows x64, linux x64 and linux arm64
This commit is contained in:
hartie95 2024-02-19 18:59:17 +01:00
parent 1950a70e71
commit 62c72e24e0

View File

@ -30,15 +30,9 @@ 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.")
}
mingwX64()
linuxX64()
linuxArm64()
sourceSets {
@ -72,7 +66,5 @@ kotlin {
}
val jsMain by getting
val jsTest by getting
val nativeMain by getting
val nativeTest by getting
}
}