glejeune / ruby-xslt

Ruby/XSLT is a simple XSLT class based on libxml <xmlsoft.org/> and libxslt <xmlsoft.org/XSLT/>

Home Page:http://algorithmique.net

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Windows support

CAMOBAP opened this issue · comments

Questions

  1. Is this module expect to be compiled on windows machine?
  2. If so what are the steps?

What I have tried

  1. Install chocolatey as described here https://chocolatey.org/install
  2. Install libxml & libxslt as described here https://stackoverflow.com/a/22210252
  3. Run gem install ruby-xslt -- --with-xml2-include=C:\ProgramData\chocolatey\lib\libxml2\build\native\include --with-xml2-lib=C:\ProgramData\chocolatey\lib\libxml2.redist\build\native\bin\v110\x64\Release\dynamic\cdecl --with-xslt-include=C:\ProgramData\chocolatey\lib\libxslt\build\native\include --with-xslt-lib=C:\ProgramData\chocolatey\lib\libxslt.redist\build\native\bin\v110\x64\Release\dynamic --enable-exslt

Result:

extconf.rb:57:in ``': No such file or directory - xml2-config --cflags (Errno::ENOENT)
from extconf.rb:57:in `

'

Full logs:

Issue was resolved by adding to %PATH% two simple/dummy scripts xml2-config.bat and xslt-config.bat with content @ECHO OFF

Now I fighting with runtime issue

LoadError (126: The specified module could not be found. - C:/tools/ruby25/lib/ruby/gems/2.5.0/gems/ruby-xslt-0.9.10/lib/xml/xslt_lib.so)

Problem above was fixed by using dll's from cinst xsltproc, I just copied them to ruby bin directory, RUBY_DLL_PATH doesn't work for some reason

RUBY_DLL_PATH works I forgot mention that ruby-xslt rely on dlls without version in filename so libxml2-2.dll need to be duplicated with libxml2.dll and so on