1. 程式人生 > >How to Install wget in OS X如何在Mac OS X下安裝wget並解決configure: error:

How to Install wget in OS X如何在Mac OS X下安裝wget並解決configure: error:

configure openssl usr local 解壓 fix 官網下載 .org get

1.ftp://ftp.gnu.org/gnu/wget/官網下載最新的安裝包 wget-1.19.tar.gz

2.打開終端輸入 tar zxvf wget-1.9.1.tar.gz 解壓縮

3.進入wget所在文件夾 終端輸入cd wget-1.9.1

4.終端輸入 ./configure

如果出現configure: error: The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config.

終端輸入 ./configure --with-ssl=openssl ,

如果你是OS X 10.10+ and OS X 10.11+,建議輸入./configure --with-ssl=openssl --with-libssl-prefix=/usr/local/ssl,否則會報錯configure: error: –with-ssl=openssl was given, but SSL is not available,如果按照上面步步驟還是報錯,有可能是安裝包放置的位置不對,建議放在 usr/local/Cellar/wget-1.9.1,我是這樣解決的報錯 安裝成功的

6.make

7.sudo make install

8.可以輸入wget www.google.com 看看是否安裝成功

How to Install wget in OS X如何在Mac OS X下安裝wget並解決configure: error: