From fe16912e9b9466a5a167c962e745d5690459f099 Mon Sep 17 00:00:00 2001 From: Miklos Szeredi Date: Thu, 2 Jun 2011 16:16:39 +0200 Subject: [PATCH] In ./configure check if umount support --fake and --no-canonicalize options and warn othewise --- configure.in | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/configure.in b/configure.in index 0e41cca..aab304b 100644 --- a/configure.in +++ b/configure.in @@ -97,5 +97,27 @@ AM_CONDITIONAL(LINUX, test "$arch" = linux) AM_CONDITIONAL(NETBSD, test "$arch" = netbsd) AM_CONDITIONAL(BSD, test "$arch" = bsd) +util_linux_ok=yes +if test "$arch" = linux -a "$cross_compiling" != "yes"; then + AC_MSG_CHECKING([if umount supports --fake --no-canonicalize]) + # exit code of umount is 1 if option is unrecognised, 2 otherwise + umount --fake --no-canonicalize > /dev/null 2>&1 + if test $? != 1; then + AC_MSG_RESULT([yes]) + else + firstline=`umount --fake --no-canonicalize 2>&1 | head -1` + AC_MSG_RESULT([$firstline]) + util_linux_ok=no + fi +fi + AC_CONFIG_FILES([fuse.pc Makefile lib/Makefile util/Makefile example/Makefile include/Makefile]) AC_OUTPUT + +if test "$util_linux_ok" = no; then + AC_MSG_WARN([ +****************************************************************** +* Please install util-linux version 2.18 or later which supports * +* --fake and --no-canonicalize options in mount and umount * +******************************************************************]) +fi -- 2.30.2