Nokogiri missing libiconv error. Chapter 3 of RoR book tutorial

I posted a question on stackoverflow but it hasnt been much help:

http://stackoverflow.com/questions/24441580/cannot-bundle-install-nokogiri-error-ror-tutorial?noredirect=1#comment37820000_24441580

I also followed the homebrew instructions to get libiconv. I have it
downloaded and installed but whenever I run gem install nokogiri. I get
the
same error

ERROR: Error installing nokogiri:

ERROR: Failed to build gem native extension.

/Users/bradfordli/.rvm/rubies/ruby-2.0.0-p481/bin/ruby extconf.rb

Building nokogiri using packaged libraries.


libiconv is missing. please visit
http://nokogiri.org/tutorials/installing_nokogiri.html for help with
installing dependencies.


*** extconf.rb failed ***

Could not create Makefile due to some reason, probably lack of necessary

libraries and/or headers. Check the mkmf.log file for more details.
You
may

need configuration options.

Provided configuration options:

–with-opt-dir

–with-opt-include

–without-opt-include=${opt-dir}/include

–with-opt-lib

–without-opt-lib=${opt-dir}/lib

–with-make-prog

–without-make-prog

–srcdir=.

–curdir

–ruby=/Users/bradfordli/.rvm/rubies/ruby-2.0.0-p481/bin/ruby

–help

–clean

–use-system-libraries

–enable-static

–disable-static

–with-zlib-dir

–without-zlib-dir

–with-zlib-include

–without-zlib-include=${zlib-dir}/include

–with-zlib-lib

–without-zlib-lib=${zlib-dir}/lib

–enable-cross-build

–disable-cross-build

Gem files will remain installed in
/Users/bradfordli/.rvm/gems/[email protected]_rails_4_0/gems/nokogiri-1.6.2.1
for inspection.

Results logged to
/Users/bradfordli/.rvm/gems/[email protected]_rails_4_0/gems/nokogiri-1.6.2.1/ext/nokogiri/gem_make.out

I checked /usr/local/Cellar and I have a libiconv direcotry in there but
I
always get the error saying libiconv is missing

Could it be that you are running OSX 10.6? I have the same problem, and
already contacted the nokogiri supporters. At least on this OSX
version. it doesn’t work.

I have also informed Michael H. to consider this in the next update
of his tutorial. You will have to do without Capybara.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs