macOS 上的 OpenSSL 1.0.2m [英] OpenSSL 1.0.2m on macOS

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

问题描述

为了构建一个特定的库,我需要带有开发包的 openssl 库版本 1.0.2m.我在 macOS 上工作.使用 brew install openssl 安装最新版本 1.1.1d.

For building one particular library I need openssl library version 1.0.2m with devel package. I am working on macOS. Using brew install openssl installs latest version 1.1.1d.

推荐答案

由于 OpenSSL 1.0.2 已于 2019 年底终止,因此不再通过 Homebrew 提供.Homebrew 2.2.0 公告中提到了这一点.

Since OpenSSL 1.0.2 is end of lifed by the end of 2019, it is no longer available via Homebrew. This is mentioned in the Homebrew 2.2.0 announcement.

自己从源代码构建和安装 OpenSSL 1.0.2 相当简单.您可以从 Old 1.0.2 Releases 页面下载所需的版本,然后按照安装中的说明.

It is fairly straightforward to build and install OpenSSL 1.0.2 yourself from source. You can download your required version from the Old 1.0.2 Releases page and follow the instructions found in INSTALL.

也可以恢复旧公式并从中安装,但我不能保证它的效果如何.以下步骤确实完成了安装过程:

It may be possible as well to recover an older formula and install from that, but I can not guarantee how well that works. The following steps did complete the installation process:

$ git clone https://github.com/Homebrew/homebrew-core.git
$ cd homebrew-core
$ git checkout 75b57384 Formula/openssl.rb
$ brew install Formula/openssl.rb

对我来说,这表明:

Warning: openssl 1.1.1d is available and more recent than version 1.0.2m.
==> Downloading https://homebrew.bintray.com/bottles/openssl-1.0.2m.high_sierra.bottle.tar.gz

然后就愉快地继续了.最后的快速尝试让人相信它运行良好:

and went on happily after that. A quick try at the end gives some confidence that it worked out well:

$ /usr/local/opt/openssl/bin/openssl version
OpenSSL 1.0.2m  2 Nov 2017

<小时>

如果您不想直接使用 git,您也可以尝试下载该版本的 openssl.rb 来自 gitHub.com 并在其上运行 brew install.


If you prefer not to use git directly, you can also try downloading that version of openssl.rb from gitHub.com and run brew install on it.

如果你想知道提交哈希是从哪里来的,我碰巧知道这个公式曾经被称为——惊奇——openssl.rb(但使用git查询已删除的文件也会起作用).因此,我检查了 Formula/openssl.rb 的历史记录,发现:

If you wonder where that commit hash came from, I happened to know that the formula used to be called -- surprise -- openssl.rb (but using git to query for removed files would have worked as well). Therefore, I inspected the history for Formula/openssl.rb and found:

$ git log -- Formula/openssl.rb
...
commit 75b573845a17aaf3f7c84dc58e97cf5fe39a502b
Author: BrewTestBot <brew-test-bot@googlegroups.com>
Date:   Thu Nov 2 17:20:33 2017 +0000

    openssl: update 1.0.2m bottle.

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

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