Undefined symbol: _OBJC_CLASS_$_ZoomVideoSDK

OK, I posted a few days ago re: audio and video issues with android and integrating the Video SDK into a custom app, which I managed to solve.

Currently trying to compile and build on an iMac to build an iOS version of the same app, and following the instructions.

I use VS Code for the most part on the mac, and I’m got it configured with yarn, so in my root app directory, I run

yarn run ios

it starts my iphone emulator, and tries to build the app, but fails with these error message (in Xcode, or in cmdline)

** CMD line error output **

Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_ZoomVideoSDKVideoPreferenceSetting", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkVideoHelper.o)
  "_OBJC_CLASS_$_ZoomVideoSDKSessionContext", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKInitParams", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKVideoOptions", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKAudioOptions", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKExtendParams", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDK", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkAudioHelper.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkCmdChannel.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkLiveStreamHelper.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkSession.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkLiveTranscriptionHelper.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkSessionStatisticsInfo.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkUserHelper.o)
      ...
ld: symbol(s) not found for architecture x86_64

XCode error output

Undefined symbol: _OBJC_CLASS_$_ZoomVideoSDKVideoPreferenceSetting
Undefined symbol: _OBJC_CLASS_$_ZoomVideoSDKSessionContext
Undefined symbol: _OBJC_CLASS_$_ZoomVideoSDKInitParams
Undefined symbol: _OBJC_CLASS_$_ZoomVideoSDKVideoOptions
Undefined symbol: _OBJC_CLASS_$_ZoomVideoSDKAudioOptions
Undefined symbol: _OBJC_CLASS_$_ZoomVideoSDKExtendParams

I’ve seen hints re: running pod install with the arch x86_64 but I don’t have an M1 chip, I have an i5 and installing Rosetta isn’t an option

Screenshot from 2023-01-24 16-39-18

1 Like

I tend to see this with my M1 Mac, and Rosetta does fix it -but in your case, I’m not sure. Have you tried using a physical device to see if that also fails?

Sadly at the moment, I can’t connect with a physical device. I work remote, and the closest mac I have access to is a 4 hour drive. I managed to get this working in the Zoom sample app with an emulator. I have no reason to understand why it’s failing with my own app.

1 Like

Thanks for the context - I’ll see if I can find the right person to help out.

1 Like

Any update? I’ve been going over the code with a fine-toothed comb, and it’s still making no sense…

Haven’t heard back - I’ll ask in a couple other places and see if anyone can help out more than me.

Hello @DanPiccolo ,

Would you please try to modify the Build Settings → Excluded Architectures option, add the Any iOS Simulator SDK option, and set the value to arm64


and add the following code in Podfile:

post_install do |installer|
  installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
      config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = "arm64"
    end
  end
end

It might help you solve this issue.
Thank you

Elaine

I will try that now.

There is an existing post_install… integrate the suggested code into it? or is it separate. I am NO expert on Podfiles

Existing code:

  post_install do |installer|
    react_native_post_install(
      installer,
      # Set `mac_catalyst_enabled` to `true` in order to apply patches
      # necessary for Mac Catalyst builds
      :mac_catalyst_enabled => false
    )
   end

I tried both, a separate post_install, and integrating it like so:

post_install do |installer|
    react_native_post_install(
      installer,
      # Set `mac_catalyst_enabled` to `true` in order to apply patches
      # necessary for Mac Catalyst builds
      :mac_catalyst_enabled => false
    )

    installer.pods_project.targets.each do |target|
      target.build_configurations.each do |config|
        config.build_settings['EXCLUDED_ARCHS[sdk=iphonesimulator*]'] = "arm64"
      end
    end
   end

and I still get the same errors (which is weird, as i have an iMac with an i5 chip, not an M1:

Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_ZoomVideoSDKVideoPreferenceSetting", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkVideoHelper.o)
  "_OBJC_CLASS_$_ZoomVideoSDKSessionContext", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKInitParams", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKVideoOptions", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKAudioOptions", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDKExtendParams", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdk.o)
  "_OBJC_CLASS_$_ZoomVideoSDK", referenced from:
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkAudioHelper.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkCmdChannel.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkLiveStreamHelper.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkSession.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkLiveTranscriptionHelper.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkSessionStatisticsInfo.o)
      objc-class-ref in libreact-native-zoom-video-sdk.a(RNZoomVideoSdkUserHelper.o)
      ...
ld: symbol(s) not found for architecture x86_64

@DanPiccolo had you run the pod install again after updating the podfiles? Also, would you please check whether you’ve added $(inherited) in the Other Linker Flags under Build Settings >> Linking
Thank you

Elaine

Hi Elaine,

I tried your suggestions with no luck. I always remove my Pods and re-run pod install just in case.

I ended up finding out why, by going line by line in the workspace, and comparing it to the Sample app, and another app I found that worked on iOS. Turns out I was missing a linkage to the ZoomVideoSDK.xcframework being explicitly defined in my app workspace in the Frameworks, Libraries and Embedded Content section

2 Likes

Did you get the react native video sdk to work on an ios emulator? I have only been able to get it to compile and run on a physical device.

Hi Samuel,

I did get it to run on the emulator, but in my situation, audio, and video don’t work on the emulator… so you can’t unmute your session on the emulator, or turn on a video stream. You can RECEIVE video and audio on the emulator.

I see. Thanks for the reply.

This topic was automatically closed after 30 days. New replies are no longer allowed.