Adrian Witaszak
02/15/2022, 5:28 PM** BUILD FAILED **
The following build commands failed:
PhaseScriptExecution Run\ Script /Users/adrianwitaszak/Projects/KMP/MyApplication/build/ios/iosApp.build/Debug-iphonesimulator/iosApp.build/Script-7555FFB5242A651A00829871.sh (in target 'iosApp' from project 'iosApp')
> Task :shared:linkDebugFrameworkIosX64 FAILED
e: Compilation failed: Could not initialize class llvm.llvm
* Source files:
* Compiler version info: Konan: 1.6.10 / Kotlin: 1.6.10
* Output kind: FRAMEWORK
e: java.lang.NoClassDefFoundError: Could not initialize class llvm.llvm
Big Chungus
02/15/2022, 5:57 PMAdrian Witaszak
02/15/2022, 6:00 PMBig Chungus
02/15/2022, 6:00 PMAdrian Witaszak
02/15/2022, 6:03 PMBig Chungus
02/15/2022, 6:05 PMBig Chungus
02/15/2022, 6:06 PMAdrian Witaszak
02/15/2022, 6:14 PMAdrian Witaszak
02/15/2022, 6:21 PM> Task :shared:linkDebugFrameworkIosX64 FAILED
e: Compilation failed: Could not initialize class llvm.llvm
* Source files:
* Compiler version info: Konan: 1.6.10 / Kotlin: 1.6.10
* Output kind: FRAMEWORK
Adrian Witaszak
02/15/2022, 6:21 PMe: java.lang.NoClassDefFoundError: Could not initialize class llvm.llvm
Adrian Witaszak
02/15/2022, 6:22 PMBUILD FAILED in 1s
2 actionable tasks: 1 executed, 1 up-to-date
Command PhaseScriptExecution failed with a nonzero exit code
** BUILD FAILED **
The following build commands failed:
PhaseScriptExecution Run\ Script /Users/adrianwitaszak/Projects/KMP/MyApplication/build/ios/iosApp.build/Debug-iphonesimulator/iosApp.build/Script-7555FFB5242A651A00829871.sh (in target 'iosApp' from project 'iosApp')
(1 failure)
Big Chungus
02/15/2022, 6:22 PMAdrian Witaszak
02/15/2022, 6:23 PMAdrian Witaszak
02/15/2022, 6:28 PM> Task :shared:linkDebugFrameworkIosX64 FAILED
e: Compilation failed: Can't load library: /Users/adrianwitaszak/.konan/kotlin-native-prebuilt-macos-x86_64-1.6.0/konan/nativelib/13622981358584302003/libllvmstubs.dylib
* Source files:
* Compiler version info: Konan: 1.6.0 / Kotlin: 1.6.0
* Output kind: FRAMEWORK
e: java.lang.UnsatisfiedLinkError: Can't load library: /Users/adrianwitaszak/.konan/kotlin-native-prebuilt-macos-x86_64-1.6.0/konan/nativelib/13622981358584302003/libllvmstubs.dylib
Adrian Witaszak
02/15/2022, 6:29 PMFAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':shared:linkDebugFrameworkIosX64'.
> Compilation finished with errors
BUILD FAILED in 7s
2 actionable tasks: 2 executed
Command PhaseScriptExecution failed with a nonzero exit code
** BUILD FAILED **
The following build commands failed:
PhaseScriptExecution Run\ Script /Users/adrianwitaszak/Projects/KMP/MyApplication/build/ios/iosApp.build/Debug-iphonesimulator/iosApp.build/Script-7555FFB5242A651A00829871.sh (in target 'iosApp' from project 'iosApp')
(1 failure)
Big Chungus
02/15/2022, 6:46 PMBig Chungus
02/15/2022, 6:47 PMBig Chungus
02/15/2022, 6:48 PMAdrian Witaszak
02/15/2022, 7:30 PMBig Chungus
02/15/2022, 8:02 PMArtyom Degtyarev [JB]
02/16/2022, 7:16 AMRun Script
.Adrian Witaszak
02/16/2022, 8:11 AMArtyom Degtyarev [JB]
02/16/2022, 8:48 AMAdrian Witaszak
02/16/2022, 6:12 PMThe following build commands failed:
PhaseScriptExecution Run\ Script /Users/adrianwitaszak/Projects/KMP/testapp/build/ios/iosApp.build/Debug-iphonesimulator/iosApp.build/Script-7555FFB5242A651A00829871.sh (in target 'iosApp' from project 'iosApp')
(1 failure)
Adrian Witaszak
02/16/2022, 6:13 PM> Task :shared:linkDebugFrameworkIosX64 FAILED
e: Compilation failed: Could not initialize class llvm.llvm
* Source files:
* Compiler version info: Konan: 1.6.10 / Kotlin: 1.6.10
* Output kind: FRAMEWORK
e: java.lang.NoClassDefFoundError: Could not initialize class llvm.llvm
Adrian Witaszak
02/16/2022, 6:14 PMAdrian Witaszak
02/16/2022, 6:14 PMBig Chungus
02/16/2022, 6:15 PMArtyom Degtyarev [JB]
02/16/2022, 6:23 PMAdrian Witaszak
02/16/2022, 6:41 PM> Task :shared:linkDebugFrameworkIosX64 FAILED
e: Compilation failed: /Users/adrianwitaszak/.konan/kotlin-native-prebuilt-macos-x86_64-1.6.10/konan/nativelib/6012039609168293530/libllvmstubs.dylib: dlopen(/Users/adrianwitaszak/.konan/kotlin-native-prebuilt-macos-x86_64-1.6.10/konan/nativelib/6012039609168293530/libllvmstubs.dylib, 0x0001): Library not loaded: @rpath/libc++.1.dylib
Referenced from: /Users/adrianwitaszak/.konan/kotlin-native-prebuilt-macos-x86_64-1.6.10/konan/nativelib/6012039609168293530/libllvmstubs.dylib
Reason: tried: '/Library/Java/JavaVirtualMachines/jdk-11.0.14.jdk/Contents/Home/lib/server/./libc++.1.dylib' (no such file), '/Library/Java/JavaVirtualMachines/jdk-11.0.14.jdk/Contents/Home/lib/server/../libc++.1.dylib' (no such file), '/Library/Java/JavaVirtualMachines/jdk-11.0.14.jdk/Contents/Home/bin/../lib/jli/libc++.1.dylib' (no such file)
Adrian Witaszak
02/16/2022, 6:41 PMAdrian Witaszak
02/16/2022, 6:52 PMKagurazaka Tsuki
02/17/2022, 2:08 AMKagurazaka Tsuki
02/17/2022, 2:10 AMsvyatoslav.scherbina
02/17/2022, 8:26 AMinstall_name_tool -change @rpath/libc++.1.dylib /usr/lib/libc++.1.dylib ~/.konan/kotlin-native-prebuilt-macos-x86_64-1.6.10/konan/nativelib/libllvmstubs.dylib
./gradlew --stop
and try to compile the project again?
You might need to change the version in the Kotlin/Native path in the first command.svyatoslav.scherbina
02/17/2022, 12:10 PMAdrian Witaszak
02/17/2022, 4:19 PMKagurazaka Tsuki
02/17/2022, 5:50 PMsvyatoslav.scherbina
02/18/2022, 6:46 AM