summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRadek Podgorny <radek@podgorny.cz>2014-03-20 18:35:03 +0100
committerRadek Podgorny <radek@podgorny.cz>2014-03-20 18:35:03 +0100
commitb9fca1afb7e1d243b1bef7bd2ca4b04632fb3fed (patch)
tree21646abed67f945b4437d0952903b26ad4013b00
parentbdcb13125fade1692344febea37e63be0618a234 (diff)
downloadunionfs-fuse-b9fca1afb7e1d243b1bef7bd2ca4b04632fb3fed.tar.gz
forgot to commit conf.h
-rw-r--r--src/conf.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/src/conf.h b/src/conf.h
new file mode 100644
index 0000000..37f1594
--- /dev/null
+++ b/src/conf.h
@@ -0,0 +1,39 @@
+/*
+ * License: BSD-style license
+ * Copyright: Bernd Schubert <bernd.schubert@fastmail.fm>
+ *
+ */
+
+#ifndef CONF_H_
+#define CONF_H_
+
+#ifdef _XOPEN_SOURCE
+
+// *at support, such as openat, utimensat, etc (see man 2 openat)
+#include <fcntl.h>
+#include <sys/stat.h>
+#if !defined (DISABLE_AT) && (_XOPEN_SOURCE >= 700 && _POSIX_C_SOURCE >= 200809L) \
+ && defined (AT_SYMLINK_NOFOLLOW)
+ #define UNIONFS_HAVE_AT
+#endif
+
+#endif // _XOPEN_SOURCE
+
+// xattr support
+#if !defined (DISABLE_XATTR)
+ #if defined (LIBC_XATTR)
+ #include <sys/xattr.h>
+ #elif defined (LIBATTR_XATTR)
+ #include <attr/xattr.h>
+ #else
+ #error // neither libc attr nor libattr xattr defined
+ #endif
+
+ #if defined (XATTR_CREATE) && defined (XATTR_REPLACE)
+ #define HAVE_XATTR
+ #endif
+#endif
+
+
+#endif // CONF_H_
+