gpt4 book ai didi

ruby-on-rails-3 - json gem 不会安装在 Windows 上

转载 作者:行者123 更新时间:2023-12-04 17:26:13 25 4
gpt4 key购买 nike

这是我不断收到的错误。我安装了 DevKit 并按照所有说明进行操作。

gem install json -v '1.6.3'
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing json:
ERROR: Failed to build gem native extension.

"C:/Program Files/Ruby/Ruby192/bin/ruby.exe" extconf.rb
creating Makefile

make
Makefile:160: warning: overriding commands for target `C:/Program'
Makefile:153: warning: ignoring old commands for target `C:/Program'
C:/Program Files/Ruby/Ruby192/bin/ruby -e "puts 'EXPORTS', 'Init_parser'" > par
ser-i386-mingw32.def
/bin/sh: C:/Program: No such file or directory
make: *** [parser-i386-mingw32.def] Error 127


Gem files will remain installed in C:/Program Files/Ruby/Ruby192/lib/ruby/gems/1.9.1/gems/json-1.6.3 for inspection.
Results logged to C:/Program Files/Ruby/Ruby192/lib/ruby/gems/1.9.1/gems/json-1.6.3/ext/json/ext/parser/gem_make.out

有人对此有解决方案吗?

最佳答案

刚刚也遇到了这个。通过Installing dm-types on Windows. (Win7 x64) :这修复了它:

它看起来 ruby 路径中的空格正在搞砸makefile。也许尝试暂时在 Windows 上创建一个符号链接(symbolic link),例如:

mklink /d c:\ruby "C:\Program Files (x86)\Ruby\Ruby193"

然后尝试使用 c:\ruby\bin\ruby.exe 安装。您可以在安装后删除符号链接(symbolic link)。

关于ruby-on-rails-3 - json gem 不会安装在 Windows 上,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8917667/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com