When I run jruby script/rails generate cucumber:install --help I have
this error:
/home/user/jruby/lib/ruby/site_ruby/shared/ffi/library.rb:28:in
`ffi_lib': Could not open library 'xml2' : xml2: cannot open shared
object file: No such file or directory. Could not open library
'libxml2.so' : libxml2.so: cannot open shared object file: No such
file or directory (LoadError)
`ffi_lib’: Could not open library ‘xml2’ : xml2: cannot open shared
object file: No such file or directory. Could not open library
‘libxml2.so’ : libxml2.so: cannot open shared object file: No such
file or directory (LoadError)
You need to install libxml for your os distro, because Nokogiri depends on it and from what I see, Cucumber uses Nokogiri from what I have seen. I have installed this on both osx and Ubuntu Server, let me know if you have any trouble and I can try to dig up my notes.
`ffi_lib’: Could not open library ‘xml2’ : xml2: cannot open shared
object file: No such file or directory. Could not open library
‘libxml2.so’ : libxml2.so: cannot open shared object file: No such
file or directory (LoadError)
You need to install libxml for your os distro, because Nokogiri depends on
it and from what I see, Cucumber uses Nokogiri from what I have seen. I have
installed this on both osx and Ubuntu Server, let me know if you have any
trouble and I can try to dig up my notes.
I’m using debian.
I’ve to install libxml-ruby and nokogiri-ruby packages?
I’m using jruby.
First, I know very little about jruby. But as far as getting cucumber working, I think that you should first just try installing libxml2 - I think you have to use your distro’s package manager or manually install. I would google for libxml2 and debian. Then see if you are getting the same error message.
I think this would solve the problem, because as far as I can see Cucumber installs Nokogiri along with it – at least I am using rvm and I did not have to install Nokogiri to get Cucumber working, so I am making that assumption. Also, someone can correct me if wrong, but I think libxml-ruby is something that sits on top of libxml/libxml2, so I think you have to install libxml first.