In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/07fd17ee52a0c9e57138b5cb43fa8b18dcd3b06a?hp=b7e6151cbc27942266f736d4706550bc35a29639>
- Log ----------------------------------------------------------------- commit 07fd17ee52a0c9e57138b5cb43fa8b18dcd3b06a Author: David Mitchell <[email protected]> Date: Fri Dec 19 11:40:33 2014 +0000 ExtUtils::Embed: silence test warning From the added code comments: XXX DAPM 12/2014: ExtUtils::Embed doesn't seem to provide API access to $Config{optimize} and so compiles the test code without optimisation on optimised perls. This causes the compiler to warn when -D_FORTIFY_SOURCE is in force without -O. For now, just strip the fortify on optimised builds to avoid the warning. ----------------------------------------------------------------------- Summary of changes: lib/ExtUtils/t/Embed.t | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/ExtUtils/t/Embed.t b/lib/ExtUtils/t/Embed.t index 4e05cfe..a0ab1d2 100644 --- a/lib/ExtUtils/t/Embed.t +++ b/lib/ExtUtils/t/Embed.t @@ -72,7 +72,15 @@ if ($^O eq 'VMS') { push @cmd, "-non_shared"; } - push(@cmd,"-I$inc",ccflags(),'embed_test.c'); + # XXX DAPM 12/2014: ExtUtils::Embed doesn't seem to provide API access + # to $Config{optimize} and so compiles the test code without + # optimisation on optimised perls. This causes the compiler to warn + # when -D_FORTIFY_SOURCE is in force without -O. For now, just strip + # the fortify on optimised builds to avoid the warning. + my $ccflags = ccflags(); + $ccflags =~ s/-D_FORTIFY_SOURCE=\d+// if $Config{optimize} =~ /-O/; + + push(@cmd, "-I$inc", $ccflags, 'embed_test.c'); if ($^O eq 'MSWin32') { $inc = File::Spec->catdir($inc,'win32'); push(@cmd,"-I$inc"); -- Perl5 Master Repository
