]> arthur.barton.de Git - netatalk.git/blobdiff - include/atalk/ea.h
Support for using $u username variable in AFP volume definitions
[netatalk.git] / include / atalk / ea.h
index 2f884e6164017e6a932798658ca6c77e51a01ed4..fbbafafabef4169cc746e72dc3afa2aad2905a91 100644 (file)
 #include <config.h>
 #endif
 
+#if HAVE_ATTR_XATTR_H
+#include <attr/xattr.h>
+#elif HAVE_SYS_XATTR_H
+#include <sys/xattr.h>
+#endif
+
+#ifdef HAVE_SYS_EA_H
+#include <sys/ea.h>
+#endif
+
+#ifdef HAVE_SYS_EXTATTR_H
+#include <sys/extattr.h>
+#endif
+
+/* FIXME: are the ACL includes really neccessary here ? */
 #ifdef HAVE_SOLARIS_ACLS
 #include <sys/acl.h>
 #endif
+#ifdef HAVE_FREEBSD_SUNACL
+#include <sunacl.h>
+#endif
+
+#ifndef ENOATTR
+#define ENOATTR ENODATA
+#endif
 
 #include <atalk/vfs.h>
 
@@ -58,6 +80,7 @@ enum {
 /* Names for our Extended Attributes adouble data */
 #define AD_EA_META "org.netatalk.Metadata"
 #define AD_EA_RESO "org.netatalk.ResourceFork"
+#define NOT_NETATALK_EA(a) (strcmp((a), AD_EA_META) != 0) && (strcmp((a), AD_EA_RESO) != 0)
 
 /****************************************************************************************
  * Wrappers for native EA functions taken from Samba
@@ -75,6 +98,7 @@ int sys_setxattr (const char *path, const char *name, const void *value, size_t
 int sys_lsetxattr (const char *path, const char *name, const void *value, size_t size, int flags);
 int sys_fsetxattr (int filedes, const char *name, const void *value, size_t size, int flags);
 int sys_copyxattr (const char *src, const char *dst);
+int sys_getxattrfd(int fd, const char *uname, int oflag, ...);
 
 /****************************************************************************************
  * Stuff for our implementation of storing EAs in files in .AppleDouble dirs