【问题标题】:Brew Install of OpenSSL3 on macOS High Sierra在 macOS High Sierra 上 Brew 安装 OpenSSL3
【发布时间】:2022-10-06 00:45:41
【问题描述】:

我在 macOS HighSierra 10.13.6 上,无法brew install openssl。我在this post 之后修改了openssl@3.rb,但仍然出现以下错误:

==> make
Last 15 lines from /Users/hahnemann/Library/Logs/Homebrew/openssl@3/02.make:
crypto/bn/rsaz-avx512.s:857:2: error: instruction requires: AVX-512 ISA AVX-512 VL ISA
 vmovdqu64 %ymm1,32(%rdi)
 ^
crypto/bn/rsaz-avx512.s:858:2: error: instruction requires: AVX-512 ISA AVX-512 VL ISA
 vmovdqu64 %ymm2,64(%rdi)
 ^
crypto/bn/rsaz-avx512.s:859:2: error: instruction requires: AVX-512 ISA AVX-512 VL ISA
 vmovdqu64 %ymm3,96(%rdi)
 ^
crypto/bn/rsaz-avx512.s:860:2: error: instruction requires: AVX-512 ISA AVX-512 VL ISA
 vmovdqu64 %ymm4,128(%rdi)
 ^
make[1]: *** [crypto/bn/liblegacy-lib-rsaz-avx512.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [build_sw] Error 2

Do not report this issue to Homebrew/brew or Homebrew/core!

These open issues may also help:
curl + recursive dependen{cies,ts}: switch to `openssl@3` https://github.com/Homebrew/homebrew-core/pull/85775

    标签: openssl homebrew macos-high-sierra


    【解决方案1】:

    我也遇到了与高山脉非常相似的事情。准确地说是 10.13.6。

    ProductName:    Mac OS X
    ProductVersion: 10.13.6
    BuildVersion:   17G14042
    

    `sysctl machdep.cpu.features 的输出

    sysctl machdep.cpu.features
    machdep.cpu.features: FPU VME DE PSE TSC MSR PAE MCE CX8 APIC SEP MTRR PGE MCA CMOV PAT PSE36 CLFSH MMX FXSR SSE SSE2 SS HTT SSE3 PCLMULQDQ VMX SSSE3 FMA CX16 PDCM SSE4.1 SSE4.2 x2APIC MOVBE POPCNT AES VMM PCID XSAVE OSXSAVE TSCTMR AVX1.0 RDRAND F16C
    

    我在 qemu kvm 设置中运行这个操作系统。有趣的是,我也有一个 mojave vm 设置,但没有遇到AVX512完全更新/修补莫哈韦的问题。

    昨天看到这个帖子

    https://superuser.com/questions/1669059/error-with-brew-install-openblas-in-macos


    所以让我们看看 openssl 是否有与NO_AVX512=1 类似的配置标志

    所以查看提取的压缩包中的 INSTALL.md 文档以获取 openssl 源代码,我能看到的最接近的是

    汇编模块编译注意事项

    汇编程序模块中某些代码路径的编译可能取决于 当前的汇编器版本是否支持某些 ISA 扩展 或不。使用 AES-NI、PCLMULQDQ、SSSE3 和 SHA 的代码路径 扩展总是组装的。除此之外,最低 汇编器版本的要求如下表所示:

    | ISA 扩展 | GNU 作为 |纳姆| llvm | |---------------|--------|--------|---------| | AVX | 2.19
    | 2.09 | 3.0 | | AVX2 | 2.22 | 2.10 | 3.1 | | ADCX/ADOX | 2.23 | 2.10 | 3.3 | | AVX512 | 2.25 | 2.11.8 | 3.6 () | | AVX512IFMA | 2.26 | 2.11.8 | 6.0 () | | VAES | 2.30 | 2.13.3 | 6.0 (*) |


    (*) 即使在 llvm 3.6 中实现了 AVX512 支持,但在此之前 7.0 版显然需要一个显式的 -march 标志来编译 组装模块。但随后编译器会生成特定于处理器的 代码,这反过来又与在 运行时,由特殊变量促进 OPENSSL_ia32cap。对于 7.0 之前的版本,可以工作 通过强制构建过程使用以下内容来解决问题 脚本:

    #!/bin/sh
    exec clang -no-integrated-as "$@"
    

    而不是真正的铿锵声。在这种情况下,什么叮当声都没有关系 使用版本,因为它是 GNU 汇编器的版本 被检查。

    所以也许可以使用-no-ingtegrated-as 调整编译命令,或者查看下面的 github 问题,您可以在其中修补 perl 脚本

    https://github.com/openssl/openssl/issues/16670#issuecomment-935184461

    【讨论】:

      【解决方案2】:

      我昨天遇到了这个错误,并且能够通过执行以下操作来安装 openssl3(参见 github 上的帖子)。我不得不更新 openssl 的构建脚本以不使用不可用的 cpu 指令。希望这可以帮助!

      https://github.com/openssl/openssl/issues/16670#issuecomment-1268671564

      【讨论】:

        猜你喜欢
        • 2018-06-16
        • 2018-12-05
        • 1970-01-01
        • 1970-01-01
        • 2018-06-11
        • 2018-01-27
        • 1970-01-01
        • 1970-01-01
        • 2021-07-16
        相关资源
        最近更新 更多