Attempting to install the zlib-devel on mac os x mavericks with homebrew doesn't work:
brew install zlib-devel
Error: No available formula for zlib-devel
Searching taps...
This install
brew install zlib
works fine though.
Attempting to install the zlib-devel on mac os x mavericks with homebrew doesn't work:
brew install zlib-devel
Error: No available formula for zlib-devel
Searching taps...
This install
brew install zlib
works fine though.
Unfortunately none of the above methods worked for me So I did
Hope it helps
For OS X Mojave
sudo installer -pkg /Library/Developer/CommandLineTools/Packages/macOS_SDK_headers_for_macOS_10.14.pkg -target /
The reason is because Xcode Command Line tools no longer installs needed headers in /include. You have to run a separate command to install the needed headers.
As noted here - https://developer.apple.com/documentation/xcode_release_notes/xcode_10_release_notes
xcode-select --install
doesn't solve this on Mojave for some reason.Since this is the only library blocking, go to https://www.zlib.net and download source code. Select the "US (zlib.net)" hyperlink about halfway down the page for the tar.xz version.
Then find the download on your local machine and double click on the file. This will unzip the download and create a new folder in the same directly.
Then in Terminal:
cd
into the directory with the downloadtar -xvf zlib-1.2.11.tar.xz
(Note thatzlib-1.2.11.tar.xz
may change depending on the latest version you've downloaded. Just run whatever file you're just downloaded.)cd zlib-1.2.11
./configure
make
make install
Just run in the command line:
In OS X 10.9+, the command line developer tools are now installed on demand. So after running this also zlib and zlib-devel should be available (no need for brew install zlib...)