linux-osi-module-proc-csdb-sprintf-bug-20050423
[openafs.git] / acinclude.m4
index 692f208..66de018 100644 (file)
@@ -14,9 +14,7 @@ AC_ARG_WITH(afs-sysname,
 [  --with-afs-sysname=sys    use sys for the afs sysname]
 )
 AC_ARG_ENABLE( obsolete,
-[  --enable-obsolete                   enable obsolete portions of AFS (mpp, ntp and package)],, enable_obsolete="no")
-AC_ARG_ENABLE( insecure,
-[  --enable-insecure                   enable insecure portions of AFS (ftpd, inetd, rcp, rlogind and rsh)],, enable_insecure="no")
+[  --enable-obsolete                   enable obsolete portions of AFS (mpp and package)],, enable_obsolete="no")
 AC_ARG_ENABLE( afsdb,
 [  --disable-afsdb                     disable AFSDB RR support],, enable_afsdb="yes")
 AC_ARG_ENABLE( pam,
@@ -115,7 +113,10 @@ case $system in
                 if test "x$with_linux_kernel_headers" != "x"; then
                   LINUX_KERNEL_PATH="$with_linux_kernel_headers"
                 else
-                  LINUX_KERNEL_PATH="/usr/src/linux-2.4"
+                  LINUX_KERNEL_PATH="/lib/modules/`uname -r`/build"
+                  if test ! -f "$LINUX_KERNEL_PATH/include/linux/version.h"; then
+                    LINUX_KERNEL_PATH="/usr/src/linux-2.4"
+                  fi
                   if test ! -f "$LINUX_KERNEL_PATH/include/linux/version.h"; then
                     LINUX_KERNEL_PATH="/usr/src/linux"
                   fi
@@ -454,7 +455,7 @@ else
                        AFS_SYSNAME="ia64_linuxXX"
                        ;;
                powerpc-*-linux*)
-                       AFS_SYSNAME="ppc_linuxXX"
+                       AFS_SYSNAME="`/bin/arch`_linuxXX"
                        ;;
                powerpc64-*-linux*)
                        AFS_SYSNAME="ppc64_linuxXX"
@@ -497,6 +498,10 @@ else
                        AFS_SYSNAME="rs_aix52"
                        enable_pam="no"
                        ;;
+               power*-ibm-aix5.3*)
+                       AFS_SYSNAME="rs_aix53"
+                       enable_pam="no"
+                       ;;
                x86_64-*-linux-gnu)
                        AFS_SYSNAME="amd64_linuxXX"
                        enable_pam="no"
@@ -554,20 +559,22 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*)
                 OPENAFS_GCC_SUPPORTS_PIPE
                 AC_SUBST(LINUX_GCC_KOPTS)
                 ifdef([OPENAFS_CONFIGURE_LIBAFS],
-                  [LINUX_BUILD_VNODE_FROM_INODE(src/config,afs)],
+                  [LINUX_BUILD_VNODE_FROM_INODE(src/config,src/afs)],
                   [LINUX_BUILD_VNODE_FROM_INODE(${srcdir}/src/config,src/afs/LINUX,${srcdir}/src/afs/LINUX)]
                 )
                 LINUX_COMPLETION_H_EXISTS
                 LINUX_DEFINES_FOR_EACH_PROCESS
                 LINUX_DEFINES_PREV_TASK
-                LINUX_EXPORTS_TASKLIST_LOCK
                 LINUX_FS_STRUCT_ADDRESS_SPACE_HAS_PAGE_LOCK
                 LINUX_FS_STRUCT_ADDRESS_SPACE_HAS_GFP_MASK
                 LINUX_FS_STRUCT_INODE_HAS_I_ALLOC_SEM
                 LINUX_FS_STRUCT_INODE_HAS_I_TRUNCATE_SEM
                 LINUX_FS_STRUCT_INODE_HAS_I_DIRTY_DATA_BUFFERS
                 LINUX_FS_STRUCT_INODE_HAS_I_DEVICES
+                LINUX_FS_STRUCT_INODE_HAS_I_SB_LIST
                 LINUX_FS_STRUCT_INODE_HAS_I_SECURITY
+                LINUX_FS_STRUCT_INODE_HAS_INOTIFY_LOCK
+                LINUX_FS_STRUCT_INODE_HAS_INOTIFY_SEM
                 LINUX_INODE_SETATTR_RETURN_TYPE
                 LINUX_WRITE_INODE_RETURN_TYPE
                 LINUX_IOP_NAMEIDATA
@@ -583,6 +590,9 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*)
                 LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_SIG
                 LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_SIGHAND
                 LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_SIGMASK_LOCK
+                LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_RLIM
+                LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_SIGNAL_RLIM
+                LINUX_SCHED_STRUCT_TASK_STRUCT_HAS_EXIT_STATE
                 LINUX_WHICH_MODULES
                  if test "x$ac_cv_linux_config_modversions" = "xno" -o $AFS_SYSKVERS -ge 26; then
                    AC_MSG_WARN([Cannot determine sys_call_table status. assuming it isn't exported])
@@ -633,9 +643,6 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*)
                 if test "x$ac_cv_linux_exports_sys_wait4" = "xyes" ; then
                  AC_DEFINE(EXPORTED_SYS_WAIT4, 1, [define if your linux kernel exports sys_wait4])
                 fi
-                if test "x$ac_cv_linux_exports_tasklist_lock" = "xyes" ; then
-                 AC_DEFINE(EXPORTED_TASKLIST_LOCK, 1, [define if your linux kernel exports tasklist_lock])
-                fi
                  if test "x$ac_cv_linux_exports_sys_call_table" = "xyes"; then
                   AC_DEFINE(EXPORTED_SYS_CALL_TABLE)
                  fi
@@ -681,9 +688,15 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*)
                 if test "x$ac_cv_linux_fs_struct_inode_has_i_security" = "xyes"; then 
                  AC_DEFINE(STRUCT_INODE_HAS_I_SECURITY, 1, [define if you struct inode has i_security])
                 fi
+                if test "x$ac_cv_linux_fs_struct_inode_has_i_sb_list" = "xyes"; then 
+                 AC_DEFINE(STRUCT_INODE_HAS_I_SB_LIST, 1, [define if you struct inode has i_sb_list])
+                fi
                 if test "x$ac_cv_linux_fs_struct_inode_has_i_dirty_data_buffers" = "xyes"; then 
                  AC_DEFINE(STRUCT_INODE_HAS_I_DIRTY_DATA_BUFFERS, 1, [define if your struct inode has data_buffers])
                 fi
+                if test "x$ac_cv_linux_fs_struct_inode_has_inotify_lock" = "xyes"; then 
+                 AC_DEFINE(STRUCT_INODE_HAS_INOTIFY_LOCK, 1, [define if your struct inode has inotify_lock])
+                fi
                 if test "x$ac_cv_linux_func_recalc_sigpending_takes_void" = "xyes"; then 
                  AC_DEFINE(RECALC_SIGPENDING_TAKES_VOID, 1, [define if your recalc_sigpending takes void])
                 fi
@@ -714,6 +727,15 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*)
                 if test "x$ac_cv_linux_sched_struct_task_struct_has_sig" = "xyes"; then 
                  AC_DEFINE(STRUCT_TASK_STRUCT_HAS_SIG, 1, [define if your struct task_struct has sig])
                 fi
+                if test "x$ac_cv_linux_sched_struct_task_struct_has_rlim" = "xyes"; then 
+                 AC_DEFINE(STRUCT_TASK_STRUCT_HAS_RLIM, 1, [define if your struct task_struct has rlim])
+                fi
+                if test "x$ac_cv_linux_sched_struct_task_struct_has_signal_rlim" = "xyes"; then 
+                 AC_DEFINE(STRUCT_TASK_STRUCT_HAS_SIGNAL_RLIM, 1, [define if your struct task_struct has signal->rlim])
+                fi
+                if test "x$ac_cv_linux_sched_struct_task_struct_has_exit_state" = "xyes"; then 
+                 AC_DEFINE(STRUCT_TASK_STRUCT_HAS_EXIT_STATE, 1, [define if your struct task_struct has exit_state])
+                fi
                 :
                fi
 esac
@@ -864,11 +886,6 @@ if test "$enable_obsolete" = "yes"; then
        WITH_OBSOLETE=YES
 fi
 
-WITH_INSECURE=NO
-if test "$enable_insecure" = "yes"; then
-       WITH_INSECURE=YES
-fi
-
 if test "x$with_bsd_kernel_headers" != "x"; then
        BSD_KERNEL_PATH="$with_bsd_kernel_headers"
 else
@@ -1049,7 +1066,6 @@ AC_SUBST(TOP_INCDIR)
 AC_SUBST(TOP_LIBDIR)
 AC_SUBST(DEST)
 AC_SUBST(WITH_OBSOLETE)
-AC_SUBST(WITH_INSECURE)
 AC_SUBST(DARWIN_INFOFILE)
 AC_SUBST(IRIX_BUILD_IP35)