Friday, 15 March 2013

ruby - ERROR: Failed to build gem native extension on Windows -



ruby - ERROR: Failed to build gem native extension on Windows -

i'm getting below error while installing 'redcarpet' gem. got installed without issue on friends machine though. (i want install run yard) ruby version: 1.9.3

cmd output:

d:\learning\common_pom_fw\sampleprojects>yard [error]: missing 'redcarpet' gem markdown formatting. install `gem install redcarpet` d:\learning\common_pom_fw\sampleprojects>gem install redcarpet temporarily enhancing path include devkit... building native extensions. take while... error: error installing redcarpet: error: failed build gem native extension. c:/ruby193/bin/ruby.exe -r ./siteconf20141009-6544-978w4t.rb extconf.rb creating makefile create clean makefile:165: *** target pattern contains no `%'. stop. create makefile:165: *** target pattern contains no `%'. stop. create failed, exit code 2 gem files remain installed in c:/ruby193/lib/ruby/gems/1.9.1/gems/redcarpet-3.1.2 inspectio n. results logged c:/ruby193/lib/ruby/gems/1.9.1/extensions/x86-mingw32/1.9.1/redcarpet-3.1.2/gem_ma ke.out

update: devkit installation instructions provided @ https://github.com/oneclick/rubyinstaller/wiki/development-kit when test installation json gem fails there :(

i went through link troubleshoot in github native gem extension error , followed instructions solve, yet problem persists..

i added 2 paths env var c:\\ruby_devkit\\bin;c:\\ruby_devkit\\mingw\\bin; removes line temporarily enhancing path include devkit... appearing on cmd

finally after much research found culprit rubygems version incompatibility native extension gems!!!

i had ruby gems ver 2.4.1 seems >2.4.0 has these issues

gem update --system 2.3.0 did trick me :)

refer: https://github.com/rubygems/rubygems/issues/977

ruby rubygems devkit

No comments:

Post a Comment