+dnl --------------------- check for Extended Attributes support
+neta_cv_eas="files"
+neta_cv_eas_sys_found=no
+neta_cv_eas_sys_not_found=no
+
+AC_CHECK_HEADERS(sys/attributes.h attr/xattr.h sys/xattr.h sys/extattr.h sys/uio.h sys/ea.h)
+
+case "$this_os" in
+
+ *osf*)
+ AC_SEARCH_LIBS(getproplist, [proplist])
+ AC_CHECK_FUNCS([getproplist fgetproplist setproplist fsetproplist],
+ [neta_cv_eas_sys_found=yes],
+ [neta_cv_eas_sys_not_found=yes])
+ AC_CHECK_FUNCS([delproplist fdelproplist add_proplist_entry get_proplist_entry],,
+ [neta_cv_eas_sys_not_found=yes])
+ AC_CHECK_FUNCS([sizeof_proplist_entry],,
+ [neta_cv_eas_sys_not_found=yes])
+ ;;
+
+ *solaris*)
+ AC_CHECK_FUNCS([attropen],
+ [neta_cv_eas_sys_found=yes],
+ [neta_cv_eas_sys_not_found=yes])
+ ;;
+
+ *)
+ AC_SEARCH_LIBS(getxattr, [attr])
+
+ if test "x$neta_cv_eas_sys_found" != "xyes" ; then
+ AC_CHECK_FUNCS([getxattr lgetxattr fgetxattr listxattr llistxattr],
+ [neta_cv_eas_sys_found=yes],
+ [neta_cv_eas_sys_not_found=yes])
+ AC_CHECK_FUNCS([flistxattr removexattr lremovexattr fremovexattr],,
+ [neta_cv_eas_sys_not_found=yes])
+ AC_CHECK_FUNCS([setxattr lsetxattr fsetxattr],,
+ [neta_cv_eas_sys_not_found=yes])
+ fi
+
+ if test "x$neta_cv_eas_sys_found" != "xyes" ; then
+ AC_CHECK_FUNCS([getea fgetea lgetea listea flistea llistea],
+ [neta_cv_eas_sys_found=yes],
+ [neta_cv_eas_sys_not_found=yes])
+ AC_CHECK_FUNCS([removeea fremoveea lremoveea setea fsetea lsetea],,
+ [neta_cv_eas_sys_not_found=yes])
+ fi
+
+ if test "x$neta_cv_eas_sys_found" != "xyes" ; then
+ AC_CHECK_FUNCS([attr_get attr_list attr_set attr_remove],,
+ [neta_cv_eas_sys_not_found=yes])
+ AC_CHECK_FUNCS([attr_getf attr_listf attr_setf attr_removef],,
+ [neta_cv_eas_sys_not_found=yes])
+ fi
+ ;;
+esac
+
+# Do xattr functions take additional options like on Darwin?
+if test x"$ac_cv_func_getxattr" = x"yes" ; then
+ AC_CACHE_CHECK([whether xattr interface takes additional options], smb_attr_cv_xattr_add_opt, [
+ old_LIBS=$LIBS
+ LIBS="$LIBS $ACL_LIBS"
+ AC_TRY_COMPILE([
+ #include <sys/types.h>
+ #if HAVE_ATTR_XATTR_H
+ #include <attr/xattr.h>
+ #elif HAVE_SYS_XATTR_H
+ #include <sys/xattr.h>
+ #endif
+ ],[
+ getxattr(0, 0, 0, 0, 0, 0);
+ ],
+ [smb_attr_cv_xattr_add_opt=yes],
+ [smb_attr_cv_xattr_add_opt=no;LIBS=$old_LIBS])
+ ])
+ if test x"$smb_attr_cv_xattr_add_opt" = x"yes"; then
+ AC_DEFINE(XATTR_ADD_OPT, 1, [xattr functions have additional options])
+ fi
+fi
+
+# Check if we have extattr
+case "$this_os" in
+ *freebsd4* | *dragonfly* )
+ AC_DEFINE(BROKEN_EXTATTR, 1, [Does extattr API work])
+ ;;
+ *)
+ AC_CHECK_FUNCS(extattr_delete_fd extattr_delete_file extattr_delete_link)
+ AC_CHECK_FUNCS(extattr_get_fd extattr_get_file extattr_get_link)
+ AC_CHECK_FUNCS(extattr_list_fd extattr_list_file extattr_list_link)
+ AC_CHECK_FUNCS(extattr_set_fd extattr_set_file extattr_set_link)
+ ;;
+esac
+
+if test "x$neta_cv_eas_sys_found" = "xyes" ; then
+ if test "x$neta_cv_eas_sys_not_found" != "xyes" ; then
+ neta_cv_eas="$neta_cv_eas | native"
+ fi
+fi
+
+dnl --------------------- Netatalk Webmin
+NETATALK_WEBMIN
+