https://kotlinlang.org logo
#multiplatform
Title
# multiplatform
m

Maurice Jouvet

08/25/2020, 1:38 PM
Hi, I am using KaMPKit and I have this issue when Building on iOS. Command PhaseScriptExecution failed with a nonzero exit code Do you know what is the pb?
1
s

Sebastien Leclerc Lavallee

08/25/2020, 1:39 PM
You have to check the Xcode error output to see which script failed and it will have an error message there. You’ll have more information.
m

Maurice Jouvet

08/25/2020, 1:47 PM
Hum.. I really don't know.. Here what I found.
/bin/sh -c /Users/mo/Library/Developer/Xcode/DerivedData/BlueKanGoiOS-fitfkqbarhmtjxdgiomdtzghdkmy/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/shared.build/Script-46EB2E000002F0.sh
REPO_ROOT="$PODS_TARGET_SRCROOT"
"$REPO_ROOT/../gradlew" -p "$REPO_ROOT" :shared:syncFramework                     -Pkotlin.native.cocoapods.target=$KOTLIN_TARGET                     -Pkotlin.native.cocoapods.configuration=$CONFIGURATION                     -Pkotlin.native.cocoapods.cflags="$OTHER_CFLAGS"                     -Pkotlin.native.cocoapods.paths.headers="$HEADER_SEARCH_PATHS"                     -Pkotlin.native.cocoapods.paths.frameworks="$FRAMEWORK_SEARCH_PATHS"
> Task :buildSrc:compileKotlin UP-TO-DATE
> Task :buildSrc:compileJava NO-SOURCE
> Task :buildSrc:compileGroovy NO-SOURCE
> Task :buildSrc:pluginDescriptors UP-TO-DATE
> Task :buildSrc:processResources NO-SOURCE
> Task :buildSrc:classes UP-TO-DATE
> Task :buildSrc:inspectClassesForKotlinIC UP-TO-DATE
> Task :buildSrc:jar UP-TO-DATE
> Task :buildSrc:assemble UP-TO-DATE
> Task :buildSrc:compileTestKotlin NO-SOURCE
> Task :buildSrc:pluginUnderTestMetadata UP-TO-DATE
> Task :buildSrc:compileTestJava NO-SOURCE
> Task :buildSrc:compileTestGroovy NO-SOURCE
> Task :buildSrc:processTestResources NO-SOURCE
> Task :buildSrc:testClasses UP-TO-DATE
> Task :buildSrc:test NO-SOURCE
> Task :buildSrc:validatePlugins UP-TO-DATE
> Task :buildSrc:check UP-TO-DATE
> Task :buildSrc:build UP-TO-DATE
> Configure project :shared
Kotlin Multiplatform Projects are an Alpha feature.
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':shared'.
> distribution
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
* Get more help at <https://help.gradle.org>
Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See <https://docs.gradle.org/6.5.1/userguide/command_line_interface.html#sec:command_line_warnings>
BUILD FAILED in 717ms
Command PhaseScriptExecution failed with a nonzero exit code
s

Sebastien Leclerc Lavallee

08/25/2020, 1:51 PM
We see it’s calling the
:shared:syncFramework
task and it fail here:
Copy code
> Configure project :shared
Kotlin Multiplatform Projects are an Alpha feature.
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':shared'.
> distribution
Unfortunately, we don’t have much more info 😅 Have you tried running
./gradlew build
at the root of the project?
k

kpgalligan

08/25/2020, 1:58 PM
I’m hitting the same issue trying to build for 1.4.0 currently
The gradlew works, but the Xcode doesn’t. That’s with our cocoapods fork. With the JB cocoapods it works (in 1.4.0). Today’s battle for me is that.
Stay tuned
s

Sebastien Leclerc Lavallee

08/25/2020, 1:59 PM
📻
m

Maurice Jouvet

08/25/2020, 2:06 PM
Same for me. 1.4.0 ^^
k

kpgalligan

08/25/2020, 2:07 PM
If you have the latest from this branch, it should work: https://github.com/touchlab/KaMPKit/tree/kpg/kotlin_140
It’s using the JB cocoapods plugin. That works, but doesn’t support features we want, so I need to poke around that today
m

Maurice Jouvet

08/25/2020, 2:08 PM
Nope I have an old one...
Ah ok, thanks, I'm going to check that.
z

zsperske

08/25/2020, 4:59 PM
Kevin, what are the features your fork supports that the JB plugin does not? Just curious
k

kpgalligan

08/25/2020, 5:01 PM
The JB fork version hides the framework config and reads it in an order that won’t let you change it. Originally we wanted to be able to have dynamic frameworks. Currently we want to have transitive kotlin modules exposed. There’s a good chance we’ll be moving away from dynamic frameworks, but that’s still up in the air.
Mispoke there. We’re the fork 🙂
z

zsperske

08/25/2020, 5:06 PM
cool, thanks for the explanation!
m

Maurice Jouvet

08/26/2020, 9:47 AM
Yes thank you! I am looking at the branch 140, I have a quick question, why coroutine and ktor-serialization for native are commented?
Ok my mistakes, I saw an old commit.
6 Views