The following is the detailed error message I got while compiling a OpenCV project. Please help me out. Thanks a lot!
Undefined symbols for architecture x86_64:
"_cvFindFundamentalMat", referenced from:
testRigidRegistrationCode() in AugmentedReality.o
CamEgoMotion::step6_computeEssentialMatrix(CvMat*, CvMat*, bool*) in CameraEgomotion.o
"_cvComputeCorrespondEpilines", referenced from:
CamEgoMotion::step6_computeEssentialMatrix(CvMat*, CvMat*, bool*) in CameraEgomotion.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
The key there is "ld: symbol(s) not found for architecture x86_64". You're linking against a 32-bit library somewhere. What library, we have no idea, since you didn't include enough information.
Related
When adding the SDK i get this compile error
ld: warning: ignoring file /Path/To/Project/MaxstVideoFramework.framework/MaxstVideoFramework, missing required architecture x86_64 in file /Path/To/Project/MaxstVideoFramework.framework/MaxstVideoFramework (2 slices)
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_MasCameraDevice", referenced from:
objc-class-ref in ScanForCouponsViewController.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I am using swift.
Does any have an idea on how to fix this ?
Thanks
Try in this terminal this code:
lipo -info /path/to/your/framework/binaryfile
Maybe the framework doesn't support architecture x86_64.
Also you should read the SDK documents, maybe you missed some settings just like "Other linker Flags".
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_MPMusicPlayerController", referenced from:
objc-class-ref in liblibPDRCore.a(PGDeviceStatus.o)
ld: symbol(s) not found for architecture armv7 clang: error: linker command failed with exit code 1 (use -v to see invocation)
One of my lib was manually dragged into project before now I have it installed by cocoapods ,then the problem occurred. And I tried add the MediaPlayer.framework(although I don't need this framework before) to my project,the problem becomes this : ld: 14 duplicate symbols for architecture armv7
Anyone can help me 🙏?
I had same problem, but then I added MediaPlayer.framework like this
I got this error when trying to running app in simulator. And I'm using this library. https://github.com/donobono/DoImagePickerController. How can I solve this problem?
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_DoImagePickerController", referenced from:
objc-class-ref in NewActivityVC.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Thank you in advance
I build project that have unity classes inside. And i got this error:
Undefined symbols for architecture armv7:
RegisterAllClassesIPhone(), referenced fro
RegisterAllClasses() 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)
Anyone knows how to handle with this?
Thanks
You may forget to add this flag:
Other C Flag:
-DINIT_SCRIPTING_BACKEND=1
Other C++ Flag:
-DINIT_SCRIPTING_BACKEND=1
I met the same issue, and fixed by added the above flags.
This error is driving me crazy, any idea?
Undefined symbols for architecture armv7s:
"_CGContextConcatCTM", referenced from:
-[PopoViewController onClick:] in PopoViewController.o
"_CGContextTranslateCTM", referenced from:
-[PopoViewController onClick:] in PopoViewController.o
"_CGContextSaveGState", referenced from:
-[PopoViewController onClick:] in PopoViewController.o
"_CGContextRestoreGState", referenced from:
-[PopoViewController onClick:] in PopoViewController.o
ld: symbol(s) not found for architecture armv7s clang: error: linker command failed with exit code 1 (use -v to see invocation)
The binary with libraries are linked.
The library search path is correct.
Thanks
Link your application with CoreGraphics.framework for iPhoneOS architecture.