rpm -q --scripts kernel-source postinstall script (through /bin/sh): cd /usr/src rm -f linux ln -snf linux-2.2.17 linux if [ 1 -eq 0 ] ; then <--- Is there some situations where 1=0 ??? cd /usr/include rm -f linux asm <--- /usr/include/linux and /usr/linux/asm can be directories, then this command doesn't work. ln -snf ../src/linux/include/linux linux ln -snf ../src/linux/include/asm asm fi
It's a %define -- it doesn't look like that in the source to the spec file. It's a packaging thing and isn't a bug, though it certainly looks strange. If they are directories, not links, then we didn't put them there and we shouldn't be removing them. Not a bug.
Thanks for the fast answer but 7.0 install kernel-headers-2.4.0-0.26.i386.rpm (Cf bug 20257) with linux and asm directories, so after update with kernel-source-2.2.17-14 we still have /usr/include/linux and /usr/include/asm for the 2.4 version...
Correct, that's exactly as it should be.
Sorry but I don't understand. why.. Could you explain me the use of 2.4 headers with a 2.2 kernel ? In bug 20257 it's said "Correct. If you want the module headers, install the 2.2.16 kernel-source package." So I have installed kernel-source package but I still have the /usr/include/linux of version 2.4 then when I try to compile my program thinks it's a 2.4 machine and it doen't work.
Building programs that can take advantage of 2.4 kernel features but can run on both kernels... Build with -I /lib/modules/$(uname -r)/build/include/ to get the right headers when you are building modules. You can have multiple kernels installed, so depending on /usr/include/{linux,asm} links is not sufficient.