Unable to compile with Objc+ project ARM architecture

Description
Hey guys,
We are unable to integrate iOS SDK into my existing Objective-C project using below instruction:

Our project has “arm64, arm64e, arm7, arm7s” architecture. When we compile our project, below error throws:

duplicate symbol _BTN_HEIGHT in:
/Users/user1/Documents/zoomProject.build/Objects-normal/arm64/SDKStartJoinMeetingPresenter+ShareServiceDelegate.o
/Users/user1/Documents/zoomProject/build/zoomProject.build/zoomProject-iphoneos/zoomProject.build/Objects-normal/arm64/MainViewController.o

ld: 30 duplicate symbols for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Which version?
v4.3.47201.0322

Hi erwolf,
Thanks for using Zoom SDK. Our demo app has the same architecture configure as yours thus the arch are supported. Could you verify the integration steps by following the doc here: https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/getting-started/integration? If the error stays, could you provide the steps of how to reproduce this error with our demo app?

Thanks!

Hi erwolf,

Thanks for your post. Just confirmed with our engineer. It seems like you have defined a constant called “BTN_HEIGHT”, which is used in our SDK and cause conflicts. Please try to rename the constant to something else to see if that helps.

Thanks!

Hi Carson,

On our end, we need to declare these constant variables to

#define SAFE_ZOOM_INSETS 34.0f
#define BTN_HEIGHT 24.0f

This works on our Xcode project.

Thanks.

@carson.zoom

After success compiling our project with MobileRTC framework, the app won’t be launched. Below message throws in console:

objc[628]: Class MWTapDetectingView is implemented in both /private/var/containers/Bundle/Application/6F95B7C7-AE72-47C7-9CCC-FEB79BBF7F86/MyApp.app/Frameworks/MobileRTC.framework/MobileRTC (0x106093e68) and /var/containers/Bundle/Application/6F95B7C7-AE72-47C7-9CCC-FEB79BBF7F86/MyApp.app/MyApp (0x1036b1018). One of the two will be used. Which one is undefined.

objc[628]: Class MWCaptionView is implemented in both /private/var/containers/Bundle/Application/6F95B7C7-AE72-47C7-9CCC-FEB79BBF7F86/MyApp.app/Frameworks/MobileRTC.framework/MobileRTC (0x106090a88) and /var/containers/Bundle/Application/6F95B7C7-AE72-47C7-9CCC-FEB79BBF7F86/MyApp.app/MyApp (0x1036b1888). One of the two will be used. Which one is undefined.

Can you investigate the reason ?

Thank you.

After adding -ObjC in other linker flag, the app works.

Hi erwolf,
Thanks for the reply and the details. Yes, we requires some configuration before deploying our SDK, please see https://marketplace.zoom.us/docs/sdk/native-sdks/iOS/getting-started/integration#5-deployment for more information.

Glad to hear that the app works. So is this problem resolved?

Thanks!

Yes, issue is resolved.

Thank you.

1 Like

Hi erwolf,

Glad to hear that the problem has been resolved. Please let us know if you have any other questions. Happy Zooming!

Thanks!

It is showing duplicate because they coded it incorrectly.

In .h file they declared

const CGFloat BTN_HEIGHT = 24;

then imported ThumbView.h file in many files and used BTN_HEIGHT.

Right Way to use this const is ---------------------

ThumbView.h
extern const CGFloat BTN_HEIGHT;

ThumbView.m
const CGFloat BTN_HEIGHT = 40;

Hi prince.kumar,

Thanks for the post and thanks for the advice. The ThumbView.h/.m only exists in our demo app(https://github.com/zoom/zoom-sdk-ios/blob/master/MobileRTCSample/MobileRTCSample/CustomMeeting/ThumbView.m) so it won’t impact the usage of our SDK.

Hope this helps. Thanks!