ios8.3 编译 arm64版 openssl-1.0.2a
xcode是6.3版的,ios sdk 是8.3的,
到http://www.openssl.org/source/下载最新版本openssl-1.0.2a
解压后用文本编辑器打开configure文件,
----------------------------------------------------------------------------------------------------------------------------------------------------------
将
# iPhoneOS/iOS
"iphoneos-cross","llvm-gcc:-O3 -isysroot \$(CROSS_TOP)/SDKs/\$(CROSS_SDK) -fomit-frame-pointer -fno-common::-D_REENTRANT:iOS:-Wl,-search_paths_first%:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${no_asm}:dlfcn:darwin-shared:-fPIC -fno-common:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
----------------------------------------------------------------------------------------------------------------------------------------------------------
替换为:
# iPhoneOS/iOS
"iphoneos-cross","llvm-gcc:-arch arm64 -O3 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.3.sdk -fomit-frame-pointer -fno-common::-D_REENTRANT:iOS:-Wl,-search_paths_first%:BN_LLONG RC4_CHAR RC4_CHUNK DES_UNROLL BF_PTR:${no_asm}:dlfcn:darwin-shared:-fPIC -fno-common:-dynamiclib:.\$(SHLIB_MAJOR).\$(SHLIB_MINOR).dylib",
----------------------------------------------------------------------------------------------------------------------------------------------------------
然后打开terminal,运行命令
./configure --prefix=/libs/openssl-1.0.2a/arm64 iphoneos-cross
make
make install
模拟器的可以用如下命令:
./configure --prefix=/libs/openssl-1.0.2a/x86_64 darwin64-x86_64-cc
./configure --prefix=/libs/openssl-1.0.2a/i386 darwin-i386-cc
make
make install
make clean
郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。