From: Marc Dionne Date: Sat, 16 Aug 2008 20:43:13 +0000 (+0000) Subject: STABLE14-linux-2-6-27-20080816 X-Git-Tag: openafs-stable-1_4_8pre1~32 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=05ec17077aa6e13cba2637e9cbf79c1e54c0baf4;p=packages%2Fo%2Fopenafs.git STABLE14-linux-2-6-27-20080816 LICENSE IPL10 FIXES 111634 add support for 2.6.27, which removes asm/semaphore.h (cherry picked from commit d7a5619e5bd8241dd13611a4be37f04f3aa4ed27) --- diff --git a/acinclude.m4 b/acinclude.m4 index 1445a59fe..ccbde274e 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -608,6 +608,7 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*) LINUX_KMEM_CACHE_CREATE_TAKES_DTOR LINUX_CONFIG_H_EXISTS LINUX_COMPLETION_H_EXISTS + LINUX_SEMAPHORE_H_EXISTS LINUX_DEFINES_FOR_EACH_PROCESS LINUX_DEFINES_PREV_TASK LINUX_FS_STRUCT_SUPER_HAS_ALLOC_INODE diff --git a/src/afs/sysincludes.h b/src/afs/sysincludes.h index 09a87e066..07c5add2d 100644 --- a/src/afs/sysincludes.h +++ b/src/afs/sysincludes.h @@ -108,7 +108,11 @@ struct xfs_inode_info { #include #include #include +#if defined(LINUX_SEMAPHORE_H) +#include +#else #include +#endif #if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,16) #include #endif diff --git a/src/cf/linux-test4.m4 b/src/cf/linux-test4.m4 index 94280d72e..ed4ce9200 100644 --- a/src/cf/linux-test4.m4 +++ b/src/cf/linux-test4.m4 @@ -1032,3 +1032,16 @@ AC_DEFUN([LINUX_EXPORTS_PROC_ROOT_FS], [ AC_DEFINE([EXPORTED_PROC_ROOT_FS], 1, [define if proc_root_fs is exported]) fi]) +AC_DEFUN([LINUX_SEMAPHORE_H_EXISTS], [ + AC_MSG_CHECKING([for linux/semaphore.h existance]) + AC_CACHE_VAL([ac_cv_linux_semaphore_h_exists], [ + AC_TRY_KBUILD( +[#include ], +[return;], + ac_cv_linux_semaphore_h_exists=yes, + ac_cv_linux_semaphore_h_exists=no)]) + AC_MSG_RESULT($ac_cv_linux_semaphore_h_exists) + if test "x$ac_cv_linux_semaphore_h_exists" = "xyes"; then + AC_DEFINE([LINUX_SEMAPHORE_H], 1, [define if linux/semaphore.h exists]) + fi]) +