Config: RedHat 8.0 with ASOUND (ASOUND LAN 8139 chip) 10/100 ethernet (PCI).
Problem: I've tried in vain to compile the
fealnx.c driver that I got from redhat 8.0 kernel-source RPM. It yields a long list of compile errors - below is the first part of the output, including the command I'm using to build:
[root@localhost net]# gcc -DMODULE -D__KERNEL__ -Wall -Wstrict-prototypes -O6 -c fealnx.c
In file included from /usr/include/linux/fs.h:23,
from /usr/include/linux/capability.h:17,
from /usr/include/linux/binfmts.h:5,
from /usr/include/linux/sched.h:9,
from fealnx.c:73:
/usr/include/linux/string.h:8:2: warning: #warning Using kernel header in userland!
In file included from /usr/include/linux/sched.h:14,
from fealnx.c:73:
/usr/include/linux/timex.h:173: field `time' has incomplete type
In file included from /usr/include/linux/bitops.h:69,
from /usr/include/asm/system.h:7,
from /usr/include/linux/sched.h:16,
from fealnx.c:73:
/usr/include/asm/bitops.h:333:2: warning: #warning This includefile is not available on all architectures.
^P/usr/include/asm/bitops.h:334:2: warning: #warning Using kernel headers in userspace.
In file included from /usr/include/linux/signal.h:4,
from /usr/include/linux/sched.h:25,
from fealnx.c:73:
/usr/include/asm/signal.h:107: parse error before "sigset_t"
/usr/include/asm/signal.h:110: parse error before '}' token
In file included from /usr/include/linux/sched.h:81,
from fealnx.c:73:
/usr/include/linux/timer.h:45: parse error before "spinlock_t"
/usr/include/linux/timer.h:53: parse error before '}' token
/usr/include/linux/timer.h:67: parse error before "tvec_base_t"
/usr/include/linux/timer.h:101: parse error before "tvec_bases"
/usr/include/linux/timer.h: In function `init_timer':
/usr/include/linux/timer.h:105: dereferencing pointer to incomplete type
/usr/include/linux/timer.h:105: dereferencing pointer to incomplete type
/usr/include/linux/timer.h:106: dereferencing pointer to incomplete type
/usr/include/linux/timer.h: In function `timer_pending':
/usr/include/linux/timer.h:121: dereferencing pointer to incomplete type
Why parse errors in all these header files??? How can I get this NIC driver built?
I tried running
make to build the default Makefile in the /usr/src/.../drivers/net directory, but this yielded an error stating no such file/folder /Rules.make
Thanks in advance for any help!