* Kernel compiler error : flexible array member not at end of struct
@ 2003-11-04 5:41 Doug Kehn
2003-11-04 10:40 ` Chris Dearman
0 siblings, 1 reply; 2+ messages in thread
From: Doug Kehn @ 2003-11-04 5:41 UTC (permalink / raw)
To: linux-mips
I am receiving the following kernel compile error:
make[3]: Entering directory
`/usr/src/x/kernel/linux-2.4.21/fs/partitions'
mips-uclibc-gcc -D__KERNEL__
-I/usr/src/x/kernel/linux-2.4.21/include -Wall
-Wstrict-prototypes -Wno-trigraphs -O2
-fno-strict-aliasing -fno-common -fomit-frame-pointer
-I /usr/src/x/linux-2.4.21/include/asm/gcc -G 0
-mno-abicalls -fno-pic -pipe -mcpu=r5000 -mips2
-Wa,--trap -nostdinc -iwithprefix include
-DKBUILD_BASENAME=check -DEXPORT_SYMTAB -c check.c
In file included from
/usr/src/x/kernel/linux-2.4.21/include/linux/raid/md.h:50,
from check.c:21:
/usr/src/x/kernel/linux-2.4.21/include/linux/raid/md_p.h:157:
flexible array member not at end of struct
make[3]: *** [check.o] Error 1
I am using gcc version 2.96-mips3264-000710 (from
sdelinux-5.01-4eb.i386.rpm). The kernel is,
obviously, 2.4.21 (from linux-mips.org). uclibc is
version 0.9.21.
I have seen one or two other posting related to this
same error. However, I was unable to find any
suggested resoltions. Does anyone know of a solution
to this compile error?
Thanks...
doug
__________________________________
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Kernel compiler error : flexible array member not at end of struct
2003-11-04 5:41 Kernel compiler error : flexible array member not at end of struct Doug Kehn
@ 2003-11-04 10:40 ` Chris Dearman
0 siblings, 0 replies; 2+ messages in thread
From: Chris Dearman @ 2003-11-04 10:40 UTC (permalink / raw)
To: Doug Kehn; +Cc: linux-mips
[-- Attachment #1: Type: text/plain, Size: 753 bytes --]
Doug Kehn wrote:
> I am using gcc version 2.96-mips3264-000710 (from
> sdelinux-5.01-4eb.i386.rpm). The kernel is,
> obviously, 2.4.21 (from linux-mips.org). uclibc is
> version 0.9.21.
>
> I have seen one or two other posting related to this
> same error. However, I was unable to find any
> suggested resoltions. Does anyone know of a solution
> to this compile error?
There is an updated version of the compiler that handles zero-length
arrays in structures correctly. See
ftp://ftp.mips.com/pub/tools/software/sde-for-linux/
Alternatively you could apply the attached patch
Chris
--
Chris Dearman The Fruit Farm, Ely Road voice +44 1223 706206
MIPS Technologies (UK) Chittering, Cambs, CB5 9PH fax +44 1223 706250
[-- Attachment #2: patch --]
[-- Type: text/plain, Size: 475 bytes --]
Index: md_p.h
===================================================================
RCS file: linux-2.4.18/include/linux/raid/md_p.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- md_p.h 4 Mar 2002 11:13:33 -0000 1.1
+++ md_p.h 8 Nov 2002 13:09:02 -0000 1.2
@@ -151,10 +151,12 @@
*/
mdp_disk_t disks[MD_SB_DISKS];
+#if MD_SB_RESERVED_WORDS
/*
* Reserved
*/
__u32 reserved[MD_SB_RESERVED_WORDS];
+#endif
/*
* Active descriptor
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2003-11-04 10:41 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-11-04 5:41 Kernel compiler error : flexible array member not at end of struct Doug Kehn
2003-11-04 10:40 ` Chris Dearman
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox