Perl 5.10 stabilization

Reini Urban
Thu May 8 17:45:00 GMT 2008

Yaakov (Cygwin Ports) schrieb:
> Reini Urban wrote:
> | I tried both ways.
> | The standard perl way with Win32CORE.a explicitly added to
> | the linker line via $Config{static_ext}, and
> Of course, but that makes things difficult when linking *other packages*
> against libperl with libtool.  libtool won't link a shared library
> against a static one on Cygwin, so if DynaLoader.a and Win32CORE.a are
> among LIBS, libtool will complain, drop them, and the link will fail due
> to undefined symbols boot_{DynaLoader,Win32CORE).
> I don't want, nor need, perl to be built with libtool.  All I want is to
> link other packages against libperl with libtool.

I see. To summarize:
   DynaLoader.o is contained in libperl.dll.a,
   Win32CORE.a not.
   ExtUtils::Embed ldopts is correct, but not libtool compatible.

Note: the next -e 'cmd' looks weird, but is needed for the -e one-liner.
$ perl5.10.0d -MExtUtils::Embed -e'ccflags; print ldopts(1)'

-fno-strict-aliasing -pipe -I/usr/local/include 
-Wl,--enable-auto-import -Wl,--export-all-symbols -Wl,--stack,8388608 
-Wl,--enable-auto-image-base -L/usr/local/lib 
  -L/usr/lib/perl5/5.10/i686-debug-cygwin/CORE -lperl -ldl -lcrypt 

libtool will not link a dynamic lib with a static lib, but ld does. Hmm.
Is this really true?
Do you have an example?
perl-5.8.8 had the very same issue, there was even DynaLoader.a needed.

I would rather complain at libtool, because it inspects the libs and 
should know to get the -Wl,--Bstatic <staticlibs> -Wl,--Bdynamic 
<dynamiclibs> cmdline right in such a case.

And I'm more afraid to break some perl packages by defining static_ext, 
but leaving out Win32CORE.a.
Reini Urban

More information about the Cygwin-apps mailing list