summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPau Espin Pedrol <pespin@sysmocom.de>2017-06-23 11:18:04 +0200
committerPau Espin Pedrol <pespin@sysmocom.de>2017-06-23 15:41:49 +0200
commit1349249f881702d98f8fc59ca2d23b59ffb74ac5 (patch)
tree8d5fa661c64db70ef55f20dd660b2034900a4bf7
parent56c5b949faf31fffb848a0c00e9a6687ef948252 (diff)
configure.ac: Fix C(PP)FLAGS for BSD build
If we pass CFLAGS params to configure, then the CFLAGS set inside configure.ac are not applied and the build fails if -Werror is enabled because then BUILDING_LIBOSMOCORE is not defined. Seeing the following output at configure time in FreeBSD build: ./configure: CFLAGS+= -fsanitize=address -fsanitize=undefined: not found ./configure: CPPFLAGS+= -fsanitize=address -fsanitize=undefined: not found ./configure: CFLAGS+= -DBUILDING_LIBOSMOCORE -Wall: not found ./configure: CPPFLAGS+= -DBUILDING_LIBOSMOCORE -Wall: not found Change-Id: I692bbc66e5343998eec360a02a3a1fe73478c5c6
-rw-r--r--configure.ac8
1 files changed, 4 insertions, 4 deletions
diff --git a/configure.ac b/configure.ac
index 64de4bf6..92544b68 100644
--- a/configure.ac
+++ b/configure.ac
@@ -231,12 +231,12 @@ AC_ARG_ENABLE(sanitize,
[sanitize=$enableval], [sanitize="no"])
if test x"$sanitize" = x"yes"
then
- CFLAGS+=" -fsanitize=address -fsanitize=undefined"
- CPPFLAGS+=" -fsanitize=address -fsanitize=undefined"
+ CFLAGS="$CFLAGS -fsanitize=address -fsanitize=undefined"
+ CPPFLAGS="$CPPFLAGS -fsanitize=address -fsanitize=undefined"
fi
-CFLAGS+=" -DBUILDING_LIBOSMOCORE -Wall"
-CPPFLAGS+=" -DBUILDING_LIBOSMOCORE -Wall"
+CFLAGS="$CFLAGS -DBUILDING_LIBOSMOCORE -Wall"
+CPPFLAGS="$CPPFLAGS -DBUILDING_LIBOSMOCORE -Wall"
AC_ARG_ENABLE(simd,
[AS_HELP_STRING(