Error installing Nokogiri 1.5.0 with rails 3.1.0 and ubuntu

前端 未结 8 1206
[愿得一人]
[愿得一人] 2020-11-29 03:38

Here is the error running bundle install vendor/gems on server:

Installing nokogiri (1.5.0) with native extensions
Gem::Installer::ExtensionBuildError: ERROR         


        
相关标签:
8条回答
  • 2020-11-29 04:10

    For Ubuntu:

    sudo apt-get install libxml2 libxml2-dev libxslt-dev zlib1g-dev
    sudo gem install nokogiri -v '1.8.2' -- --use-system-libraries 
    

    For MacOS:

    brew install libxml2
    gem install nokogiri -v '1.8.2' -- --use-system-libraries \
      --with-xml2-include=$(brew --prefix libxml2)/include/libxml2
    
    0 讨论(0)
  • 2020-11-29 04:12

    You need to have all the necessary libraries installed on your machine. When you installed RVM , it should have listed this for you. On the current version of rvm, you can run rvm requirements to see the exact list. Right now, that list is:

    sudo apt-get install build-essential openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev automake libtool bison subversion

    0 讨论(0)
提交回复
热议问题