]> arthur.barton.de Git - netatalk.git/blobdiff - configure.in
Make the --disable-admin-group configure option work.
[netatalk.git] / configure.in
index e8849945625d80c92355b8a95b331050ee1b35ea..e5dfae1a676976c7a098dafd03ec6a8b79a1dfd4 100644 (file)
@@ -1,4 +1,4 @@
-dnl $Id: configure.in,v 1.168.2.7 2003-11-20 17:21:00 bfernhomberg Exp $
+dnl $Id: configure.in,v 1.168.2.10 2003-12-15 07:03:16 srittau Exp $
 dnl configure.in for netatalk
 
 AC_INIT(bin/adv1tov2/adv1tov2.c)
@@ -116,7 +116,7 @@ dnl --------------------------------------------------------------------------
 
 AC_DEFINE(ADMIN_GRP, 1)
 
-AC_ARG_WITH(admin-group,
+AC_ARG_ENABLE(admin-group,
        [  --disable-admin-group   disable admin group],
         if test "$enableval" = "no"; then
                AC_DEFINE(ADMIN_GRP, 0)
@@ -478,9 +478,33 @@ if test x"$this_os" = "xirix"; then
 fi
 
 dnl ----- Linux specific -----
+ac_have_atalk_addr=no
 if test x"$this_os" = "xlinux"; then 
        AC_MSG_RESULT([ * Linux specific configuration])
 
+       dnl ----- kernel 2.6 changed struct at_addr to atalk_addr
+       AC_MSG_CHECKING([for struct atalk_addr])
+       AC_COMPILE_IFELSE([
+#include <sys/socket.h>
+#include <asm/types.h>
+#include <linux/atalk.h>
+
+int main() {
+       struct atalk_addr foo;
+
+       return 0;
+}
+       ], [
+               ac_have_atalk_addr=yes
+               AC_MSG_RESULT([yes])
+       ], [
+               AC_MSG_RESULT([no])
+       ])
+
+if test "x$ac_have_atalk_addr" = "xyes"; then
+       AC_DEFINE(HAVE_ATALK_ADDR, 1, [set if struct at_addr is called atalk_addr])
+fi
+
        dnl ----- check if we need the quotactl wrapper
        AC_CHECK_HEADERS(sys/quota.h linux/quota.h)
        AC_CHECK_FUNC(quotactl,,