Skip Menu |

This queue is for tickets about the Perl-Dist-Strawberry CPAN distribution.

Report information
The Basics
Id: 48576
Status: resolved
Priority: 0/
Queue: Perl-Dist-Strawberry

People
Owner: Nobody in particular
Requestors: kmx [...] cpan.org
Cc: cnighswonger [...] foundations.edu
AdminCc:

Bug Information
Severity: Important
Broken in: (no value)
Fixed in: (no value)



Subject: Ext-lib: XML2/XSLT support
Hi, this is another post with a suggestion of reorganising the external libraries bundled with strawberry. Currently the XML2 support in strawberry seems to based on zlatkovic.com binary of libxml2.dll version 2.6.30 (the latest version is 2.7.3 - but it not the main issue). Libxml2 supports works - so why do I propose a change? *) I have tried to add libxslt support (XML::LibXSLT module) to my strawberry. I downloaded lib[e]xslt.dll from zlakovic.com but did not managed to use it due to some linker problems. These maybe caused by the fact that zlatkovic.com binaries are build with MS compiler and it is not so easy to get it work with mingw - standalone libxml2 works fine; however if you add libxslt the new issues appear - XML::LibXSLT is directly using libxml2.dll and libxslt.dll that then indirectly uses again libxml2.dll (the *.a/*.lib files where probably not well generated therefore mingw linker was slightly confused and ended up with some errros). *) So the only way that works for me was to compile a new libxslt/libexslt from sources. As I have considered strange to have libxml2.dll form zlatkovic.com (build by MS compiler) and lib[e]xslt.dll build myself (mingw) - I have also rebuilt libxml2.dll. *) Then another issues regarding DLL names appear. The biggest one was with libxslt.dll as this external library name (placed in c:\strawberry\bin\libxslt.dll) was in a collision with XML::LibXSLT XS library of the same name (placed in c:\strawberry\perl\site\lib\auto\XML\LibXSLT\LibXSLT.dll) - this simply does not work. The solution was to patch XML::LibXSLT to used a different DLL name - latest SVN trunk version uses LibXSLT.xs.dll. Due to some Dynaloader bug in 5.10.0 (fixed in 5.10.1) it does work with strawberry 5.8.9 but not with 5.10.0. *) So I have decided to change the library name libxslt.dll to libxslt_.dll. And to avoid similar issues I have also renamed libxml2.dll to libxml2_.dll (aka "PATH issue" appears if you have in your PATH before strawberry dirs some other directory containing another copy of DLL with the same name - then this "another" DLL is gonna be loaded and strange thing happens). *) And finaly I also feel that there are some useless files installed with LIBXML2 - so we might wath to tidy-up a little bit e.g. c:\strawberry\c\lib\libxml2_a.lib c:\strawberry\c\lib\libxml2_a_dll.lib So what did I do: - compiled: libxml2-2.7.3 libxslt-1.1.24 with mingw compiler (that one included in strawberry) - used alternative DLL names: libxml2_.dll libxslt_.dll libexslt_.dll - successfully tested with: XML::LibXML (1.69) and XML::LibXSLT (svn trunk) Some comments to the build process: - libxml2-2.7.3 libxslt-1.1.24 have mingw makefiles but a little bit violence on them was necessary to produce what I wanted - both libraries has "strange" approach to static vs. dynamic linkage - by default static lib = libxslt.a; dynamic = libxslt.lib (the same for libxml2, libexslt) - if you want to use static lib (without DLL dependency): gcc example.c -DLIBXSLT_STATIC -lxslt - if you want to use dynamic lib (with DLL dependency): gcc example.c -llibxslt - this approach is very unusual; as no Makefile from CPAN I have seen does not use -DLIBXSLT_STATIC option (that is Win32 specific) I have decided to use just the dynamic linking and put into my strawberry perl just dynamic library - I was in doubts what is the right name because some makefiles uses -lxslt (~libxslt.a) and other -llibxslt (~libxslt.lib). In the end I have decided to use the names: libxml2.a libxslt.a libexslt.a - Directly with gcc it works only with options: -lxml2 -lxslt -lexslt - ExtUtils::MakeMaker handles also: -llibxml2 -llibxslt -llibexslt To test the changes I am proposing try this: 1) remove XML2 support currently installed into strawberry del c:\strawberry\c\bin\libxml2.def del c:\strawberry\c\bin\libxml2.dll del c:\strawberry\c\bin\xmlcatalog.exe del c:\strawberry\c\bin\xmllint.exe del c:\strawberry\c\lib\libxml2.a del c:\strawberry\c\lib\libxml2.lib del c:\strawberry\c\lib\libxml2_a.lib del c:\strawberry\c\lib\libxml2_a_dll.lib del /Q c:\strawberry\c\include\libxml\* rmdir c:\strawberry\c\include\libxml 2) Unzip enclosed ZIPs into c:\strawberry\c libxml2-2.7.3-bin_20090810.zip libxslt-1.1.24-bin_20090810.zip 3) Reinstall existing modules binded to removed LIBXML2.DLL cpan -fi XML::LibXML::Common cpan -fi XML::LibXML (I know that both are distributed together; but this works) All test should pass and both modules should install smoothly. 4) XML::LibXSLT - ver. 1.67 is not Win32-ready yet, we need the latest dev release from svn://axkit.org/XML-LibXSLT/trunk - perl makefile.PL - dmake test - dmake install All test should pass and module should install smoothly. It would be nice if you can consider including XSLT support into the next strawberry release. -- kmx
Subject: libxml2-2.7.3-bin_20090810.zip

Message body not shown because it is not plain text.

Subject: libxslt-1.1.24-bin_20090810.zip

Message body not shown because it is not plain text.

Just to record an idea: It would probably be slightly better to link zlib statically into libxml2_.dll (because this DLL is probably the only one binary in the whole strawberry requiring ZLIB1.DLL). -- kmx
Show quoted text
> Just to record an idea: > > It would probably be slightly better to link zlib statically into > libxml2_.dll (because this DLL is probably the only one binary in the > whole strawberry requiring ZLIB1.DLL).
As discussed here: https://rt.cpan.org/Ticket/Display.html?id=48759 - we are probably not able to completely avoid zlib1.dll. So idea of getting rid of zlib1.dll was wrong. -- kmx
Just to record an idea from IRC: I have to rebuild XML2/XSLT with libzlib from zlib.net and libiconv from gnuwin32 (both dynamically linked)
Hi, I have prepared the new rebuild against zlib/iconv setup agreed with CSJewell: - libxslt-1.1.24-bin_20090819.zip - libxml2-2.7.3-bin_20090819.zip Both are ready for release. Tested with XML::LibXML::Common (0.13), XML::LibXML (1.69), XML::LibXSLT (svn trunk). -- kmx
Download libxslt-1.1.24-bin_20090819.zip
application/binary 204.7k

Message body not shown because it is not plain text.

Hi, I have prepared the new rebuild against zlib/iconv setup agreed with CSJewell: - libxslt-1.1.24-bin_20090819.zip - libxml2-2.7.3-bin_20090819.zip Both are ready for release. Tested with XML::LibXML::Common (0.13), XML::LibXML (1.69), XML::LibXSLT (svn trunk). -- kmx
Download libxslt-1.1.24-bin_20090819.zip
application/binary 204.7k

Message body not shown because it is not plain text.

Hi, I have prepared the new rebuild against zlib/iconv setup agreed with CSJewell: - libxslt-1.1.24-bin_20090819.zip - libxml2-2.7.3-bin_20090819.zip Both are ready for release. Tested with XML::LibXML::Common (0.13), XML::LibXML (1.69), XML::LibXSLT (svn trunk). -- kmx
Download libxml2-2.7.3-bin_20090819.zip
application/binary 732.4k

Message body not shown because it is not plain text.

On Wed Aug 19 17:34:44 2009, KMX wrote: Show quoted text
> Hi, > > I have prepared the new rebuild against zlib/iconv setup agreed with > CSJewell: > - libxslt-1.1.24-bin_20090819.zip > - libxml2-2.7.3-bin_20090819.zip > > Both are ready for release.
I only see the second one of those attached to this bug.
Show quoted text
> > - libxslt-1.1.24-bin_20090819.zip > > - libxml2-2.7.3-bin_20090819.zip > > > > Both are ready for release.
> > I only see the second one of those attached to this bug.
These URLs should work: https://rt.cpan.org/Ticket/Attachment/650393/333172/libxslt-1.1.24-bin_20090819.zip https://rt.cpan.org/Ticket/Attachment/650397/333188/libxml2-2.7.3-bin_20090819.zip
... and do not forget to rebuild - XML::LibXML::Common (0.13) - XML::LibXML (1.69) with the new xml2 library -- kmx
LibXSLT is not going to install simply, it looks like. But I'll keep trying. At any rate, the libraries are included (libxml2 first, and libxslt as of r8911) so marking patched. C:\strawberry\cpan>pip http://svn.ali.as/cpan/users/kmx/perl-modules-patched/XML-LibXSLT-1.67.tar.gz CPAN: Time::HiRes loaded ok (v1.9719) Fetching with LWP: http://cpan.strawberryperl.com/authors/01mailrc.txt.gz CPAN: YAML loaded ok (v0.70) CPAN: CPAN::SQLite loaded ok (v0.197) Fetching with LWP: http://cpan.strawberryperl.com/modules/02packages.details.txt.gz Fetching with LWP: http://cpan.strawberryperl.com/modules/03modlist.data.gz Creating database file ... Gathering information from index files ... Populating database tables ... Done! Running make for L/LO/LOCAL/XML-LibXSLT-1.67.tar.gz Checksum for C:\strawberry\cpan\sources\authors\id\L\LO\LOCAL\XML-LibXSLT-1.67.t ar.gz ok CPAN: Archive::Tar loaded ok (v1.52) CPAN.pm: Going to build L/LO/LOCAL/XML-LibXSLT-1.67.tar.gz looking for -llibxslt... no libxslt not found Try setting LIBS and INC values on the command line Or get libxslt and libxml2 from http://www.libxml.org/ If you install via RPMs, make sure you also install the -devel RPMs, as this is where the headers (.h files) are. No 'Makefile' created LOCAL/XML-LibXSLT-1.67.tar.gz C:\strawberry\perl\bin\perl.exe Makefile.PL -- NOT OK Running make test Make had some problems, won't test Running make install Make had some problems, won't install
Subject: Re: [rt.cpan.org #48576] Ext-lib: XML2/XSLT support
Date: Tue, 08 Sep 2009 05:51:57 +0200
To: bug-Perl-Dist-Strawberry [...] rt.cpan.org
From: kmx <kmx [...] volny.cz>
Could you please try to run: d:\unpacked\XML-LibXSLT-1.67> perl Makefile.PL DEBUG=1 And attach the log here? -- kmx
XML-LibXSLT (SVN trunk version; latest CPAn version is not good enough) installs OK - tested on strawberry-perl-5.10.1.0-beta-2.zip. pip http://svn.ali.as/cpan/users/kmx/perl-modules-patched/XML-LibXSLT-1.67.tar.gz I can try to ask XML-LibXSLT author when he is going to release the next version. -- kmx
Please do.
Dne po 28.zář.2009 02:15:03, CSJEWELL napsal(a): Show quoted text
> > Please do.
See http://rt.cpan.org/Ticket/Display.html?id=48247#txn-667455 As you have a bigger authority as Strawberry Perl maintainer you can try to post there your comment to support early release of the new XML::LibXSLT -- kmx
From: cnighswonger [...] foundations.edu
I was able to get this to build on strawberry-perl-5.10.1.0-beta-2. dmake test complained about XML::LibXML being version 1.69 rather than 1.7. I'm not sure where it gets looking for 1.7 as even the current developer's release is only 1.69_2. After changing the tests to look for 1.69 all tests passed with the exception of one in t/15misc.t which attempts to invoke the load_xml method. This method does not appear to exist in the current XML::LibXML code afaict. I'd love to see this part of the final 5.10.1.0 release of strawberry. If I can help, let me know. Regards, Chris
Hi Chris, the strawberry Oct09 beta2 works with: - XML::LibXML 1.69 - XML::LibXSLT that you can download from here: http://svn.ali.as/cpan/users/kmx/perl-modules-patched/XML-LibXSLT-1.67.tar.gz (it SVN export couple of months ago) The author of XML::Lib(XML|XSLT) plans to release both new *XML and *XSLT together as he is gonna introduce some significant changes not compatible with earlier versions (it might be a reason for errors you have described). I am not sure if he is going to release it before mid of Oct (it is AFAIK CSJewell's deadline for getting new releases from CPAN to Oct09 release) - see http://rt.cpan.org/Ticket/Display.html?id=48247 (you can submit there some "supportive" post :) Anyway, dev releases from CPAN or even from SVN have nearly zero chance of being included into strawberry release. -- kmx
On Mon Oct 05 05:17:06 2009, KMX wrote: Show quoted text
> I am not sure if he is going to release it before mid of Oct (it is > AFAIK CSJewell's deadline for getting new releases from CPAN to Oct09 > release) - see http://rt.cpan.org/Ticket/Display.html?id=48247 (you > can > submit there some "supportive" post :) > > Anyway, dev releases from CPAN or even from SVN have nearly zero > chance > of being included into strawberry release.
It looks like Petr has come through with the 1.70 release of XML::LibXSLT. Maybe it will make it into the October release now? Regards, Chris
Hi Chris, Show quoted text
> It looks like Petr has come through with the 1.70 release of > XML::LibXSLT. Maybe it will make it into the October release now?
I have discussed this yesterday with csjewell and he said yes, it will be part of Oct09 release. -- kmx
On Thu Oct 08 09:00:39 2009, KMX wrote: Show quoted text
> Hi Chris, >
> > It looks like Petr has come through with the 1.70 release of > > XML::LibXSLT. Maybe it will make it into the October release now?
> > I have discussed this yesterday with csjewell and he said yes, it will > be part of Oct09 release.
And r9626 installs it.
Since it's in now, I'm setting to patched.
Resolving since October release happened.