编译并导入OpenSSL

编译并导入OpenSSL

 

1. 首先,需要运行脚本生成OpenSSL库,参考 https://github.com/x2on/OpenSSL-for-iPhone 示例

编译并导入OpenSSL 

 

2. 运行脚本生成静态库

编译并导入OpenSSL

下一步我们会用到这两个文件夹中的内容

编译并导入OpenSSL

 

3. 新建一个文件夹叫 openssl ,然后将 OpenSSL-for-iPhone 项目中的 FSOpenSSL.h/m 文件拖到文件夹中,将生成的 include 以及 lib 文件夹也拖到 openssl 文件夹中.

结构如下图所示

编译并导入OpenSSL

 

4. 将整个文件夹 openssl 拖到新建的项目当中

编译并导入OpenSSL

 

5. 在 Header Search Paths 中添加以下内容 "$(SRCROOT)/$(PROJECT_NAME)/openssl/include"

编译并导入OpenSSL

 

6. 在 Library Search Paths 中添加以下内容 "$(SRCROOT)/$(PROJECT_NAME)/openssl/lib"

编译并导入OpenSSL

 

7. 编译运行,结束

 

相关文章:

  • 2021-07-24
  • 2021-09-08
  • 2022-01-11
  • 2021-10-07
  • 2021-05-30
  • 2021-12-13
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-10-10
相关资源
相似解决方案