OpenSSL的Mach-O的为i386硬件架构和ARMv7链接错误 [英] Openssl Mach-O linker error for architecture i386 and armv7

查看:246
本文介绍了OpenSSL的Mach-O的为i386硬件架构和ARMv7链接错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想实现的OpenSSL code,我发现到我的项目,但我得到的不会消失,这些链接器错误。我检查了框架是正确链接,甚至包括使用../lib和../include手动库和头搜索路径。尽管这样的错误消失,当我摆脱Openssl的功能或任何函数调用,如EVP_OpenUpdate或EVP_OpenInit的。这只有当我创建,然后从某种原因,我ViewController.h文件调用该函数。

I am trying to implement openssl code I found into my project but I get these linker errors that aren't going away. I checked that the frameworks are properly linked and even included the library and header search paths manually using ../lib and ../include. Despite this the error goes away when I get rid of the Openssl function or any function calls such as EVP_OpenUpdate or EVP_OpenInit. This only if I create and then call the function from my ViewController.h file for some reason.

下面是日志错误的:

  Ld /Users/User/Library/Developer/Xcode/DerivedData/LineaSSL-clrggexngizkqqbtcxpnmsciuwag/Build/Products/Debug-iphoneos/LineaSSL.app/LineaSSL normal armv7
cd /Users/User/Documents/LineaSSL
setenv IPHONEOS_DEPLOYMENT_TARGET 4.0
setenv  PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs
/iPhoneOS5.1.sdk -L/Users/User/Library/Developer/Xcode/DerivedData/LineaSSL-clrggexngizkqqbtcxpnmsciuwag/Build/Products/Debug-iphoneos -L/Users/User/Documents/LineaSSL/../../Desktop/x2on-OpenSSL-for-iPhone-a095890/OpenSSL-for-iOS/lib -L/Users/User/Documents/LineaSSL/../../Downloads/DTDevices-iOS_2012-06-15_v1/Library -L/Users/User/Documents/LineaSSL/OpenSSL-for-iOS/lib -L/Users/User/Documents/LineaSSL/lib -F/Users/User/Library/Developer/Xcode/DerivedData/LineaSSL-clrggexngizkqqbtcxpnmsciuwag/Build/Products/Debug-iphoneos -Finclude -Finclude/openssl -filelist /Users/User/Library/Developer/Xcode/DerivedData/LineaSSL-clrggexngizkqqbtcxpnmsciuwag/Build/Intermediates/LineaSSL.build/Debug-iphoneos/LineaSSL.build/Objects-normal/armv7/LineaSSL.LinkFileList -dead_strip -miphoneos-version-min=4.0 -lcrypto -lssl -framework CoreGraphics -framework ExternalAccessory -framework Foundation -framework UIKit -ldtdev -o /Users/User/Library/Developer/Xcode/DerivedData/LineaSSL-clrggexngizkqqbtcxpnmsciuwag/Build/Products/Debug-iphoneos/LineaSSL.app/LineaSSL

ld: warning: ignoring file /Users/User/Desktop/x2on-OpenSSL-for-iPhone-a095890/OpenSSL-for-iOS/lib/libcrypto.a, file was built for archive which is not the architecture being linked (armv7)
ld: warning: ignoring file /Users/User/Desktop/x2on-OpenSSL-for-iPhone-a095890/OpenSSL-for-iOS/lib/libssl.a, file was built for archive which is not the architecture being linked (armv7)
Undefined symbols for architecture armv7:
 "_rsa_open3", referenced from:
   -[ViewController barcodeData:isotype:] in ViewController.o
 ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)

请让我知道我应该做的关于此错误。

Please let me know what I should do in regards to this error.

先谢谢了。

推荐答案

我不得不从头开始重建整个项目,以获得它的工作。我不知道为什么我不得不做这样的事情虽然。

I had to rebuild the entire project from scratch in order to get it to work. I don't know why I had to do such a thing though.

这篇关于OpenSSL的Mach-O的为i386硬件架构和ARMv7链接错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆