[英]Ruby On Rails Installation in FreeBSD OS -Error in libv8
我正在使用FreeBSd OS,当我尝试安装libv8时,
gem install libv8
它抛出一个错误......
Building native extensions. This could take a while...
ERROR: Error installing therubyracer:
ERROR: Failed to build gem native extension.
/usr/local/bin/ruby18 extconf.rb
*** 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/local/bin/ruby18
extconf.rb:13: uninitialized constant Gem (NameError)
Checking for Python...
extconf.rb:13: uninitialized constant Gem
我被搞砸了
gem 'therubyracer'
gem 'libv8', '3.3.10.4'
在宝石文件..
这可能发生在Ruby 1.8.7中,它不会像1.9.x那样自动包含ruby gems。 这里有一个github更新: https : //github.com/fractaloop/libv8/blob/master/ext/libv8/extconf.rb
但目前这似乎并未出现在已发布的宝石中。 它应该像安装这样简单:
gem 'libv8', :git => 'git://github.com/fractaloop/libv8.git'
但是从查看源代码,它会动态地将gem版本与v8库的版本相关联,当我尝试它时,它失败了,说它是版本0.0.4。 我在不同的操作系统上,所以试一试,看看它是否适合你。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.