如何在 Mac OS X 上将 OpenSSL 构建为 32 位 (i386)?
我下载了 OpenSSL 源代码,并进行了 config
、make
、sudo make install
三部曲。
然后我构建了我的项目,链接到 libcrypto.a 和 libssl.a,但是得到:
ld: warning: in /usr/local/ssl/lib/libcrypto.a, file was built for unsupported file format which is not the architecture being linked (x86_64)
ld: warning: in /usr/local/ssl/lib/libssl.a, file was built for unsupported file format which is not the architecture being linked (x86_64)
我很确定我想将 OpenSSL 重新构建为 32 位(i386),因为(由于与这个问题无关的原因)我的项目需要是32位的。
如何在 Mac OS X 上将 OpenSSL 构建为 32 位? (我在“安装”文件中没有看到任何有关此内容的信息。)
I downloaded OpenSSL sources, and did the config
, make
, sudo make install
trilogy.
I then built my project, linking in libcrypto.a and libssl.a, but got:
ld: warning: in /usr/local/ssl/lib/libcrypto.a, file was built for unsupported file format which is not the architecture being linked (x86_64)
ld: warning: in /usr/local/ssl/lib/libssl.a, file was built for unsupported file format which is not the architecture being linked (x86_64)
I'm pretty sure I want to re-build OpenSSL as 32-bit (i386), because (for reasons not pertinent to this question) my project needs to be 32-bit.
How do I build OpenSSL as 32-bit on Mac OS X? (I didn't see anything about this in the "INSTALL" file.)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果有人正在寻找构建动态库的解决方案,可以这样做:
对于 64 位,运行
If anybody is looking for a solution to build dynamic libraries, this is how to do it:
For 64 bit, run