Perl CFLAGS and LDFLAGS change

Petr Pisar ppisar at redhat.com
Thu Jul 9 15:24:11 UTC 2015


On Wed, Jul 08, 2015 at 02:25:11PM +0200, Petr Pisar wrote:
> It turned out that perl is broken too. Fortunately, only /usr/bin/perl is
> broken. Not the libperl.so or any other XS modules. This issue is known as
> <https://bugzilla.redhat.com/show_bug.cgi?id=1238804>.
> 
> Playing with perl's Configure arguments shows different options are used at
> different places and the best configuration looks like this (from perl.spec):
> 
> -/bin/sh Configure -des -Doptimize="$RPM_OPT_FLAGS" \
> -        -Dccdlflags="-Wl,--enable-new-dtags" \
> -        -Dlddlflags="-shared $RPM_OPT_FLAGS $RPM_LD_FLAGS" \
> +# ldflags is not used when linking XS modules.
> +# Only ldflags is used when linking miniperl.
> +# Only ccflags and ldflags are used for Configure's compiler checks.
> +# Set optimize=none to prevent from injecting upstream's value.
> +/bin/sh Configure -des \
> +        -Doptimize="none" \
> +        -Dccflags="$RPM_OPT_FLAGS" \
> +        -Dldflags="$RPM_LD_FLAGS" \
> +        -Dccdlflags="-Wl,--enable-new-dtags $RPM_LD_FLAGS" \
> +        -Dlddlflags="-shared $RPM_LD_FLAGS" \
> 
I did it in perl-5.22.0-347.fc23.

-- Petr
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 213 bytes
Desc: not available
URL: <http://lists.fedoraproject.org/pipermail/perl-devel/attachments/20150709/d6314d4c/attachment.sig>


More information about the perl-devel mailing list