Hi devs! I create a new multiplatform project with...
# kotlin-native
f
Hi devs! I create a new multiplatform project with Android and IOS. (It show a current platform) At android run perfectly but when I run the code on Xcode I have an error: /Users/.../Xcode/DerivedData/iosApp-axkbbwgyarknnvehlgjsmvkylxqc/Build/Intermediates.noindex/iosApp.build/Debug-iphonesimulator/app.build/Script-F861D812207FA4320085E80D.sh: line 2: /Users/dev/Documents/MultiplatformTest/iosApp/../gradlew: No such file or directory What a file I need? Where can get it?
a
Hello! It has to be generated during the
packForXcode
task or made by hands calling
gradle wrapper
command in your project directory. To be fair, this is kinda strange that you haven’t got it by default. How did you create this project? I suppose it was not made by some kind of wizard or based on a sample from the K/N repository, isn’t it?
f
I just create a new Multiplatform project with Idea's wizzard
a
Ok. It looks like you used the “Mobile Android/iOS project” (please tell me if I’m wrong). In this project build.gradle file you can find some commentary about “//Before opening the project from iosApp directory in Xcode, // make sure all Gradle infrastructure exists (gradle.wrapper, gradlew).” This means that you got to execute gradle wrapper task before opening the project. I recommend you to do it via command-line, and try to open the Xcode again. To learn more about this gradlew, check Gradle official documentation (https://docs.gradle.org/current/userguide/gradle_wrapper.html)
f
Yes! Thank you! It work!
🎉 2