Trying to figure out how to even start debugging this issue. I'm using Google VR on Unity, deploying to xcode for the build to iOS devices. I"ve opened the workspace instead of the project in xcode as referenced in:
Xcode Project vs. Xcode Workspace - Differences
I've attempted to fix as referenced in:
Duplicate Symbols for Architecture arm64
Still getting the same error and have no idea where to go from here.
duplicate symbol _OBJC_CLASS_$_DeviceParamsSyncHelper in:
/Users/OriginDevIT/Documents/ODIT_ARVR/GP_Excel/builds/ios/V1.9.11.b11/Pods/GVRSDK/Libraries/libGVRSDK.a(DeviceParamsSyncHelper.mm.o)
/Users/OriginDevIT/Documents/ODIT_ARVR/GP_Excel/builds/ios/V1.9.11.b11/Libraries/Plugins/iOS/libgvrunity.a(DeviceParamsSyncHelper.mm.o)
duplicate symbol _OBJC_METACLASS_$_DeviceParamsSyncHelper in:
/Users/OriginDevIT/Documents/ODIT_ARVR/GP_Excel/builds/ios/V1.9.11.b11/Pods/GVRSDK/Libraries/libGVRSDK.a(DeviceParamsSyncHelper.mm.o)
/Users/OriginDevIT/Documents/ODIT_ARVR/GP_Excel/builds/ios/V1.9.11.b11/Libraries/Plugins/iOS/libgvrunity.a(DeviceParamsSyncHelper.mm.o)
ld: 2087 duplicate symbols for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Related
Does anyone know a solution to below error https://pastebin.com/1nd0hkcF.
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I have successfully ran Unity iOS version on simulator, but running it on a real device throws out an error about some missing symbols from 64arm architecture.
I have tried everything from relinking stuff, downgrading, changing bitcode, architectures. It just keeps throwing the same missing symbol arm64 and linker error after.
I am developing an app using the Ionic 4 framework and am currently attempting to build it for iOS and release it to the App Store. The error I am getting is when I attempt to run the app in Xcode, it will fail in the linking phase with the following error:
ld: 346 duplicate symbols for architecture x86_64 clang: error: linker
command failed with exit code 1 (use -v to see invocation).
This is preceded by a list of the duplicate symbols like so:
duplicate symbol _OBJC_IVAR_$_FIRInstanceIDURLQueryItem._name in:
/Users/james/Library/Developer/Xcode/DerivedData/Jambox-ataoinheliizvyaczvbklhkqvhpf/Build/Products/Debug-iphonesimulator/FirebaseInstanceID/libFirebaseInstanceID.a(FIRInstanceIDURLQueryItem.o)
Jambox/Plugins/cordova-plugin-firebase/FirebaseInstanceID.framework/FirebaseInstanceID(FIRInstanceIDURLQueryItem_ce817fff617a4255d51c2a25da32a1f0.o)
These are relating to the following frameworks:
FirebaseInstanceID.framework
GoogleUtilities.framework
nanopb.framework
FirebaseCore.framework
I have tried a few solutions to this problem, but none result in success:
1). Removing -ObjC and $(inherited) from Other Linker Flags - this causes the app to build and link successfully, but crash on startup with this error:
*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '+[FIRApp
registerAsConfigurable:]: unrecognized selector sent to class
0x1080bc178'
2). Removing each framework in the list of duplicate symbols - this helps in lowering the number of duplicate symbols. I can get it down to 65 duplicate symbols until I have to remove GoogleUtilities.framework, which causes the build the fail with this error:
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_GULObjectSwizzler", referenced from:
objc-class-ref in FirebasePerformance(FPRObjectInstrumentor_f65d32035cadef24185912716f0b12f9.o)
objc-class-ref in FirebasePerformance(FPRNetworkTrace_3053ec2ab59f2fcfec4b18c29e4b4cec.o)
objc-class-ref in FirebasePerformance(FPRNSURLConnectionInstrument_5611d225f62417fa73742554b6a45401.o)
ld: symbol(s) not found for architecture x86_64 clang: error: linker
command failed with exit code 1 (use -v to see invocation)
3). Deleting DerivedData folder - I get the same errors after doing this.
4). Removing and adding the iOS platform - Same errors.
In my case, this problem arose when using phonegap-plugin-push and cordova-plugin-firebase-analytics together. I found the fix in this issue thread.
Basically, go to your Project Navigator in Xcode, then 'Build Phases', expand 'Link Binary With Libraries', click '+' and Add 'libGoogleToolboxForMac.a' and 'libPodsYourProjectName.a' and redo the build.
I've a unique problem. I'm including the AppRTC in my project via. podfile. It is successfully getting installed and along with it libjingle_peerconnection and SocketRocket libraries are also getting installed. However when I build my project it shows duplicate symbol error for libWebRTC.a and gives the following message -->
duplicate symbol _RTCFileName in:
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(libjingle_peerconnection_objc.RTCLogging.o)
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(rtc_base_objc.RTCLogging.o)
duplicate symbol _RTCLogEx in:
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(libjingle_peerconnection_objc.RTCLogging.o)
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(rtc_base_objc.RTCLogging.o)
duplicate symbol _RTCSetMinDebugLogLevel in:
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(libjingle_peerconnection_objc.RTCLogging.o)
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(rtc_base_objc.RTCLogging.o)
duplicate symbol __Z27RTCGetNativeLoggingSeverity18RTCLoggingSeverity in:
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(libjingle_peerconnection_objc.RTCLogging.o)
(My project path)/Pods/libjingle_peerconnection/libjingle_peerconnection/libWebRTC.a(rtc_base_objc.RTCLogging.o)
ld: 4 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I've tried everything related to this but with no success. So please help me to solve it or atleast tell why this is happening.
When project is working fine when I try to run in simulator. However, when I try to archive the project, I got the follow error. The code is too long. I just putting some part of it.
duplicate symbol l017 in:
GoogleMobileAds.framework/GoogleMobileAds(GADBannerAdViewDelegate.o)
GoogleMobileAds(GADRewardBasedVideoAd+Mediation.o)
duplicate symbol l018 in:
GoogleMobileAds.framework/GoogleMobileAds(GADCSITimeRecorder.o)
GoogleMobileAds.framework/GoogleMobileAds(GADRewardBasedVideoAd+Mediation.o)
duplicate symbol l008 in:
GoogleMobileAds.framework/GoogleMobileAds(GADNativeAdAttributionView.o)
GoogleMobileAds.framework/GoogleMobileAds(GADPushTransitionView.o)
duplicate symbol l014 in:
GoogleMobileAds.framework/GoogleMobileAds(GADPinger.o)
GoogleMobileAds.framework/GoogleMobileAds(GADAdAppViewController.o)
ld: 28 duplicate symbols for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
How to solve this?
Problem solved by removing the "-ObjC" linker flag.
I'm using Xcode Version 6.0.1 (6A317)and stuck with Apple Mach-O error for a long time. I get this error once I introduce SocketRocket project.
duplicate symbol _OBJC_IVAR_$_AppDelegate._window in:
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/AppDelegate-113CA4C4B5D4CC68.o
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/AppDelegate-D68FF7E1CDB59174.o
duplicate symbol _OBJC_METACLASS_$_AppDelegate in:
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/AppDelegate-113CA4C4B5D4CC68.o
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/AppDelegate-D68FF7E1CDB59174.o
duplicate symbol _OBJC_CLASS_$_AppDelegate in:
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/AppDelegate-113CA4C4B5D4CC68.o
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/AppDelegate-D68FF7E1CDB59174.o
duplicate symbol _OBJC_CLASS_$_ViewController in:
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/ViewController-7B952F801D984E6D.o
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/ViewController-99529767CD55CC78.o
duplicate symbol _OBJC_METACLASS_$_ViewController in:
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/ViewController-7B952F801D984E6D.o
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/ViewController-99529767CD55CC78.o
duplicate symbol _main in:
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/main-B74D1ABF07758C74.o
/Users/anuradhavasudeva/Desktop/Buzz/Complete/CWPAYou/Build/Intermediates/CWPAYou.build/Debug-iphonesimulator/CWPAYou.build/Objects-normal/i386/main-F48A7B3907D55170.o
ld: 6 duplicate symbols for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I have made sure to follow the steps given in https://github.com/square/SocketRocket
the only exception I see is SocketRocket.framework was showing red when I tried adding it under + Link Binary with libraries.
I have added the following libraries:
Security.Framework
CFNetwork.Framework
UIKit.Framework
Foundation.Framework
libicucore.dylib
libsocketrocket.a
libresolv.dylib
I've set other linker flags to -ObjC
Build Active Architecture only - No, because setting it to Yes throws an error : Check dependencies. No architectures to compile for (ONLY_ACTIVE_ARCH=YES, active arch=x86_64, VALID_ARCHS=i386).
Valid Architectures - armv64 armv7 armv7s
This issue is really killing my time. I tried to follow other posts but nothing could help me solve the issue!
1.- Are you importing a .m file inside another .m file instead of the Header? It happens by mistake some times and causes that issue.
2.- Check in your Compile Sources under Build Phases that you are not including same file 2 times although from the looks of it this doesn't seem the problem.
3.- If all else fails. Clean DerivedData folder for the project in Organizer. Clean and re-build.