0
我想在我的Mac上的rails环境中设置一个ruby,以便开始使用RubyMine IDE。 我用自制,rbenv,为了安装的Ruby/Rails所需的所有其他库 - 但是当我sudo gem install rails
安装失败,因为:Rails安装失败 - 由Nokogiri宝石引起?
Building native extensions. This could take a while...
ERROR: Error installing rails:
ERROR: Failed to build gem native extension.
current directory: /usr/local/lib/ruby/gems/2.3.0/gems/nokogiri-1.6.8.1/ext/nokogiri
/usr/local/opt/ruby/bin/ruby -r ./siteconf20161110-767-xwnfls.rb extconf.rb
checking if the C compiler accepts ... yes
checking if the C compiler accepts -Wno-error=unused-command-line-argument-hard-error-in-future... no
Building nokogiri using packaged libraries.
Using mini_portile version 2.1.0
checking for iconv.h... yes
checking for gzdopen() in -lz... no
zlib is missing; necessary for building libxml2
*** 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.
我试图在它自己的安装引入nokogiri和我得到的以下错误:
ERROR: While executing gem ... (Errno::EACCES)
Permission denied @ rb_sysopen - /usr/local/lib/ruby/gems/2.3.0/gems/nokogiri-1.6.8.1/.autotest
我真的希望有人能帮助我,因为我是一个相当有小白到RonR,我觉得事情变得凌乱目录/权限明智的,
谢谢。
嘿, 我没有那么多的意见,因为我已经安装了问题上下文中所述的自制软件,rbev和rvm。其次,zlib不是自制软件包。只有我已经安装的lzlib。 谢谢 – AcidMicrowave
做'brew search zlib'。我在OS X 10.10上,并拥有该软件包。它可能不在主要存储库中。对不起,我最初误解你已经用'rbenv'设置了一切。如果是这样的话,你不应该使用'sudo'来运行'gem install'。看看你是否可以通过搜索找到'zlib',我记得从Caskroom或其他前缀的10.11开始设置它。 –
我试过寻找它没有运气:(IM在10月12日的方式,我似乎无法弄清楚如何使用Caskroom将帮助我安装它? 再次感谢 – AcidMicrowave