summaryrefslogtreecommitdiffstats
path: root/Configure
diff options
context:
space:
mode:
authorEmilia Kasper <emilia@openssl.org>2015-10-09 20:00:53 +0200
committerEmilia Kasper <emilia@openssl.org>2015-10-14 17:10:20 +0200
commit58dd1ce91aeafb513fa9fd09740e3151c2479314 (patch)
treecb89f958ae6407db6e27db000ece79f968a6b244 /Configure
parent4ec36aff2a3c221b640dafa56ac838312e6724f4 (diff)
make depend: prefer clang over makedepend
Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'Configure')
-rwxr-xr-xConfigure7
1 files changed, 4 insertions, 3 deletions
diff --git a/Configure b/Configure
index 06b2278c16..9ff6e70dd8 100755
--- a/Configure
+++ b/Configure
@@ -1635,10 +1635,11 @@ if ($shlib_version_number =~ /(^[0-9]*)\.([0-9\.]*)/)
$shlib_minor=$2;
}
+my $ecc = $cc;
+$ecc = "clang" if `$cc --version 2>&1` =~ /clang/;
+
if ($strict_warnings)
{
- my $ecc = $cc;
- $ecc = "clang" if `$cc --version 2>&1` =~ /clang/;
my $wopt;
die "ERROR --strict-warnings requires gcc or clang" unless ($ecc =~ /gcc(-\d(\.\d)*)?$/ or $ecc =~ /clang$/);
foreach $wopt (split /\s+/, $gcc_devteam_warn)
@@ -1703,7 +1704,7 @@ while (<IN>)
s/^CC=.*$/CC= $cc/;
s/^AR=\s*ar/AR= $ar/;
s/^RANLIB=.*/RANLIB= $ranlib/;
- s/^MAKEDEPPROG=.*$/MAKEDEPPROG= $cc/ if $cc eq "gcc" || ($cc eq 'cc' && $target =~ /darwin/);
+ s/^MAKEDEPPROG=.*$/MAKEDEPPROG= $cc/ if $ecc eq "gcc" || $ecc eq "clang";
}
s/^CFLAG=.*$/CFLAG= $cflags/;
s/^DEPFLAG=.*$/DEPFLAG=$depflags/;