Fork me on GitHub

Nokogiri, RVM, Homebrew and headhache!!!

Thanks to a gist (which I forked and slightly changed) I was able to finally install Nokogiri on my mac:

export BREW_HOME=/usr/local

brew install libxml2
brew link libxml2
brew install https://github.com/adamv/homebrew-alt/raw/master/duplicates/libxslt.rb
brew link libxslt
brew install libiconv
brew link libiconv
gem install nokogiri -- --with-xml2-dir=$BREW_HOME/Cellar/libxml2/2.7.8 --with-xslt-dir=$BREW_HOME/Cellar/libxslt/1.1.26 --with-iconv-dir=$BREW_HOME/Cellar/libiconv/1.13.1/

If you had MacPorts previously installed, it might still not work so
sudo mv /opt/local /opt/local_old
and try again.

Enjoy :)

 

 

No comments yet.


Leave a comment

(required)

(required)