How to install latest version of openssl Mac OS X El Capitan

后端 未结 9 2141
无人及你
无人及你 2020-11-22 07:05

I have used brew install openssl to download and install openssl v1.0.2f, however, it comes back saying:

A CA file has been bootstrapped using c         


        
相关标签:
9条回答
  • 2020-11-22 07:13

    Only

    export PATH=$(brew --prefix openssl)/bin:$PATH in ~/.bash_profile
    

    has worked for me! Thank you mipadi.

    0 讨论(0)
  • I reached this page when I searched for information about openssl being keg-only. I believe I have understood the reason why Homebrew is taking this action now. My solution may work for you:

    • Use the following command to make the new openssl command available (assuming you have adjusted PATH to put /usr/local/bin before /usr/bin): ln -s /usr/local/opt/openssl/bin/openssl /usr/local/bin/

    • When compiling with openssl, follow Homebrew's advice and use -I/usr/local/opt/openssl/include -L/usr/local/opt/openssl/lib

    • Alternatively, you can make these settings permanent by putting the following lines in your .bash_profile or .bashrc: export CPATH=/usr/local/opt/openssl/include export LIBRARY_PATH=/usr/local/opt/openssl/lib

    0 讨论(0)
  • 2020-11-22 07:17

    this command solve my problem on github CI job and virtualbox

    brew install openssl@1.1
    cp /usr/local/opt/openssl@1.1/lib/pkgconfig/*.pc /usr/local/lib/pkgconfig/
    
    0 讨论(0)
  • 2020-11-22 07:20

    To replace the old version with the new one, you need to change the link for it. Type that command to terminal.

    brew link --force openssl
    

    Check the version of openssl again. It should be changed.

    0 讨论(0)
  • 2020-11-22 07:24

    This is an old question but still answering it in present-day context as many of the above answers may not work now.

    The problem is that the Path is still pointing to the old version. Two solutions can be provided for resolution :

    1. Uninstall old version of openssl package brew uninstall openssl and then reinstall the new version : brew install openssl
    2. point the PATH to the new version of openssl.First install the new version and now(or if) you have installed the latest version, point the path to it: echo 'export PATH="/usr/local/opt/openssl/bin:$PATH"' >> ~/.bash_profile
    0 讨论(0)
  • 2020-11-22 07:26

    Execute following commands:

    brew update
    brew install openssl
    echo 'export PATH="/usr/local/opt/openssl/bin:$PATH"' >> ~/.bash_profile
    source ~/.bash_profile
    

    You will have the latest version of openssl installed and accessible from cli (command line/terminal). Since the third command will add export path to .bash_profile, the newly installed version of openssl will be accessible across system restarts.

    0 讨论(0)
提交回复
热议问题