summaryrefslogtreecommitdiffstats
path: root/configure.ac
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2014-03-29 11:22:29 +0100
committerChristophe Grenier <grenier@cgsecurity.org>2014-03-29 11:22:29 +0100
commitcd5f3bea4c6ce15832badd350d35d5f13dd899f7 (patch)
tree235a81f28ab7ac99ae59a0c422b21d2bfe51333e /configure.ac
parent24d570d6635c918dd2d2b26a7c4195231d2268f5 (diff)
Disable assert() code when compiling for powerpc-apple-darwin
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac14
1 files changed, 14 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index ed8e1e4..1d19808 100644
--- a/configure.ac
+++ b/configure.ac
@@ -179,6 +179,15 @@ AC_ARG_WITH([uuid],
# AS_HELP_STRING(--with-carvpath-includes=DIR,location of the carvpath includes files),
# [CPPFLAGS="${CPPFLAGS} -I${withval}"])
+AC_ARG_ENABLE([assert],
+ AS_HELP_STRING(--enable-assert, enable compilation of assert code (default is YES)),
+ [case "${enableval}" in
+ yes) use_assert=true ;;
+ no) use_assert=false ;;
+ *) AC_MSG_ERROR([bad value ${enableval} for --enable-assert]) ;;
+ esac],
+ [use_assert=true])
+
AC_ARG_ENABLE([sudo],
AS_HELP_STRING(--enable-sudo,enable use of sudo (default is NO)),
[case "${enableval}" in
@@ -809,6 +818,11 @@ then
AC_DEFINE_UNQUOTED([SUDO_BIN], "$SUDO_BIN", [Path to sudo for privileged operations])
fi
+if test "$use_assert" = "false";
+then
+ AC_DEFINE(NDEBUG, 1, [Disable the assert error checking])
+fi
+
#reiserfs_fs_open_fast may not been detected because of lack of -ldal
OLDLIBS="$LIBS"
LIBS="$OLDLIBS $testdisk_LDADD -ldal"