XS DLL name clashes with DLL that needs to load (Win32) 
Author Message
 XS DLL name clashes with DLL that needs to load (Win32)

I'm using XML::LibXSLT and I need it to run on Win32/Activestate
(5.6.1 build 629).

After finally getting hold of a copy of M$ VC++ v6 (my v5 wouldn't
link perl56.lib) and pasting some of the Win32 work-rounds from
XML/LibXML/Makefile.PL into XML/LibXSLT/Makefile.PL I got it to build.

By when I try to "nmake test" it complains about missing symbols in
libxslt.dll.  This is because it's really looking in
auto/XML/LibXSLT/LibXSLT.dll not libxslt.dll.

My Google Groups search for other people with this problem found only
the following:

http://www.*-*-*.com/ %40tiuk.ti.com

So I tied what it suggested in there and hacked the DLEXT to 'xs.dll' in
the Makefile.  But then the 'bootstrap XML::LibXSLT' failed to find
the DLL.

So then I hacked XML/LibXSLT.pm thus:

{
   local $DynaLoader::dl_dlext = 'xs.dll';
   bootstrap XML::LibXSLT $VERSION;

Quote:
}

Now I have enough work-rounds to get XML::LibXSLT working on Win32
Activestate-629 but it was rather a palaver.

Anyone got any ideas how I can address this more cleanly.

--
     \\   ( )
  .  _\\__[oo

 .  l___\\
  # ll  l\\
 ###LL  LL\\



Sun, 31 Jul 2005 17:12:58 GMT  
 XS DLL name clashes with DLL that needs to load (Win32)

Quote:
>I'm using XML::LibXSLT and I need it to run on Win32/Activestate
>(5.6.1 build 629).

>After finally getting hold of a copy of M$ VC++ v6 (my v5 wouldn't
>link perl56.lib) and pasting some of the Win32 work-rounds from
>XML/LibXML/Makefile.PL into XML/LibXSLT/Makefile.PL I got it to build.

>By when I try to "nmake test" it complains about missing symbols in
>libxslt.dll.  This is because it's really looking in
>auto/XML/LibXSLT/LibXSLT.dll not libxslt.dll.

[ ... ]
I found the following to work, using libxml2-2.4.26
(later versions seem to have problems with the Perl modules,
not just on Win32). First, build libxml2 using the dynamic
target, and install libxml2.lib and libxml2.dll to locations
that VC++ can find them. Use this in building and installing
XML::LibXML::Common and XML::LibXML. Then, for XML::LibXSLT,
as well as this libxml2, use a static libxslt.lib built from
the libxslt sources. For these modules you may also have to add
libraries such as zlib and iconv to the Makefile.PL, if those
were used.

If you want support for exslt in XML::LibXSLT, there may
still be some missing symbols from the (static) libexslt
lib from libxslt, depending on the version you're using.
To resolve these, you may have to add the symbols to the
associated .def file, and perhaps also add some .c files
containing these symbols.

--
best regards,
randy kobes



Sun, 31 Jul 2005 23:45:28 GMT  
 XS DLL name clashes with DLL that needs to load (Win32)

Quote:


> >I'm using XML::LibXSLT and I need it to run on Win32/Activestate
> >(5.6.1 build 629).

> >After finally getting hold of a copy of M$ VC++ v6 (my v5 wouldn't
> >link perl56.lib) and pasting some of the Win32 work-rounds from
> >XML/LibXML/Makefile.PL into XML/LibXSLT/Makefile.PL I got it to build.

> >By when I try to "nmake test" it complains about missing symbols in
> >libxslt.dll.  This is because it's really looking in
> >auto/XML/LibXSLT/LibXSLT.dll not libxslt.dll.
> [ ... ]
> I found the following to work, using libxml2-2.4.26
> (later versions seem to have problems with the Perl modules,
> not just on Win32). First, build libxml2 using the dynamic
> target, and install libxml2.lib and libxml2.dll to locations
> that VC++ can find them. Use this in building and installing
> XML::LibXML::Common and XML::LibXML. Then, for XML::LibXSLT,
> as well as this libxml2, use a static libxslt.lib built from
> the libxslt sources. For these modules you may also have to add
> libraries such as zlib and iconv to the Makefile.PL, if those
> were used.

I think you miss my point.  I have sucessfully built a working
XML::LibXSLT using libxml2.dll and libxslt.dll and without having to
resort to static linking.  

Actually if it had occured to me to statically link libxslt.lib into
auto/XML/LibXSLT/LibXSLT.dll I'd probably have done so but it didn't
occur to me. :-)

The topic of discussion I was hoping for in this thread was a more
general solution to the problem of DLL name-clashes in XS on Win32.  I
was only citing the auto/XML/LibXSLT/LibXSLT.dll vs libxslt.dll clash
as an example.

--
     \\   ( )
  .  _\\__[oo

 .  l___\\
  # ll  l\\
 ###LL  LL\\



Mon, 01 Aug 2005 03:06:41 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. DESENDING SORT OF DATES IN A TABLE

2. How do I use SQL in Btrieve v6.15 with Titan Btrieve?

3. Help with, IF-THEN-ELSE statements

4. Creating xs layer with specific name of the rersulting XS DLL

5. Creating xs layer with specific name of the rersulting XS DLL

6. Unable to load ISAPI dll perlis.dll

7. PerlMagick with ActivePerl (perlis.dll) on NT4 / IIS4 wont load Magick.dll for Dynaloader.pm

8. using other DLLs in XS under Win32

9. Almost able to compile Crypt::Blowfish on Win32 - need DLL help

10. h2xs: Generating wrappers for Win32 dlls -- need GUID

11. XS code to call DLL

12. XS DLL Wrapper Code: Please Review

 

 
Powered by phpBB® Forum Software