From 99a57963c71afa255f50635dd4f7d4ff0b0324aa Mon Sep 17 00:00:00 2001 From: robi6 Date: Fri, 19 Sep 2014 23:48:18 +0200 Subject: fix an Autoconf macro check --- configure.ac | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 98bf660..17080d9 100644 --- a/configure.ac +++ b/configure.ac @@ -35,13 +35,13 @@ AC_MSG_ERROR([library libmagic.so >= 5.04 not found, install package "file-5.04" -AC_ARG_ENABLE(debug,[ --enable-debug Turn on debugging ], - [if test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DDEBUG"; fi]) -AC_ARG_ENABLE(debug-magic,[ --enable-debug-magic Turn on debugging magic-scan-engine ], - [if test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DDEBUG_MAGIC_SCAN"; fi]) -AC_ARG_ENABLE(file-attr,[ --enable-file-attr enable restore of file attribute ], - [if test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DFILE_ATTR"; fi]) -AC_ARG_ENABLE(expert-mode,[ --enable-expert-mode enable advanced options for expert mode ], - [if test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DEXPERT_MODE"; fi]) +AC_ARG_ENABLE(debug,[ --enable-debug Turn on debugging ], + [if test x$enableval == xyes && test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DDEBUG"; fi]) +AC_ARG_ENABLE(debug-magic,[ --enable-debug-magic Turn on debugging magic-scan-engine ], + [if test x$enableval == xyes && test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DDEBUG_MAGIC_SCAN"; fi]) +AC_ARG_ENABLE(file-attr,[ --enable-file-attr enable restore of file attribute ], + [if test x$enableval == xyes && test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DFILE_ATTR"; fi]) +AC_ARG_ENABLE(expert-mode,[ --enable-expert-mode enable advanced options for expert mode ], + [if test x$enableval == xyes && test "$GCC" = "yes"; then CPPFLAGS="$CPPFLAGS -DEXPERT_MODE"; fi]) AC_OUTPUT(Makefile src/Makefile) -- cgit v1.2.3