ios – 找不到lcrypto的库

我正在尝试构建iOS AllJoyn项目,但我遇到了OpenSSL集成的问题.

我一直在看这些方向:https://allseenalliance.org/docs-and-downloads/documentation/configuring-build-environment-ios-and-osx#unique_16

我已经按照指示一直到Xcode IDE Build,但现在我收到一个错误,上面写着:“找不到lcrypto的库”.

在线查看看起来可能与Makefile有关,但我不确定lcrypto是什么以及我应该引用什么库.

编辑
我注意到它说它是一个Shell脚本调用错误

这里还有跟踪:

ld: warning: directory not found for option '-L/PATH/alljoyn/alljoyn/common/crypto/openssl/build/Debug-iphoneos'
ld: library not found for -lcrypto
clang: error: linker command Failed with exit code 1 (use -v to see invocation)
scons: *** [build/darwin/arm/iphoneos/debug/obj/test/bbcclient] Error 1
scons: building terminated because of errors.
Command /usr/local/bin/scons Failed with exit code 2

解决方法

为了成功使用AllJoyn SDK,您需要有一个openssl库的编译版本(即libcrypto.a).

有关构建openssl库的详细信息,请参见SDK中/ alljoyn_objc下的README-INSTALLING.txt文件,我已经复制了下面的相关说明.一旦创建了openssl库,就需要将它放在项目可访问的目录中(在您的情况下为“/ PATH / alljoyn / alljoyn / common / crypto / openssl / build / Debug-iphoneos”).

大部分信息都包含在AllJoyn Programming Guide for Objective-C

README-INSTALLING.txt文件中的相关文本:

  1. OpenSSL is required for iOS development and is available at the following web
    address: www.openssl.org
    AllJoyn has been tested with version 1.0.1 of OpenSSL.
  2. Download the Xcode project that can be used to build OpenSSL for iOS from GitHub,
    at the following web address: 07001

Installation

  1. copy the OpenSSL source into a separate folder on your development system,not
    under the AllJoyn SDK.

  2. Navigate to the OpenSSL source top folder in Finder,and copy the openssl.xcodeproj
    folder you downloaded from GitHub into this folder.

  3. Open the openssl.xcodeproj in Xcode.

  4. In Xcode,build the crypto target (libssl.a and libcrypto.a) for each combination of configuration (debug|release) and platform (iphoneos|iphonesimulator) that you need for your iOS project by selecting Product->Build For->(your desired configuration).

相关文章

UITabBarController 是 iOS 中用于管理和显示选项卡界面的一...
UITableView的重用机制避免了频繁创建和销毁单元格的开销,使...
Objective-C中,类的实例变量(instance variables)和属性(...
从内存管理的角度来看,block可以作为方法的传入参数是因为b...
WKWebView 是 iOS 开发中用于显示网页内容的组件,它是在 iO...
OC中常用的多线程编程技术: 1. NSThread NSThread是Objecti...