我一直想跑bundle install.以下是我输入的一系列命令以及错误消息的相关片段.
bundle update
Run Code Online (Sandbox Code Playgroud)
安装linecache时出错(0.46),Bundler无法继续.在捆绑之前
确保gem install linecache -v '0.46'成功.
gem install linecache -v '0.46'
Run Code Online (Sandbox Code Playgroud)
还不能处理1.9.x.
gem install linecache19
Run Code Online (Sandbox Code Playgroud)
检查vm_core.h ...没有
最后:
gem install linecache19 -- --with-ruby-include=/opt/t/rvm/src/ruby-1.9.3-p194
ERROR: Error installing linecache19:
ERROR: Failed to build gem native extension.
/opt/t/rvm/rubies/ruby-2.0.0-p0/bin/ruby extconf.rb --with-ruby-include=/opt/t/rvm/src/ruby-1.9.3-p194
checking for vm_core.h... yes
checking for version.h... yes
creating Makefile
make
compiling trace_nums.c
In file included from trace_nums.c:21:
/opt/t/rvm/src/ruby-1.9.3-p194/vm_core.h:311:5: error: unknown type name 'rb_event_hook_t'; did you mean 'rb_event_flag_t'?
rb_event_hook_t *event_hooks;
^~~~~~~~~~~~~~~
rb_event_flag_t
/opt/t/rvm/rubies/ruby-2.0.0-p0/include/ruby-2.0.0/ruby/ruby.h:1602:23: note: 'rb_event_flag_t' …Run Code Online (Sandbox Code Playgroud) 在相应的目录中运行"bundle install"时,我得到了以下错误:
An error occurred while installing linecache19 (0.5.12), and Bundler cannot continue.
Make sure that `gem install linecache19 -v '0.5.12'` succeeds before bundling.
Run Code Online (Sandbox Code Playgroud)
在尝试运行gem install linecache19 -v '0.5.12'(如上所述)时,我收到以下错误:
nishant@nishant-Inspiron-1545:~/voylla_website$ gem install linecache19 -v '0.5.12'
Building native extensions. This could take a while...
ERROR: Error installing linecache19:
ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb
checking for vm_core.h... no
/home/nishant/.rvm/gems/ruby-1.9.2-p320/gems/ruby_core_source-0.1.5/lib/ruby_core_source.rb:39: Use RbConfig instead of obsolete and deprecated Config.
checking for vm_core.h... no
*** extconf.rb failed ***
Could …Run Code Online (Sandbox Code Playgroud) 我已经决定摆脱rvm,我在使用新版本的ruby 1.9.2编译gem时遇到了麻烦.宝石需要1.9.2,我有它,但说不能没有安装,所以错误消息没有意义.
如何明确告诉gem使用所述版本的ruby进行编译?
Gem::InstallError: linecache19 requires Ruby version >= 1.9.2.
An error occured while installing linecache19 (0.5.12), and Bundler cannot continue.
Make sure that `gem install linecache19 -v '0.5.12'` succeeds before bundling.
apps2 ~/projects/sms/apps2/apps2_admin $ ruby -v
ruby 1.9.2p180 (2011-02-18 revision 30909) [x86_64-darwin10.8.0]
apps2 ~/projects/sms/apps2/apps2_admin $ which ruby
/usr/local/bin/ruby
Run Code Online (Sandbox Code Playgroud)