Getting this error:
# rails c
FFI::NotFoundError: Function 'xmlRelaxNGSetParserStructuredErrors' not found in [libxml2.so, libxslt.so, libexslt.so]
attach_function at /home/prod/.rvm/rubies/jruby-1.6.5/lib/ruby/site_ruby/shared/ffi/library.rb:154
each at org/jruby/RubyArray.java:1612
attach_function at /home/prod/.rvm/rubies/jruby-1.6.5/lib/ruby/site_ruby/shared/ffi/library.rb:150
LibXML at /home/prod/.rvm/gems/jruby-1.6.5@p-ecom1-rails311/gems/nokogiri-1.4.6-java/lib/nokogiri/ffi/libxml.rb:305
Nokogiri at /home/prod/.rvm/gems/jruby-1.6.5@p-ecom1-rails311/gems/nokogiri-1.4.6-java/lib/nokogiri/ffi/libxml.rb:42
(root) at /home/prod/.rvm/gems/jruby-1.6.5@p-ecom1-rails311/gems/nokogiri-1.4.6-java/lib/nokogiri/ffi/libxml.rb:41
require at org/jruby/RubyKernel.java:1038
I have it working on an old server, but seem to have something missing on the new one. The ruby and lib versions seem to be the same on both servers, namely:
ruby -v => jruby 1.6.5 (ruby-1.8.7-p330) (2011-10-25 9dcd388) (OpenJDK 64-Bit Server VM 1.6.0_20) [linux-amd64-java]
Actually - the java version on the old server is the Oracle version...
Centos 5.7
# yum list | egrep "xslt|xml2"
libxml2.i386 2.6.26-2.1.12.el5_7.1 installed
libxml2.x86_64 2.6.26-2.1.12.el5_7.1 installed
libxml2-devel.i386 2.6.26-2.1.12.el5_7.1 installed
libxml2-devel.x86_64 2.6.26-2.1.12.el5_7.1 installed
libxml2-python.x86_64 2.6.26-2.1.12.el5_7.1 installed
libxslt.x86_64 1.1.17-2.el5_2.2 installed
libxslt-devel.x86_64 1.1.17-2.el5_2.2 installed
EDIT: Just tried the Oracle java version to match the old/working box, no joy, although a slightly different error, namely:
$ ruby -v
jruby 1.6.5 (ruby-1.8.7-p330) (2011-10-25 9dcd388) (Java HotSpot(TM) Server VM 1.6.0_29) [linux-i386-java]
$ rails c
LoadError: Could not open library 'xslt' : xslt: cannot open shared object file: No such file or directory. Could not open library 'libxslt.so' : libxslt.so: cannot open shared object file: No such file or directory
ffi_lib at /home/prod/.rvm/rubies/jruby-1.6.5/lib/ruby/site_ruby/shared/ffi/library.rb:82
collect at org/jruby/RubyArray.java:2318
EDIT2:
Tried updating mechanize and nokogiri but seems there are cookie related differences in mechanize 2 - trying to get the github version which seems it should fix this.
EDIT3:
Tried 1.4.7 Nokogiri , but still gives error. For now have installed 1.5 which installs ok - just that it doesnt work in my dev env on OSX. Probably need to raise a bug with nokogiri - but have to write a test program to demonstrate the issue.