summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOlivier CrĂȘte <olivier.crete@collabora.com>2013-09-25 20:28:41 -0400
committerOlivier CrĂȘte <olivier.crete@collabora.com>2013-09-25 20:35:34 -0400
commit96dc161f99ec2058127d50b2bb28ea3e9c2d3835 (patch)
tree452628716b059ebb541077ad00ffdad08a0ec771
parentedf5cf40797eca0e6661fe3b08912a84a39204c3 (diff)
Use AS_IF in configure.ac
https://bugs.freedesktop.org/show_bug.cgi?id=54121
-rw-r--r--configure.ac17
1 files changed, 7 insertions, 10 deletions
diff --git a/configure.ac b/configure.ac
index 5d856e3..5552241 100644
--- a/configure.ac
+++ b/configure.ac
@@ -66,22 +66,19 @@ AS_COMPILER_FLAG(-Wno-unused-parameter,
ifelse(tp_farstream_nano_version, 0, [],
[
- if test x$werror = xyes; then
- ERROR_CFLAGS="$ERROR_CFLAGS -Werror -Wno-error=deprecated-declarations"
- fi
- if test x$wextra = xyes -a \
+ AS_IF([test x$werror = xyes],
+ [ERROR_CFLAGS="$ERROR_CFLAGS -Werror -Wno-error=deprecated-declarations"])
+ AS_IF([test x$wextra = xyes -a \
x$wno_missing_field_initializers = xyes -a \
- x$wno_unused_parameter = xyes; then
- ERROR_CFLAGS="$ERROR_CFLAGS -Wextra -Wno-missing-field-initializers -Wno-unused-parameter"
- fi
+ x$wno_unused_parameter = xyes].
+ [ERROR_CFLAGS="$ERROR_CFLAGS -Wextra -Wno-missing-field-initializers -Wno-unused-parameter"])
])
AC_SUBST(ERROR_CFLAGS)
AC_ARG_ENABLE(coverage, [ --enable-coverage compile with coverage info],[enable_coverage=${enableval}],enable_coverage=no)
-if test "x$enable_coverage" = "xyes"; then
- CFLAGS="$CFLAGS -g -fprofile-arcs -ftest-coverage"
-fi
+AS_IF([test "x$enable_coverage" = "xyes"],
+ [CFLAGS="$CFLAGS -g -fprofile-arcs -ftest-coverage"])
CFLAGS="$CFLAGS"