summaryrefslogtreecommitdiffstats
path: root/Configure
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2015-11-09 09:50:56 +0100
committerRichard Levitte <levitte@openssl.org>2015-11-09 12:15:07 +0100
commitc8cc43108d97517dfce25a114acd5651f5548cd5 (patch)
tree47e6d3bc6cb081fd6dcb2c54073394621f1b9a62 /Configure
parent1fe1c65c3ba96dd89e6c805331204428a27d4b6c (diff)
Make the match for previous cflags a bit more strict
./Configure [target] --strict-warnings -Wno-pedantic-ms-format would not add '-pedantic' because it matches '-Wno-pedantic-ms-format', which was added first. Reviewed-by: Matt Caswell <matt@openssl.org> (cherry picked from commit 6703c4ea87b30554283deaa5df1f8d68725d3ee4)
Diffstat (limited to 'Configure')
-rwxr-xr-xConfigure4
1 files changed, 2 insertions, 2 deletions
diff --git a/Configure b/Configure
index c9dedcd37d..fdf8d9a97e 100755
--- a/Configure
+++ b/Configure
@@ -1584,13 +1584,13 @@ if ($strict_warnings)
die "ERROR --strict-warnings requires gcc or clang" unless ($ecc =~ /gcc$/ or $ecc =~ /clang$/);
foreach $wopt (split /\s+/, $gcc_devteam_warn)
{
- $cflags .= " $wopt" unless ($cflags =~ /$wopt/)
+ $cflags .= " $wopt" unless ($cflags =~ /(^|\s)$wopt(\s|$)/)
}
if ($ecc eq "clang")
{
foreach $wopt (split /\s+/, $clang_devteam_warn)
{
- $cflags .= " $wopt" unless ($cflags =~ /$wopt/)
+ $cflags .= " $wopt" unless ($cflags =~ /(^|\s)$wopt(\s|$)/)
}
}
}