带Bitcode的OpenSSL CocoaPod iOS? [英] OpenSSL CocoaPod iOS with Bitcode?

查看:271
本文介绍了带Bitcode的OpenSSL CocoaPod iOS?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有支持bitcode的OpenSSL cocoapod?以前我使用 pod'OpenSSL',但我想在我的应用程序中使用bitcode。有没有办法做到这一点,还是我必须自己构建OpenSSL?

Is there an OpenSSL cocoapod that works with bitcode enabled? Previously I was using the pod 'OpenSSL', but I want to have bitcode in my app. Is there any way to do this, or must I build OpenSSL by myself?

谢谢

推荐答案

我可以回答这个问题,因为我想出了怎么做。由于没有正式的CocoaPod,您必须使用构建脚本自行构建它。这是我使用的构建脚本:
https://gist.github.com/ felix-schwarz / c61c0f7d9ab60f53ebb0

I can answer this question, as I figured out how to do it. Since there is no official CocoaPod, you will have to use a build script to build it yourself. Here is the build script that I used: https://gist.github.com/felix-schwarz/c61c0f7d9ab60f53ebb0

此构建脚本将为您生成两个文件夹,一个名为 lib 另一个名为 include 。转到项目设置并转到构建阶段。打开名为 Link Binary With Libraries 的部分。然后,打开 lib 文件夹并拖动 libcrypto_iOS.a libssl_iOS.a 进入 Link Binary With Libraries 部分。

This build script will generate two folders for you, one called lib and another called include. Go to your project settings and go to Build Phases. Open the section called Link Binary With Libraries. Then, open the lib folder and drag libcrypto_iOS.a and libssl_iOS.a into the Link Binary With Libraries section.

接下来,转到构建设置。在搜索路径部分下,转到标题搜索路径,双击该字段,这将打开另一个框。在那里,拖动包含文件夹。还要确保库搜索路径具有 lib 文件夹。

Next, go to Build Settings. Under the Search Paths section, Go to Header Search Paths, double click the field, which will open another box. In there, drag the include folder. Also make sure that the Library Search Paths have the lib folder.

希望这会有所帮助!

这篇关于带Bitcode的OpenSSL CocoaPod iOS?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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