Nokogiri says versions of Libxml2 above 2.9.0 are broken, is it?
Asked Answered
D

1

7

The message on installation says so, but I can't find any reference to it. "are currently known to be broken", but known by whom, and what is the problem? I've checked the Nokogiri code base and issue log, but I can't find the reference to this.

Here's the (relevant parts of the) message Nokogiri (v1.6.3.1 in this case) gives:

IMPORTANT!  Nokogiri builds and uses a packaged version of libxml2.

If this is a concern for you and you want to use the system library
instead, abort this installation process and reinstall nokogiri as
follows:

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

If you are using Bundler, tell it to use the option:

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

However, note that nokogiri does not necessarily support all versions
of libxml2.

For example, libxml2-2.9.0 and higher are currently known to be broken
and thus unsupported by nokogiri, due to compatibility problems and
XPath optimization bugs.
Default answered 29/10, 2014 at 15:58 Comment(4)
The XPath optimization bug is probably this issue. This was my fault but it is fixed in the current 2.9.2 release.Discourtesy
@Discourtesy Kudos to you for taking responsibility like that, and thanks for the info. Mystery 33% solved! Now to find out what the "compatibility problems" are, and why known is so hard to know :-)Default
Hi Guys, I'm using yosemite and this is happening to me. Any help???Calcifuge
@Calcifuge could it be related to this issue ?Default
D
1

There might be two ways: 1. use system libraries as it indicate:

gem install nokogiri -- --use-system-libraries 
  1. it might be grep problem, indicated here, and you might be able to get over it by a shell command (assuming using Bash):

export GREP_OPTIONS="--color=auto"

Derouen answered 22/3, 2015 at 23:45 Comment(1)
This doesn't answer the question so I can't give it the tick, but it may be helpful to others so best to leave it here.Default

© 2022 - 2024 — McMap. All rights reserved.