我无法捆绑安装 Ruby On Rails。我收到错误
C:/RailsInstaller/Ruby1.9.3/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 C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:506:in `try_cpp'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:931:in `block in have_header'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:790:in `block in checking_for'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:284:in `block (2 levels) in postpone'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:254:in `open'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:284:in `block in postpone'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:254:in `open'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:280:in `postpone'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:789:in `checking_for'
from C:/RailsInstaller/Ruby1.9.3/lib/ruby/1.9.1/mkmf.rb:930:in `have_header'
from extconf.rb:9:in `<main>'
Gem files will remain installed in C:/sites/rails_projects/sample_app/with-ffi_c-lib/ruby/1.9.1/gems/ffi-1.0.11 for inspection.
Results logged to C:/sites/rails_projects/sample_app/with-ffi_c-lib/ruby/1.9.1/gems/ffi-1.0.11/ext/ffi_c/gem_make.out
An error occured while installing ffi (1.0.11), and Bundler cannot continue.
Make sure that `gem install ffi -v '1.0.11'` succeeds before bundling.
PS C:\sites\rails_projects\sample_app>
当我尝试跑步时gem install ffi -v '1.0.11'
我得到错误
"ERROR: Could not find a valid gem 'ffi-v' <>=0 in any repository
我在谷歌上搜索过,有些人认为我需要安装 ruby devkit 来解决这个问题。问题是,我也无法让它工作。我运行 ruby dk.rb init 命令,初始化完成,但是当我查看 config.yml 文件时,虽然我安装了 ruby,但没有自动列出 rubies。
任何帮助将不胜感激。