Error - “gem install rails” - libxml2 is missing

后端 未结 8 1942
滥情空心
滥情空心 2021-01-05 02:14

I\'ve been working through the Rails install instructions (http://railsapps.github.io/installrubyonrails-mac.html) and everything was okay up until I got to gem instal

8条回答
  •  猫巷女王i
    2021-01-05 03:05

    I just had the same problem and was able to solve it as follows:

    Installing Nokogiri separately worked only when using the system libraries:

    gem install nokogiri -- --use-system-libraries
    

    ...but was still failing when executing bundle install. So just configure bundler to also build Nokogiri using the system libraries:

    bundle config build.nokogiri --use-system-libraries
    

提交回复
热议问题