summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2016-02-07 09:33:49 -0500
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2016-02-07 09:33:49 -0500
commitdcd6ecf1e7697dcfe80b7f795914b0e7f4cb486a (patch)
tree2793ac940965bbd336bfa2373337a5959010856f
parentd8889a887b7e79f5e7a2ac2c1b98ffa5e473a2d5 (diff)
parent4c79662e251bea1bfbe18d4374a69bf47aa7a1c6 (diff)
Merge pull request #2541 from mgorny/append-flags-fix
build-sys: Perform flag tests in context of existing flags
-rw-r--r--m4/attributes.m42
1 files changed, 1 insertions, 1 deletions
diff --git a/m4/attributes.m4 b/m4/attributes.m4
index db5df250f4..51ac88be61 100644
--- a/m4/attributes.m4
+++ b/m4/attributes.m4
@@ -43,7 +43,7 @@ AC_DEFUN([CC_CHECK_FLAG_APPEND], [
AC_CACHE_CHECK([if $CC supports flag $3 in envvar $2],
AS_TR_SH([cc_cv_$2_$3]),
[eval "AS_TR_SH([cc_save_$2])='${$2}'"
- eval "AS_TR_SH([$2])='-Werror `echo "$3" | sed 's/^-Wno-/-W/'`'"
+ eval "AS_TR_SH([$2])='${cc_save_$2} -Werror `echo "$3" | sed 's/^-Wno-/-W/'`'"
AC_LINK_IFELSE([AC_LANG_SOURCE(ifelse([$4], [],
[int main(void) { return 0; } ],
[$4]))],