]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
lib: fix ismounted includes for FreeBSD
authorRuediger Meier <ruediger.meier@ga-group.nl>
Wed, 17 Feb 2016 22:28:52 +0000 (23:28 +0100)
committerRuediger Meier <ruediger.meier@ga-group.nl>
Thu, 18 Feb 2016 15:54:32 +0000 (16:54 +0100)
Signed-off-by: Ruediger Meier <ruediger.meier@ga-group.nl>
configure.ac
lib/ismounted.c

index 535df03fb0ac425d4f997ce16ea1c408643909a1..227ba253f25ebac33e00dd72ce244813d729eb42 100644 (file)
@@ -237,6 +237,7 @@ AC_CHECK_HEADERS([ \
        sys/ioccom.h \
        sys/ioctl.h \
        sys/mkdev.h \
+       sys/mount.h \
        sys/param.h \
        sys/prctl.h \
        sys/queue.h \
@@ -251,6 +252,7 @@ AC_CHECK_HEADERS([ \
        sys/timex.h \
        sys/ttydefaults.h \
        sys/types.h \
+       sys/ucred.h \
        sys/un.h \
        unistd.h \
 ])
index 90952905d03bd15fa0366793437e51e22f45f183..f83be65e09b40aca71a3e444b3beb250e1cf016c 100644 (file)
 #include <sys/stat.h>
 #include <ctype.h>
 #include <sys/param.h>
-#ifdef __APPLE__
-#include <sys/ucred.h>
-#include <sys/mount.h>
+
+#ifndef __linux__
+# ifdef HAVE_SYS_UCRED_H
+#  include <sys/ucred.h>
+# endif
+# ifdef HAVE_SYS_MOUNT_H
+#  include <sys/mount.h>
+# endif
 #endif
 
 #include "pathnames.h"