i have a kmp framework where i include a swift fil...
# compose-ios
j
i have a kmp framework where i include a swift file (with @objc notation) so i can use it from ios/kotlin. It works fine, but when i want to use the exported framework outside of kmp, just in a straight ios project, I get an error
Copy code
Undefined symbols for architecture arm64:
  "_OBJC_CLASS_$_CameraController", referenced from:
in Test[2](Test.framework.o)
Has anyone run into this?
p
Is the framework exporting the swift file with it ?
Otherwise you might need to use a plugin that includes the swift files in the framework. By default the KMP Gradle plugin won't do it
j
That seems to be an issue. It's in compile sources, but it it not exported in the framework. The bridge header works, and I can use it in Kotlin, just can't in ios.
j
thanks, i'll check those out 👍
👍 1