This setup install homebrew in user directories, which is safer to mess with. The downside is larger install times since it has to build packages from source.
1) Git-clone it into the ~/homebrew
directory:
git clone https://github.com/Homebrew/brew ~/homebrew
2) Make sure to include the bin/
and sbin/
directories in $PATH
, by adding this to ~/.bash_profile
:
PATH="$HOME/homebrew/bin:$HOME/homebrew/sbin:$PATH"'
3) Update
brew update
Check where a library is installed:
Example, boost
library:
brew --prefix boost