1 AC_INIT(fuse, 2.6.0-pre3)
4 AM_CONFIG_HEADER(include/config.h)
9 # compatibility for automake < 1.8
10 if test -z "$mkdir_p"; then
11 mkdir_p="../mkinstalldirs"
21 if test "$ac_env_CFLAGS_set" != set; then
22 CFLAGS="-Wall -W -g -O2"
24 CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=64 -D_REENTRANT -DFUSE_USE_VERSION=26"
26 AC_ARG_ENABLE(kernel-module,
27 [ --enable-kernel-module Compile kernel module ])
29 [ --enable-lib Compile with library ])
31 [ --enable-util Compile with util ])
32 AC_ARG_ENABLE(example,
33 [ --enable-example Compile with examples ])
35 [ --disable-mtab Disable and ignore usage of /etc/mtab ])
37 AC_ARG_WITH(pkgconfigdir,
38 [ --with-pkgconfigdir=DIR pkgconfig file in DIR @<:@LIBDIR/pkgconfig@:>@],
39 [pkgconfigdir=$withval],
40 [pkgconfigdir='${libdir}/pkgconfig'])
41 AC_SUBST(pkgconfigdir)
45 if test "$arch" = linux -a "$enable_kernel_module" != "no"; then
46 AC_CONFIG_SUBDIRS(kernel)
49 if test "$enable_lib" != "no"; then
50 subdirs2="$subdirs2 lib";
52 if test "$arch" = linux -a "$enable_util" != "no"; then
53 subdirs2="$subdirs2 util";
55 if test "$enable_example" != "no"; then
56 subdirs2="$subdirs2 example";
58 if test "$enable_mtab" = "no"; then
59 AC_DEFINE(IGNORE_MTAB, 1, [Don't update /etc/mtab])
61 AC_CHECK_FUNCS([fork setxattr fdatasync])
62 AC_CHECK_MEMBERS([struct stat.st_atim])
66 AC_SEARCH_LIBS(clock_gettime, [rt])
67 libfuse_libs="$libfuse_libs $LIBS"
69 AC_SUBST(libfuse_libs)
71 if test -z "$MOUNT_FUSE_PATH"; then
74 AC_SUBST(MOUNT_FUSE_PATH)
75 if test -z "$UDEV_RULES_PATH"; then
76 UDEV_RULES_PATH=/etc/udev/rules.d
78 AC_SUBST(UDEV_RULES_PATH)
82 AM_CONDITIONAL(LINUX, test "$arch" = linux)
83 AM_CONDITIONAL(BSD, test "$arch" = bsd)
85 AC_CHECK_HEADERS(selinux/selinux.h, AC_CHECK_LIB(selinux, getfilecon))
87 AC_CONFIG_FILES([fuse.pc Makefile lib/Makefile util/Makefile example/Makefile include/Makefile])