An error occurs when run iOSApp in KMM(Android studio), Could not able to configure schema. please see the attachment.
Could not able run iOSApp in Kotlin multiplatform in Android Studio
Asked Answered
Hello, @Gan! Please check this particular .xcodeproj file presence. If it exists, try opening it with the Xcode and build from there, just to check if it was not broken during the download or whatever. –
Comment
Go to XCode > Preferences > Locations > Command Line Tools
=> Select desired version of Xcode. This worked for me.
This helps to fix "Error: Could not detect version of installed Xcode"! You may need to restart android studio after doing this. –
Khalsa
Thanks @Nilay-Dagdemir. Note: Even if it is already selected, you just need to reselect the Xcode again and then restart the Android Studio. –
Salford
Run in console
xcode-select --print-path
I got this result
/Library/Developer/CommandLineTools
And it should be something like
/Applications/Xcode${xcode-number}/Xcode.app
So run in console
cd /Applications
Then run in console
ls -la
If you see Xcode.app
- Then you run example 1 in console
Else if you see something like
Xcode 8.0.3
- Then you run example 2 in console
Now you should run this in console
sudo xcode-select -switch ${path-to-xcode.app}/Xcode.app
example 1
sudo xcode-select -switch /Applications/Xcode.app
example 2
sudo xcode-select -switch /Applications/Xcode 8.0.3/Xcode.app
Update:
I also found this https://youtrack.jetbrains.com/issue/KT-41691
This also helps to fix "Error: Could not detect version of installed Xcode"! –
Amylene
© 2022 - 2024 — McMap. All rights reserved.