[OpenAFS] AFS on linux 2.6.17/18

chas williams - CONTRACTOR chas@cmf.nrl.navy.mil
Wed, 02 Aug 2006 11:15:17 -0400


In message <44D0BCB1.60304@rl.ac.uk>,William John Murray writes:
>/lib/modules/`uname -r`/build/include/linux/utsrelease.h
>and this could fix the first problem, but is the second linked?
>Anyone got any clues?

this could be better written, but works.

Index: acinclude.m4
===================================================================
--- acinclude.m4	(revision 30)
+++ acinclude.m4	(revision 33)
@@ -121,6 +121,10 @@
 		     LINUX_KERNEL_PATH="/usr/src/linux"
 		   fi
 		 fi
+               if test -f "$LINUX_KERNEL_PATH/include/linux/utsrelease.h"; then
+		 linux_kvers=`fgrep UTS_RELEASE $LINUX_KERNEL_PATH/include/linux/utsrelease.h |awk 'BEGIN { FS="\"" } { print $[]2 }'|tail -n 1`
+		 LINUX_VERSION="$linux_kvers"
+               else
 		 if test -f "$LINUX_KERNEL_PATH/include/linux/version.h"; then
 		  linux_kvers=`fgrep UTS_RELEASE $LINUX_KERNEL_PATH/include/linux/version.h |awk 'BEGIN { FS="\"" } { print $[]2 }'|tail -n 1`
 		  if test "x$linux_kvers" = "x"; then
@@ -143,6 +147,7 @@
 		 else
                     enable_kernel_module="no"
                  fi
+               fi
 		 if test ! -f "$LINUX_KERNEL_PATH/include/linux/autoconf.h"; then
 		     enable_kernel_module="no"
 		 fi