0 Bewertungen0% fanden dieses Dokument nützlich (0 Abstimmungen)
116 Ansichten7 Seiten
Jasdeep Singh Passionate Ruby, ruby on rails, JavaScript, CoffeeScript Developer based out of Toronto. Wanted to install the Ruby OpenGraph gem for a project I was working on. However, unfortunately I was facing this issue which was failing on building of nokogiri native Extensions.
Originalbeschreibung:
Originaltitel
Installing Nokogiri Fails on OS X Mavericks _ Jasdeep Singh
Jasdeep Singh Passionate Ruby, ruby on rails, JavaScript, CoffeeScript Developer based out of Toronto. Wanted to install the Ruby OpenGraph gem for a project I was working on. However, unfortunately I was facing this issue which was failing on building of nokogiri native Extensions.
Jasdeep Singh Passionate Ruby, ruby on rails, JavaScript, CoffeeScript Developer based out of Toronto. Wanted to install the Ruby OpenGraph gem for a project I was working on. However, unfortunately I was facing this issue which was failing on building of nokogiri native Extensions.
8/2/2014 Installing Nokogiri Fails on OS X Mavericks | Jasdeep Singh
http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/ 1/7 JasdeepSingh Passionate Ruby, Ruby on Rails, JavaScript, CoffeeScript Developer based out of Toronto. InstallingNokogiriFailsonOSXMavericks
October 28, 2013
So, I upgraded to OS X Mavericks this weekend. The upgrade went smooth and everything had been running extremely fine for me until today. I wanted to install the Ruby OpenGraph gem for a project I was working on. This gem depends on the Nokogiri Gem. However, unfortunately I was facing this issue which was failing on building of Nokogiri Native Extensions as follows. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 $ gem install nokogiri Building native extensions. This could take a while... ERROR: Error installing opengraph: ERROR: Failed to build gem native extension.
/Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/bin/ruby extconf.rb extconf.rb:10: Use RbConfig instead of obsolete and deprecated Config. checking for libxml/parser.h... *** 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 Looking for expert help on your next software project? Contact me now! 8/2/2014 Installing Nokogiri Fails on OS X Mavericks | Jasdeep Singh http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/ 2/7 After seeing this error, I was pretty much like: 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 --srcdir=. --curdir --ruby=/Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/bin/ruby --with-zlib-dir --without-zlib-dir --with-zlib-include --without-zlib-include=${zlib-dir}/include --with-zlib-lib --without-zlib-lib=${zlib-dir}/lib --with-iconv-dir --without-iconv-dir --with-iconv-include --without-iconv-include=${iconv-dir}/include --with-iconv-lib --without-iconv-lib=${iconv-dir}/lib --with-xml2-dir --without-xml2-dir --with-xml2-include --without-xml2-include=${xml2-dir}/include --with-xml2-lib --without-xml2-lib=${xml2-dir}/lib --with-xslt-dir --without-xslt-dir --with-xslt-include --without-xslt-include=${xslt-dir}/include --with-xslt-lib --without-xslt-lib=${xslt-dir}/lib /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:381:in `try_do': The compiler failed to generate an executable file. (RuntimeError) You have to install development tools first. from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:506:in `try_cpp' from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:970:in `block from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:790:in `block in checking_for' from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:284:in `block from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:254:in `open' from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:284:in `block from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:254:in `open' from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:280:in `postpone from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:789:in `checking_for' from /Users/jasdeep/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/mkmf.rb:969:in `find_header from extconf.rb:96:in `<main>'
Gem files will remain installed in /Users/jasdeep/.rvm/gems/ruby-1.9.3-p448/gems/nokogiri Results logged to /Users/jasdeep/.rvm/gems/ruby-1.9.3-p448/gems/nokogiri-1.4.7/ext/nokogiri 8/2/2014 Installing Nokogiri Fails on OS X Mavericks | Jasdeep Singh http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/ 3/7 So, i checked the gem_make.out where the errors were logged and figured my comman line developer tools in this new version of OS X were pooched/missing. There is a command line tool available called xcode-select which is used to switch between different versions of XCode and Xcode in this new version of OS X comes with an update (Version 5.0.1). This little tool can be used to install the latest command line developer tools. This command did it for me: 1 $ xcode-select --install 8/2/2014 Installing Nokogiri Fails on OS X Mavericks | Jasdeep Singh http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/ 4/7 Google+
After downloading and installing the new Command Line Developer Tools: If this didnt worked for you, a couple people reported that their gcc was missing. Consider following this Stack Overflow question if thats the case: http://stackoverflow.com/a/19643909/472869 PS: I had a few warnings after installing the gem which Ive left out for brevity sake. These were just some encoding warnings Nothing serious. Im hoping there wont be any major issues with Nokogiri on Mavericks. Jasdeep Singh 28 Comments Jasdeep Singh Login Sort by Best Share Join the discussion Reply sally 3 months ago I would reach through the internet and hug you if i could. I have been fighting with this for so long! Thank you so much for posting this!
5 Favorite Share 1 2 3 4 5 6 $ gem install nokogiri Building native extensions. This could take a while... Successfully installed nokogiri-1.6.0 Installing ri documentation for nokogiri-1.6.0 1 gem installed $ 8/2/2014 Installing Nokogiri Fails on OS X Mavericks | Jasdeep Singh http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/ 5/7 Reply Rob Park 6 months ago Worked for me too. Thanks!
3 Reply Rafael Rosa 2 months ago Thanks, it worked :)
1 Reply narangjasdeep 2 months ago Mod Rafael Rosa glad it helped. Thanks!
Reply grimmdude 4 months ago Thanks man, exactly what I was looking for!
1 Reply narangjasdeep 2 months ago Mod grimmdude sorry for the late reply, but glad this was helpful!
Reply spencer owen 4 months ago Unfortunately it didn't work for me because of this http://stackoverflow.com/quest...
1 Reply narangjasdeep 2 months ago Mod spencer owen thanks for posting this link to SO, I hope it turns out to be helpful for others.
Reply Gourav Tiwari 5 months ago this worked! thanks for sharing!
1 Reply mgryszko 6 months ago Thanks for the tip - it worked like a charm!
1 Reply narangjasdeep 2 months ago Mod mgryszko glad I could be helpful. keep coding! ;)
Reply kennygorman 14 hours ago Thx!!! helped a ton.
Jeff Kibuule 3 days ago SUCCESS! Share Share Share Share Share Share Share Share Share Share Share 8/2/2014 Installing Nokogiri Fails on OS X Mavericks | Jasdeep Singh http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/ 6/7 Reply Reply Alex 5 days ago Thank you sir!
Reply yinghau76 7 days ago You save my day. Thank you!
Reply erwin 13 days ago unfortunatly, new major issues with Nokogiri on Mavericks.... seems to be the case with each new XCode release now ...
Reply Guest a month ago this worked, after struggling with the nokogiri install
Reply Arpan J a month ago This worked! Was trying to solve this for a while. Thanks much!!
Reply wanlin brian a month ago Thanks a lot!
Reply Alex Jahraus 2 months ago Thanks a lot! Installing XCode CL tools fixed this for me, however, I was unable to install them using `xcode-select --install`, had to download the DMG from Apple: http://adcdownload.apple.com/D...
Reply Chandler Roth 2 months ago I could hug you. Worked like a dream. Thanks.
Reply Joel 3 months ago "Can't install the software because it is not currently available from the Software Update server." See this message consistently.
Reply narangjasdeep 2 months ago Mod Joel Unsure what's going on. At what step do you get this?
Bryan Shanaver 8 months ago Share Share Share Share Share Share Share Share Share Share Share 8/2/2014 Installing Nokogiri Fails on OS X Mavericks | Jasdeep Singh http://jasdeep.ca/2013/10/installing-nokogiri-fails-os-x-mavericks/ 7/7 Lifestyle changes I made that helped me Loose 30lbs in roughly 4 months 3 comments 3 months ago Ajit Singh good one jawan Happy Birthday Manpreet!! 2 comments 9 months ago Satinderjit Singh hah... Nice compilation dude! :) Rails Pub Night, Ruby Meetups & Learn to Code Bootcamps in Toronto 4 comments 10 months ago narangjasdeep I would highly recommend Eloquent Ruby for some one Installing Redis on Mac OS X 27 comments a year ago AndreFigueira install brew, then do brew install redis ALSO ON JASDEEP SINGH Reply Bryan Shanaver 8 months ago Thanks for posting - worked for me too
Reply RamiJames 8 months ago Thank you for posting this answer!
Reply Nathan Bashaw 9 months ago Thank you soooo much!!!!
Reply Amicushq.com 9 months ago This was amazing! Thank you so much!!
Reply narangjasdeep 9 months ago Mod Amicushq.com Glad it helped.