尝试使用快速角检测器时出现 Apple O-Match 链接器错误 成功实验室
我正在尝试实现此: http://www.hatzlaha.co.il/ 150842/FAST-Corner-V2 在我的应用程序中。他们共享完整的编译项目,正在做我想要的事情。我试图在我的应用程序中使用它,但在复制功能后我陷入了编译应用程序的困境。
我从编译器中收到此错误:
Ld /Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos/ARmgr.app/ARmgr normal armv6
cd /Users/wojciechradomski2/Documents/xCode/AR/ARmgr
setenv IPHONEOS_DEPLOYMENT_TARGET 4.0
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/llvm-g++-4.2 -arch armv6 -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.3.sdk -L/Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos -L/Users/wojciechradomski2/Documents/xCode/AR/ARmgr/ARmgr/opencv_device/lib -F/Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos -filelist /Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Intermediates/ARmgr.build/Debug-iphoneos/ARmgr.build/Objects-normal/armv6/ARmgr.LinkFileList -dead_strip -lstdc++ -lz -miphoneos-version-min=4.0 -framework OpenGLES -framework AssetsLibrary -framework MobileCoreServices -framework MediaPlayer -framework QuartzCore -framework CoreVideo -framework CoreMedia -framework AVFoundation -framework Accelerate -framework UIKit -framework Foundation -framework CoreGraphics -lcv -lcxcore -o /Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos/ARmgr.app/ARmgr
Undefined symbols for architecture armv6:
"fast9_detect_nonmax(unsigned char const*, int, int, int, int, int*)", referenced from:
-[CameraViewController captureOutput:didOutputSampleBuffer:fromConnection:] in CameraViewController.o
ld: symbol(s) not found for architecture armv6
collect2: ld returned 1 exit status
正如自述文件所说,我只需要导入 fast.h,并且我正在这样做。 我检查了所有库、导入和框架——我都有。
即使有这样的情况,也会显示上述错误:
fast9_score(NULL, NULL, NULL, NULL, NULL);
删除此行后,一切都可以正常编译。
我有什么想法错过或做错了吗?
i am trying to implement this: http://www.hatzlaha.co.il/150842/FAST-Corner-V2 in my app. They share complete compiling project that is doing what I want. I am trying to use it in my app but I got stuck in compiling my application after copying function.
I got this error from compiler:
Ld /Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos/ARmgr.app/ARmgr normal armv6
cd /Users/wojciechradomski2/Documents/xCode/AR/ARmgr
setenv IPHONEOS_DEPLOYMENT_TARGET 4.0
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/llvm-g++-4.2 -arch armv6 -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.3.sdk -L/Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos -L/Users/wojciechradomski2/Documents/xCode/AR/ARmgr/ARmgr/opencv_device/lib -F/Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos -filelist /Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Intermediates/ARmgr.build/Debug-iphoneos/ARmgr.build/Objects-normal/armv6/ARmgr.LinkFileList -dead_strip -lstdc++ -lz -miphoneos-version-min=4.0 -framework OpenGLES -framework AssetsLibrary -framework MobileCoreServices -framework MediaPlayer -framework QuartzCore -framework CoreVideo -framework CoreMedia -framework AVFoundation -framework Accelerate -framework UIKit -framework Foundation -framework CoreGraphics -lcv -lcxcore -o /Users/wojciechradomski2/Library/Developer/Xcode/DerivedData/ARmgr-bxkvnxdnsjbaioahqhygfsmofpxn/Build/Products/Debug-iphoneos/ARmgr.app/ARmgr
Undefined symbols for architecture armv6:
"fast9_detect_nonmax(unsigned char const*, int, int, int, int, int*)", referenced from:
-[CameraViewController captureOutput:didOutputSampleBuffer:fromConnection:] in CameraViewController.o
ld: symbol(s) not found for architecture armv6
collect2: ld returned 1 exit status
As readme file says I need only to import fast.h, and I am doing it.
I checked all libraries, imports and frameworks - I have them all.
The above error displays even with someting like this:
fast9_score(NULL, NULL, NULL, NULL, NULL);
After removing this line everything compiles fine.
Any ideas what I am missing or doing wrong?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
粗略一看,缺少的函数是在 fast.cc 中定义的。因此,请确保您的项目中有它,并且它会被编译并与您所需的目标链接。
编辑:提示:如果链接器中缺少符号,只需 grep 查找包含该符号的文件。您可能会找到定义它的那个...我刚刚在您在帖子中链接的项目的源目录中执行了“grep -r fast9_detect_nonmax *”,并找到了该文件。
From my cursory glance, the missing function is defined in fast.cc. So make sure you have it in your project, and it gets compiled and linked with your desired target.
Edit: A hint: if you get missing symbols in the linker, just grep for the files which contain that symbol. You may find the one that defines it... I just did a "grep -r fast9_detect_nonmax *" in the source directory of the project you linked in your post, and found the file.