From 3a1548643f3f9ef6905e31bcde8603a525789abc Mon Sep 17 00:00:00 2001 From: Andy Polyakov Date: Mon, 18 Sep 2017 16:30:28 +0200 Subject: Configure: unify clang's -Qunused-arguments option treatment. Detect clang even if it's disguised, e.g. cross-compiler or invoked by explicit path name, and add the option based on that. Reviewed-by: Ben Kaduk (Merged from https://github.com/openssl/openssl/pull/4383) --- Configure | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'Configure') diff --git a/Configure b/Configure index 4d74b432eb..326a3ff434 100755 --- a/Configure +++ b/Configure @@ -141,7 +141,6 @@ my $gcc_devteam_warn = "-DDEBUG_UNUSED" # -Wunused-macros -- no, too tricky for BN and _XOPEN_SOURCE etc # -Wextended-offsetof -- no, needed in CMS ASN1 code my $clang_devteam_warn = "" - . " -Qunused-arguments" . " -Wswitch-default" . " -Wno-parentheses-equality" . " -Wno-language-extension-token" @@ -1321,6 +1320,10 @@ if (defined($config{api})) { push @{$config{defines}}, $apiflag; } +if (defined($predefined{__clang__}) && !$disabled{asm}) { + $config{cflags} .= " -Qunused-arguments"; +} + if ($strict_warnings) { my $wopt; -- cgit v1.2.3