I’m working on a Google Chrome extension to allow users to check the URL they are being forwarded to when they click on shortened URLs. I wanted to make sure I’m parsing responses and forwards properly, so wget came to mind. I’ve used wget a few times on Linux, but I’m doing my development on my Mac, so I compiled wget for my Mac.
Download
- wget-1.14.tar.gz
- SHA-1 of wget-1.14.tar.gz: fedb008d414b87e44962e5e17671230aebe88189
- Signature: wget-1.14.tar.gz.sig
- SHA-1 of the wget executable: 062e17849d46cecc3d1e6d4a42b88e7eba16d96a
- Open the Terminal and navigate to the downloaded archive
- Extract the files by running tar xzf wget-1.14.tar.gz
- Login with an account with Administrator privileges
- Copy /bin/wget to /usr/local/bin
- Copy /man/wget.1 to /usr/local/share/man/man1
- Make sure all users have execute/read access to these files
Compile
Note: You must have Xcode installed.
- Download the wget source (wget-1.14.tar.gz) from http://ftp.gnu.org/gnu/wget/
- Open a terminal window and browse to the downloaded archive
- Extract the archive using tar xzf wget-1.14.tar.gz
- Open the wget-1.14 directory
- Run ./configure --with-ssl=openssl
If you have GNUTLS installed, you can omit “–with-ssl=openssl” - Run make
- You will have the wget binary in the /src directory and the man page in the /doc directory
- Copy /src/wget to /usr/local/bin
- Copy /doc/wget.1 to /usr/local/share/man/man1
- Make sure all users have execute/read access to these files