What is a robust installation process for Nokogiri (on Ubuntu)?

前端 未结 5 1851
既然无缘
既然无缘 2020-12-30 13:22

I tried to install Nokogiri on my Ubuntu 12.04 system, and got an error that said \"libxslt is missing\", but the libxslt-dev and libxml2-dev

5条回答
  •  悲&欢浪女
    2020-12-30 14:02

    I'm pretty new to ruby, but this...

    gem install nokogiri -v '1.5.2' -- --with-xml2-lib=/usr/lib/i386-linux-gnu --with-xml2-include=/usr/include/libxml2 --with-xslt-lib=/usr/lib/i386-linux-gnu --with-xslt-include=/usr/include/libxslt
    

    ...worked for me on Ubuntu 12.04. (Or, anyway, it satisfied the nokogiri dependency and got me one step closer to what I'm really trying to accomplish.) I thought it might have messed up my RVM magic, but nokogirl-1.5.2 is definitely sitting there in ~/.rvm/ruby-1.9.3-p194/gems, so...maybe it's all good?

提交回复
热议问题