无法安装linecache19 gem [英] Unable to install linecache19 gem

查看:59
本文介绍了无法安装linecache19 gem的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我进行捆绑安装时,我收到以下错误安装linecache19(0.5.11)时发生错误,并且捆绑器无法继续 。完整的跟踪如下:

When i do bundle install im getting the following error "An error occurred while installing linecache19 (0.5.11), and Bundler cannot continue". The complete trace is as follows :

Installing linecache19 (0.5.11) with native extensions 
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.

        /home/raza/.rvm/rubies/ruby-1.9.3-p362/bin/ruby extconf.rb                                                                                                          
checking for vm_core.h... no                                                                                                                                                
/home/raza/.rvm/gems/ruby-1.9.3-p362@holla/gems/ruby_core_source-0.1.4/lib/ruby_core_source.rb:39: Use RbConfig instead of obsolete and deprecated Config.                  
checking for vm_core.h... yes                                                                                                                                               
checking for version.h... yes                                                                                                                                               
checking for RUBY_VERSION_MAJOR in version.h... no                                                                                                                          
Requesting http://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p362.tar.gz                                                                                                     
Downloading http://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p362.tar.gz                                                                                                    
checking for vm_core.h... yes
checking for version.h... yes
checking for RUBY_VERSION_MAJOR in version.h... no
Makefile creation failed
*************************************************************

  NOTE: For Ruby 1.9 installation instructions, please see:

     http://wiki.github.com/mark-moseley/ruby-debug

*************************************************************

*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers.  Check the mkmf.log file for more
details.  You may need configuration options.

Provided configuration options:
        --with-opt-dir
        --with-opt-include
        --without-opt-include=${opt-dir}/include
        --with-opt-lib
        --without-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=.
        --curdir
        --ruby=/home/raza/.rvm/rubies/ruby-1.9.3-p362/bin/ruby
        --with-ruby-dir
        --without-ruby-dir
        --with-ruby-include
        --without-ruby-include=${ruby-dir}/include
        --with-ruby-lib
        --without-ruby-lib=${ruby-dir}/lib


Gem files will remain installed in /home/raza/.rvm/gems/ruby-1.9.3-p362@holla/gems/linecache19-0.5.11 for inspection.
Results logged to /home/raza/.rvm/gems/ruby-1.9.3-p362@holla/gems/linecache19-0.5.11/ext/trace_nums/gem_make.out
An error occurred while installing linecache19 (0.5.11), and Bundler cannot continue.
Make sure that `gem install linecache19 -v '0.5.11'` succeeds before bundling.

然后我尝试运行 gem install linecache19 -v'0.5.11'以及 gem安装linecache19 -v'0.5.11'---with-ruby-include = $ rvm_path / src / ruby​​-1.9.3-p362 ,但仍然面临相同的问题。

I then tried running gem install linecache19 -v '0.5.11' as well as gem install linecache19 -v '0.5.11' -- --with-ruby-include=$rvm_path/src/ruby-1.9.3-p362 but still facing same problem.

我的mkmf.log位于~/.rvm/gems/ruby-1.9.3-p362@holla/gems/linecache19-0.5.11/ext/trace_nums是如下所示:

My mkmf.log located at ~/.rvm/gems/ruby-1.9.3-p362@holla/gems/linecache19-0.5.11/ext/trace_nums is as follows :

have_header: checking for vm_core.h... -------------------- no

"gcc -o conftest -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I.    -I/home/raza/.rvm/usr/include  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC conftest.c  -L. -L/home/raza/.rvm/rubies/ruby-1.9.3-p362/lib -Wl,-R/home/raza/.rvm/rubies/ruby-1.9.3-p362/lib -L/home/raza/.rvm/usr/lib -Wl,-R/home/raza/.rvm/usr/lib -L.  -rdynamic -Wl,-export-dynamic -L/home/raza/.rvm/usr/lib  -Wl,-R/home/raza/.rvm/usr/lib      -Wl,-R -Wl,/home/raza/.rvm/rubies/ruby-1.9.3-p362/lib -L/home/raza/.rvm/rubies/ruby-1.9.3-p362/lib -lruby  -lpthread -lrt -ldl -lcrypt -lm   -lc"
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: int main() {return 0;}
/* end */

"gcc -E -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I.    -I/home/raza/.rvm/usr/include  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC  conftest.c -o conftest.i"
conftest.c:3:21: fatal error: vm_core.h: No such file or directory
compilation terminated.
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: #include <vm_core.h>
/* end */

--------------------

have_header: checking for vm_core.h... -------------------- yes

"gcc -E -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I. -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby-1.9.3-p362  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC  conftest.c -o conftest.i"
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: #include <vm_core.h>
/* end */

--------------------

have_header: checking for version.h... -------------------- yes

"gcc -E -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I. -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby-1.9.3-p362  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC  conftest.c -o conftest.i"
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: #include <version.h>
/* end */

--------------------

have_macro: checking for RUBY_VERSION_MAJOR in version.h... -------------------- no

"gcc -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I. -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby-1.9.3-p362  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC   -c conftest.c"
conftest.c:6:3: error: #error 
conftest.c:7:1: error: expected identifier or ‘(’ before ‘>>’ token
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: #include <version.h>
4: /*top*/
5: #ifndef RUBY_VERSION_MAJOR
6: # error
7: >>>>>> RUBY_VERSION_MAJOR undefined <<<<<<
8: #endif
/* end */

--------------------

have_header: checking for vm_core.h... -------------------- yes

"gcc -E -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I. -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby-1.9.3-p362  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC  conftest.c -o conftest.i"
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: #include <vm_core.h>
/* end */

--------------------

have_header: checking for version.h... -------------------- yes

"gcc -E -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I. -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby-1.9.3-p362  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC  conftest.c -o conftest.i"
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: #include <version.h>
/* end */

--------------------

have_macro: checking for RUBY_VERSION_MAJOR in version.h... -------------------- no

"gcc -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/x86_64-linux -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby/backward -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1 -I. -I/home/raza/.rvm/rubies/ruby-1.9.3-p362/include/ruby-1.9.1/ruby-1.9.3-p362  -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wimplicit-function-declaration  -fPIC   -c conftest.c"
conftest.c:6:3: error: #error 
conftest.c:7:1: error: expected identifier or ‘(’ before ‘>>’ token
checked program was:
/* begin */
1: #include "ruby.h"
2: 
3: #include <version.h>
4: /*top*/
5: #ifndef RUBY_VERSION_MAJOR
6: # error
7: >>>>>> RUBY_VERSION_MAJOR undefined <<<<<<
8: #endif
/* end */

--------------------

我在运行Ubuntu 12.10的计算机上安装IM。如何解决此问题?

Im on a machine running Ubuntu 12.10. How can i fix this problem ?

谢谢

推荐答案

您需要先通过include目录安装ruby-debug。

You need to install ruby-debug first passing the include directory.


gem install ruby​​-debug19-
--with-ruby-include = $ rvm_path / src / ruby​​-1.9.3-p362

gem install ruby-debug19 -- --with-ruby-include=$rvm_path/src/ruby-1.9.3-p362

这篇关于无法安装linecache19 gem的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆