【发布时间】:2015-02-26 20:00:56
【问题描述】:
我对 Ruby on Rails 完全陌生,并且在创建新的 Rails 项目时遇到了一些困难。每次运行“捆绑安装”命令时,我都会收到以下错误:
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
C:/Ruby193/bin/ruby.exe -r ./siteconf20150226-7776-brvf10.rb extconf.rb
checking for rb_method_entry_t.called_id in method.h... no
checking for rb_control_frame_t.method_id in method.h... no
checking for rb_method_entry_t.called_id in method.h... no
checking for rb_control_frame_t.method_id in method.h... no
checking for rb_method_entry_t.called_id in method.h... yes
checking for vm_core.h... yes
checking for iseq.h... yes
checking for insns.inc... yes
checking for insns_info.inc... yes
checking for eval_intern.h... yes
checking for struct iseq_line_info_entry in vm_core.h,iseq.h... no
checking for struct iseq_insn_info_entry in vm_core.h,iseq.h... yes
checking for if rb_iseq_compile_with_option was added an argument filepath..
s
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/debug
1.6.8 for inspection.
Results logged to C:/Ruby193/lib/ruby/gems/1.9.1/extensions/x86-mingw32/1.9.
bugger-1.6.8/gem_make.out
An error occurred while installing debugger (1.6.8), and Bundler cannot
continue.
Make sure that `gem install debugger -v '1.6.8'` succeeds before bundling.
现在我已经尝试了一切,从安装调试器版本 1.6.8,删除然后重新安装它,删除 Gemfile.LOCK 并创建一个新的 rails 项目,但我仍然得到错误。我正在使用来自http://rubyinstaller.org/downloads/ 的Ruby 安装程序“Ruby 1.9.3-p551”和来自同一个网站的DevKit-tdm-32-4.5.2-20111229-1559-sfx.exe。我尝试安装 byebug,但与我的 Ruby 版本不兼容。
有人有什么建议吗?
非常感谢您!
【问题讨论】:
-
你需要能够编译
c/c++,我不确定在 Windows 上这样做,但我认为你可以从 MS 下载一些东西来做到这一点。 -
大多数时候我建议在 *nix 机器上进行任何类型的 Web 开发,因为这样更容易做很多事情。
-
感谢您的建议 :))
标签: ruby-on-rails ruby installation bundle