Undefined symbols for architecture x86_64 iOS - ios

I have used cocoapods to install the upnpx library which successfully builds. But as soon as I went to build after using one of the classes In my project I am faced with this error:
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_UPnPManager", referenced from:
objc-class-ref in RendererView.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

SOLVED: For me, setting "Build active architectures only" to YES in build settings of the project target resolves this issue

Related

Undefined symbols for architecture x86_64: "_OBJC_CLASS_$_FIRAnalytics"

I know that this question has been asked before but I tried every possible solution shared online but still got the issue. First tried with pods and then moved the FirebaseAnalytics into SPM. "Build Active Architecture Only" is set NO. In framework search paths, $(inherited) value and $(PROJECT_DIR)/Frameworks are available due to the frameworks I use in pods and SPM.
This is the error I get when I import FirebaseAnalytics and call Analytics:
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_FIRAnalytics", referenced from:
objc-class-ref in SessionManager.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

CocoaPods not linking with the project

I have a project that uses CocoaPods. It was working but something got broken.
It does compile if I target the simulator, but If I target the devise (Build or Archive) it throws a linker error.
ld: warning: ignoring file /Users/myuser/ios/share/share/libPods.a, file was built for archive which is not the architecture being linked (armv7s): /Users/myuser/ios/share/share/libPods.a
Undefined symbols for architecture armv7s:
"_OBJC_CLASS_$_AFHTTPRequestOperationManager", referenced from:
objc-class-ref in BackendProxy.o
ld: symbol(s) not found for architecture armv7s
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I really need some help because I am really stucked.
Thanks!
EDIT: i deleted that libPods.a, that was an old one, and now it's giving me:
ld: library not found for -lPods
But only on Archive or Build for iosDevice, this is still working on the simulator.
Try removing armv7s from valid architectures section.
Build Settings -> Architectures -> Valid Architectures

iOS testflight sdk arm7 architecture issue

I have added test flight sdk to my project and after archive it I got this error:
ld: warning: ignoring file Include/libapps-on-maps-sim.a, file was built for archive which is not the architecture being linked (armv7): Include/libapps-on-maps-sim.a
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_TestFlight", referenced from:
objc-class-ref in MTAppDelegate.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
How can I change architecture for this file? I have architecture settings for my project and for pods $(ARCHS_STANDARD)

Unity 3.5.6 compile error on mac mini for iOS

I got compile error and do not know how to fix it:
Undefined symbols for architecture armv7:
"_mono_aot_module_Assembly_UnityScript_firstpass_info", referenced from:
RegisterMonoModules() in RegisterMonoModules.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
In build settings for valid architectures only armv7 choosen.
Solved by adding Assembly-UnityScript-firstpass.dll.s and Assembly-CSharp-firstpass.dll.s to xcode project

Undefined symbols for architecture i386 and symbol not found for architecture i386

I am developing a fake static framework. I build it and included it another sample application. The sample application is running fine on iPhone(ios 7.1), but it giving below errors when i run it on simulator
ld: warning: ignoring file /Users/awsuser8/Desktop/Test.framework/Test, file was built for archive which is not the architecture being linked (i386): /Users/awsuser8/Desktop/Test.framework/Test
Undefined symbols for architecture i386:
"_OBJC_CLASS_$_Test", referenced from:
objc-class-ref in ViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
You can rebuild the library for the iOS Simulator and combine it using lipo with the ARM build of the library. Then the library will support x86 builds as well.

Resources