develooper Front page | perl.perl5.porters | Postings from October 2003

[PATCH] ExtUtils::Liblist/Kid.pm doesn't see import libraries on Cygwin

From:
Gerrit P. Haase
Date:
October 11, 2003 05:06
Subject:
[PATCH] ExtUtils::Liblist/Kid.pm doesn't see import libraries on Cygwin
Message ID:
61-878521888.20031011141153@familiehaase.de
Hallo Michael,

Cygwin needs this change in Liblist/Kid.pm because there are several
import libraries installed without having a static library besides and
these are not recognized by Kid.pm.

Former pratice was to name the import libraries like the static libs,
or to have both, now this was switched and all import libraries
(besides w32api libs and libcygwin itself) should use the importlib
suffix .dll.a. 

This breaks building modules, e.g libgmp.dll.a will not be found where
a libgmp.a will be found by Liblist/Kid.pm.  If there is no static
libgmp.a then the link fails because the Liblist contains nothing.

The patch (also attached):
--- lib/ExtUtils/Liblist/Kid.pm~       2003-10-11 12:11:00.137542400 +0200
+++ lib/ExtUtils/Liblist/Kid.pm        2003-10-11 12:10:49.882796800 +0200
@@ -132,6 +132,7 @@
                 && ($thislib .= "_s") ){ # we must explicitly use _s version
            } elsif (-f ($fullname="$thispth/lib$thislib$Config_libext")){
            } elsif (-f ($fullname="$thispth/$thislib$Config_libext")){
+           } elsif (-f ($fullname="$thispth/lib$thislib.dll$Config_libext")){
            } elsif (-f ($fullname="$thispth/Slib$thislib$Config_libext")){
            } elsif ($^O eq 'dgux'
                 && -l ($fullname="$thispth/lib$thislib$Config_libext")

# END

Gerrit
-- 
=^..^=


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About