diff options
author | Eelco Dolstra <e.dolstra@tudelft.nl> | 2007-10-29 10:03:07 +0000 |
---|---|---|
committer | Eelco Dolstra <e.dolstra@tudelft.nl> | 2007-10-29 10:03:07 +0000 |
commit | 42d80d11705579dbb1e8b9029e2beaa1e86baf91 (patch) | |
tree | f91b5c63d642823f0951a393e04660b1014f1798 | |
parent | d91cd305634bfe0de200cb0b062a56349249d26e (diff) | |
download | guix-42d80d11705579dbb1e8b9029e2beaa1e86baf91.tar.gz |
* On FreeBSD, sys/mount.h needs sys/param.h.
-rw-r--r-- | configure.ac | 9 | ||||
-rw-r--r-- | src/libstore/build.cc | 6 |
2 files changed, 12 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index 5d8a719133..afffe70592 100644 --- a/configure.ac +++ b/configure.ac @@ -101,12 +101,17 @@ AC_LANG_POP(C++) # Check for chroot support (requires chroot() and bind mounts). AC_CHECK_FUNCS([chroot]) -AC_CHECK_HEADERS([sys/mount.h]) +AC_CHECK_HEADERS([sys/param.h], [], [], []) +AC_CHECK_HEADERS([sys/mount.h], [], [], +[#ifdef HAVE_SYS_PARAM_H +# include <sys/param.h> +# endif +]) # Check for <locale> AC_LANG_PUSH(C++) -AC_CHECK_HEADERS([locale]) +AC_CHECK_HEADERS([locale], [], [], []) AC_LANG_POP(C++) diff --git a/src/libstore/build.cc b/src/libstore/build.cc index 533883dc52..36e3b5e1dd 100644 --- a/src/libstore/build.cc +++ b/src/libstore/build.cc @@ -24,13 +24,17 @@ #include <pwd.h> #include <grp.h> + +/* Includes required for chroot support. */ #include "config.h" +#if HAVE_SYS_PARAM_H +#include <sys/param.h> +#endif #if HAVE_SYS_MOUNT_H #include <sys/mount.h> #endif - #define CHROOT_ENABLED HAVE_CHROOT && HAVE_SYS_MOUNT_H && defined(MS_BIND) |