ribesg
06/03/2019, 8:50 AM> Task :linkTestDebugExecutableIosSim
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_UIDevice", referenced from:
objc-class-ref in combined.o
ld: symbol(s) not found for architecture x86_64
e: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld invocation reported errors
Occurred after adding some imports for platform.UIKit.<stuff>
in a filesvyatoslav.scherbina
06/03/2019, 8:53 AMribesg
06/03/2019, 8:55 AMribesg
06/03/2019, 10:11 AMsvyatoslav.scherbina
06/03/2019, 10:47 AMribesg
06/03/2019, 1:16 PMsvyatoslav.scherbina
06/03/2019, 1:19 PMBut why does it fail to compile the test debug executable? The test sources don’t have UIKit imports and don’t use the main file which contains the importBecause test debug executable contains compiled main sources.
ribesg
06/03/2019, 1:19 PMsvyatoslav.scherbina
06/03/2019, 1:21 PM-framework UIKit
link options manually.
See linkerOpts
here: https://kotlinlang.org/docs/reference/building-mpp-with-gradle.html#using-kotlinnative-targetsribesg
06/03/2019, 1:22 PMbinaries
framework
block, but here I don’t have that, so I need to search for the binary and apply that in my Gradle file, right?svyatoslav.scherbina
06/03/2019, 1:24 PMribesg
06/03/2019, 1:34 PMbinaries.getByName("testDebugExecutable").linkerOpts("-framework UIKit")