简体   繁体   中英

Issue with Ruby gem install

I am trying to install json on windows as follows, but its not working. Please help me with possible resoultion for the same.

C:\Ruby193\bin>gem install --local json-1.8.1.gem
Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
ERROR:  Error installing json-1.8.1.gem:
        ERROR: Failed to build gem native extension.

    C:/Ruby193/bin/ruby.exe -r ./siteconf20140725-4216-11o740j.rb extconf.rb
creating Makefile

make  clean
Makefile:165: *** target pattern contains no `%'.  Stop.

make
Makefile:165: *** target pattern contains no `%'.  Stop.

make failed, exit code 2

Gem files will remain installed in C:/Ruby193/lib/ruby/gems/1.9.1/gems/json-1.8.1 for inspection.
Results logged to C:/Ruby193/lib/ruby/gems/1.9.1/extensions/x86-mingw32/1.9.1/json-1.8.1/gem_make.out

RubyGems 2.4.1 will not build native extensions in Ruby version 1.9.3 and earlier on Windows.

You will need to downgrade RubyGems to 1.8.29. To do this run the following command:

gem update --system 1.8.29

Check gem version:

gem -v
1.8.29

Now try your command again:

gem install --local json-1.8.1.gem

ref: https://groups.google.com/forum/#!topic/rubyinstaller/k19SeJijpKU/discussion

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM