Hi can anyone help with this. `Getting Undefined ...
# kotlin-native
s
Hi can anyone help with this.
Getting Undefined symbol for architecture x86_64: _OBJC_CLASS_$
, trying to integrate Snowplow library
Copy code
Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_SPGlobalContext", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPStructured", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPSnowplow", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPGlobalContextsConfiguration", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPSelfDescribingJson", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPEmitterConfiguration", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPSessionConfiguration", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPTrackerConfiguration", referenced from:
      objc-class-ref in Felix(result.o)
  "_OBJC_CLASS_$_SPNetworkConfiguration", referenced from:
      objc-class-ref in Felix(result.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
https://youtrack.jetbrains.com/issue/KTIJ-23233/Getting-Undefined-symbol-for-architecture-x8664-OBJCCLASS-when-trying-to-compile-iOS-app
k
How are you integrating it? The error basically means the linker can’t find that binary. Generally, that means you’ve configured cinterop but not the binary part. I gave a talk that goes into this (somewhat) https://www.droidcon.com/2022/06/28/sdk-design-and-publishing-for-kotlin-multiplatform-mobile/.
The title is wrong on the site, though. Video has the actual title in it.
s
Thanks @kpgalligan, I will check this out
694 Views