美文网首页
ruby记录

ruby记录

作者: Miley_MOJIE | 来源:发表于2018-02-11 19:20 被阅读0次

    1、Installing nokogiri 1.8.5 with native extensions
    Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
    An error occurred while installing nokogiri (1.8.5), and Bundler cannot continue.
    Make sure that gem install nokogiri -v '1.8.5' --source 'http://gems.ruby-china.com/' succeeds before bundling.
    解决

    • brew install libxml2 libxslt
    • gem install nokogiri -- --use-system-libraries --with-xml2-include=brew --prefix/opt/libxml2/include/libxml2 --with-xml2-lib=brew --prefix/opt/libxml2/lib --with-xslt-dir=brew --prefix/opt/libxslt --with-iconv-include=brew --prefix/opt/libiconv/include/
      2、无法找到openssl
    image.png

    解决
    进入ruby的安装安装包,重新设置openssl的配置路径,重新编译安装ruby
    ./configure --with-openssl-dir=/usr/local/opt/openssl
    make
    make install

    相关文章

      网友评论

          本文标题:ruby记录

          本文链接:https://www.haomeiwen.com/subject/wprltftx.html