Get rid of Nokogiri LibXML warning on OSX Lion
If you are a Rails developer on OSX Lion or Mountain Lion, you might have seen this:
WARNING: Nokogiri was built against LibXML version 2.9.0, but has dynamically loaded 2.7.8
This happens because the Lion system default libxml2 (loaded at bootstrap) is used, regardless of which libxml2 Nokogiri was built against.
To get rid of the warning, (re)install the Nokogiri gem with:
gem install nokogiri -- --with-xml2-dir=/usr --with-xslt-dir=/opt/local --with-iconv-dir=/opt/local
Written by Michele Gerarduzzi
Related protips
1 Response
Also, try moving gem 'nokogiri' in the Gemfile to the top (just below gem 'rails'), as per https://github.com/sparklemotion/nokogiri/issues/742#issuecomment-9082139
over 1 year ago
·
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Rails
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#