Kotlin native link error on macOS, does that ring ...
# multiplatform
j
Kotlin native link error on macOS, does that ring a bell ?
Copy code
./gradlew :linkDebugExecutableMacosX64 
:compileKotlinMacosX64 UP-TO-DATE
The /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld command returned non-zero exit code: 1.	
output:	
-macosx_version_min has been renamed to -macos_version_min	
ld: unknown options: -sdk_version
j
No idea what exactly injects the -macosx_version_min instead of -macos_version_min; but if you add "-Xverbose-phases=Linker" to the linker flags (most probably by adding
freeCompilerArgs = listOf("-Xverbose-phases=Linker")
to the binaries { ... } thing in the build.gradle.kts), it should at least show you the command line and it will be a bit easier to debug where the offending switch comes from?
j
apparently a bug that was fixed in kotlin 1.9.10 https://youtrack.jetbrains.com/issue/KT-60230