We just got a copy of the Linux client for our Cisco VPN router at work, but I'm having trouble compiling it. The script it calls to compile the kernel module it needs has these lines: INCLUDES="-I. -I${KSRCDIR}/include" CFLAGS="-O2 -DCNI_LINUX_INTERFACE -D__KERNEL__ -DMODULE -D_LOOSE_KERNEL_NAMES -\ DHAVE_CONFIG_H" $CC $CFLAGS $INCLUDES -c linuxcniapi.c $CC $CFLAGS $INCLUDES -c interceptor.c $CC $CFLAGS $INCLUDES -c IPSecDrvOS_linux.c $LD -r -o cisco_ipsec linuxcniapi.o IPSecDrvOS_linux.o interceptor.o libdriver.\ so which trigger some #error text like this:
You should not include /usr/include/{linux,asm}/ header files directly for the compilation of kernel modules. ... To build kernel modules please do the following:
o Have the kernel sources installed
o Make sure that the symbolic link /lib/modules/`uname -r`/build exists and points to the matching kernel source directory
o Now copy /boot/vmlinuz.version.h to /lib/modules/`uname -r`/build/include/linux/version.h
o When compiling, make sure to use the following compiler option to use the correct include files:
-I/lib/modules/`uname -r`/build/include
instead of
-I/usr/include/linux
I'm not sure how to correct this, since the include when the script runs actually expands to /usr/src/linux/include and not /usr/include/linux. Can anyone offer a suggestion? -- =========================================================== Glenn Holmer (gholmer@ameritech.net) ----------------------------------------------------------- Performing music well is a matter of distorting the score to produce the desired illusion, namely the existence of the score in a pure state. ----------------------------------------------------------- -Shadow, 1975 ===========================================================