I’m trying to build the template idea project Kotl...
# kotlin-native
g
I’m trying to build the template idea project Kotlin (Mobile Android/iOS). When I launch the gradle build I have this error:
Copy code
> Task :app:compileKotlinIos
xcrun: error: SDK "iphonesimulator" cannot be located
xcrun: error: SDK "iphonesimulator" cannot be located
xcrun: error: unable to lookup item 'Path' in SDK 'iphonesimulator'
exception: org.jetbrains.kotlin.konan.KonanExternalToolFailure: The /usr/bin/xcrun command returned non-zero exit code: 1.
        at org.jetbrains.kotlin.konan.exec.Command.handleExitCode(ExecuteCommand.kt:100)
        at org.jetbrains.kotlin.konan.exec.Command.getOutputLines(ExecuteCommand.kt:91)
XCode is installed and I can run the simulators from there. I don’t understand why the paths are not correct. Any idea?
s
Please try to launch Xcode first, it should propose installing some required components.
g
Launched XCode first without any proposal of any components. And I can build and run an sample project without problem.
message has been deleted
But I still have the error when launching gradle build.
Found the solution at the end of internet 😅. https://qiita.com/yoshinbo@github/items/8eb71d8015291ac6a3bc
👍 2