'Bundle' ruby gem 'gamebox' 问题
'Bundle' issues with ruby gem 'gamebox'
我是第一次使用 gem 'gamebox',我遇到了 运行 问题。我安装了 gem 并生成了指南指示我使用的模板,但是当我尝试将其捆绑时,它抛出了下面详述的错误。
$ bundle install --path lib/dependencies
Fetching gem metadata from https://rubygems.org/.bundle install --path lib/dependencies
.......
Resolving dependencies...
Using rake 0.9.2.2
Using hitimes 1.2.2
Using timers 4.0.1
Using celluloid 0.16.0
Using conject 0.1.8
Using cri 2.1.0
Using diff-lcs 1.2.5
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
/usr/bin/ruby2.1 extconf.rb
checking for socket() in -lsocket... no
checking for gethostbyname() in -lnsl... yes
checking for atan() in -lm... yes
checking for inflate() in -lz... yes
checking for iconv_open() in -liconv... no
checking for libiconv_open() in -liconv... no
checking for libiconv_open() in -llibiconv... no
checking for iconv_open() in -llibiconv... no
checking for iconv_open() in -lc... yes
checking for xmlParseDoc() in -lxml2... no
checking for xmlParseDoc() in -llibxml2... no
checking for xmlParseDoc() in -lxml2... no
*** 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
--without-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=/usr/bin/ruby2.1
--with-iconv-dir
--without-iconv-dir
--with-iconv-include
--without-iconv-include=${iconv-dir}/include
--with-iconv-lib
--without-iconv-lib=${iconv-dir}/lib
--with-zlib-dir
--without-zlib-dir
--with-zlib-include
--without-zlib-include=${zlib-dir}/include
--with-zlib-lib
--without-zlib-lib=${zlib-dir}/lib
--with-socketlib
--without-socketlib
--with-nsllib
--without-nsllib
--with-mlib
--without-mlib
--with-zlib
--without-zlib
--with-iconvlib
--without-iconvlib
--with-iconvlib
--without-iconvlib
--with-libiconvlib
--without-libiconvlib
--with-libiconvlib
--without-libiconvlib
--with-clib
--without-clib
--with-xml2-config
--without-xml2-config
--with-xml2-dir
--without-xml2-dir
--with-xml2-include
--without-xml2-include=${xml2-dir}/include
--with-xml2-lib
--without-xml2-lib=${xml2-dir}/lib
--with-xml2lib
--without-xml2lib
--with-libxml2lib
--without-libxml2lib
--with-xml2lib
--without-xml2lib
extconf failure: need libxml2.
Install the library or try one of the following options to extconf.rb:
--with-xml2-config=/path/to/xml2-config
--with-xml2-dir=/path/to/libxml2
--with-xml2-lib=/path/to/libxml2/lib
--with-xml2-include=/path/to/libxml2/include
extconf failed, exit code 1
Gem files will remain installed in /home/user_id/company_office/lib/dependencies/ruby/2.1.0/gems/libxml-ruby-2.8.0 for inspection.
Results logged to /home/user_id/company_office/lib/dependencies/ruby/2.1.0/extensions/x86_64-linux/2.1.0/libxml-ruby-2.8.0/gem_make.out
An error occurred while installing libxml-ruby (2.8.0), and Bundler cannot
continue.
Make sure that `gem install libxml-ruby -v '2.8.0'` succeeds before bundling.
我尝试使用 gem install libxml-ruby -v '2.8.0'
以及 sudo gem install libxml-ruby -v '2.8.0'
输出以下内容:
$ gem install libxml-ruby -v '2.8.0'
ERROR: While executing gem ... (Errno::EACCES)
Permission denied @ rb_sysopen - /var/lib/gems/2.1.0/gems/libxml-ruby-2.8.0/HISTORY
我是 ruby 和 linux 的新手,如果这是一个愚蠢的问题,我深表歉意。
谢谢
您似乎缺少必需的 C 库。我猜想你需要安装 libxml2-dev(或者你喜欢的 Linux 包管理器中的任何名称)。
我是第一次使用 gem 'gamebox',我遇到了 运行 问题。我安装了 gem 并生成了指南指示我使用的模板,但是当我尝试将其捆绑时,它抛出了下面详述的错误。
$ bundle install --path lib/dependencies
Fetching gem metadata from https://rubygems.org/.bundle install --path lib/dependencies
.......
Resolving dependencies...
Using rake 0.9.2.2
Using hitimes 1.2.2
Using timers 4.0.1
Using celluloid 0.16.0
Using conject 0.1.8
Using cri 2.1.0
Using diff-lcs 1.2.5
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
/usr/bin/ruby2.1 extconf.rb
checking for socket() in -lsocket... no
checking for gethostbyname() in -lnsl... yes
checking for atan() in -lm... yes
checking for inflate() in -lz... yes
checking for iconv_open() in -liconv... no
checking for libiconv_open() in -liconv... no
checking for libiconv_open() in -llibiconv... no
checking for iconv_open() in -llibiconv... no
checking for iconv_open() in -lc... yes
checking for xmlParseDoc() in -lxml2... no
checking for xmlParseDoc() in -llibxml2... no
checking for xmlParseDoc() in -lxml2... no
*** 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
--without-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=/usr/bin/ruby2.1
--with-iconv-dir
--without-iconv-dir
--with-iconv-include
--without-iconv-include=${iconv-dir}/include
--with-iconv-lib
--without-iconv-lib=${iconv-dir}/lib
--with-zlib-dir
--without-zlib-dir
--with-zlib-include
--without-zlib-include=${zlib-dir}/include
--with-zlib-lib
--without-zlib-lib=${zlib-dir}/lib
--with-socketlib
--without-socketlib
--with-nsllib
--without-nsllib
--with-mlib
--without-mlib
--with-zlib
--without-zlib
--with-iconvlib
--without-iconvlib
--with-iconvlib
--without-iconvlib
--with-libiconvlib
--without-libiconvlib
--with-libiconvlib
--without-libiconvlib
--with-clib
--without-clib
--with-xml2-config
--without-xml2-config
--with-xml2-dir
--without-xml2-dir
--with-xml2-include
--without-xml2-include=${xml2-dir}/include
--with-xml2-lib
--without-xml2-lib=${xml2-dir}/lib
--with-xml2lib
--without-xml2lib
--with-libxml2lib
--without-libxml2lib
--with-xml2lib
--without-xml2lib
extconf failure: need libxml2.
Install the library or try one of the following options to extconf.rb:
--with-xml2-config=/path/to/xml2-config
--with-xml2-dir=/path/to/libxml2
--with-xml2-lib=/path/to/libxml2/lib
--with-xml2-include=/path/to/libxml2/include
extconf failed, exit code 1
Gem files will remain installed in /home/user_id/company_office/lib/dependencies/ruby/2.1.0/gems/libxml-ruby-2.8.0 for inspection.
Results logged to /home/user_id/company_office/lib/dependencies/ruby/2.1.0/extensions/x86_64-linux/2.1.0/libxml-ruby-2.8.0/gem_make.out
An error occurred while installing libxml-ruby (2.8.0), and Bundler cannot
continue.
Make sure that `gem install libxml-ruby -v '2.8.0'` succeeds before bundling.
我尝试使用 gem install libxml-ruby -v '2.8.0'
以及 sudo gem install libxml-ruby -v '2.8.0'
输出以下内容:
$ gem install libxml-ruby -v '2.8.0'
ERROR: While executing gem ... (Errno::EACCES)
Permission denied @ rb_sysopen - /var/lib/gems/2.1.0/gems/libxml-ruby-2.8.0/HISTORY
我是 ruby 和 linux 的新手,如果这是一个愚蠢的问题,我深表歉意。 谢谢
您似乎缺少必需的 C 库。我猜想你需要安装 libxml2-dev(或者你喜欢的 Linux 包管理器中的任何名称)。