summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorLucas De Marchi <lucas.demarchi@profusion.mobi>2012-03-19 13:20:42 -0300
committerLennart Poettering <lennart@poettering.net>2012-03-26 21:02:26 +0200
commiteb2e280f9c59b66965c9316eadc4c113a13ca744 (patch)
treee9f1761d2187d64233cc51480e919ea2f55b8959 /configure.ac
parent169c4f65131fbc7bcb51e7d5487a715cdcd0e0eb (diff)
build-sys: do not set CFLAGS directly
Set a separate variable for adding warning flags. Build systems are not supposed to change CFLAGS and LDFLAGS, these are user variables. Reference: http://www.gnu.org/software/automake/manual/html_node/Flag-Variables-Ordering.html
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac3
1 files changed, 2 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 47a08dda64..ac56bc7176 100644
--- a/configure.ac
+++ b/configure.ac
@@ -60,7 +60,7 @@ if test -z "$GPERF" ; then
AC_MSG_ERROR([*** gperf not found])
fi
-CC_CHECK_CFLAGS_APPEND([ \
+CC_CHECK_FLAGS_APPEND([with_cflags], [CFLAGS], [\
-pipe \
-Wall \
-W \
@@ -105,6 +105,7 @@ CC_CHECK_CFLAGS_APPEND([ \
-fdata-sections \
-Wl,--as-needed \
-Wl,--gc-sections])
+AC_SUBST([WARNINGFLAGS], $with_cflags)
LT_PREREQ(2.2)
LT_INIT