Under the redhat 7.0 ,when I compile a kernel module,I failed with the following messages:
gcc -O2 -Wall -pipe -DMODULE -D__KERNEL__ -I/usr/src/linux/include -Wstrict-prototypes -fomit-frame-pointer -fno-strength-reduce -c clm_dspdrv.c -o clm_dspdrv.o
In file included from /usr/include/linux/fs.h:288,
from /usr/include/linux/capability.h:18,
from /usr/include/linux/binfmts.h:6,
from /usr/include/linux/sched.h:10,
from /usr/include/linux/vmalloc.h:5,
from /usr/include/asm/io.h:109,
from clm_dspdrv.c:16:
/usr/include/linux/ncp_fs_i.h:27: two or more data types in declaration of `type name'
/usr/include/linux/ncp_fs_i.h:27: warning: no semicolon at end of struct or union
/usr/include/linux/ncp_fs_i.h:27: parse error before `['
In file included from /usr/include/linux/capability.h:18,
from /usr/include/linux/binfmts.h:6,
from /usr/include/linux/sched.h:10,
from /usr/include/linux/vmalloc.h:5,
from /usr/include/asm/io.h:109,
from clm_dspdrv.c:16:
/usr/include/linux/fs.h:443: field `ncpfs_i' has incomplete type
/usr/include/linux/fs.h:448: Internal error: Segmentation fault.
Please submit a full bug report.
See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.
{standard input}: Assembler messages:
{standard input}:8: Warning: Ignoring changed section attributes for .modinfo
make: *** [clm_dspdrv.o] Error 2
==================================
Posted via http://nodevice.com
Linux Programmer's Site