like dhcpcd cc -D_BSD_SOURCE -O2 -pipe -pedantic -std=c99 -Wall -Wunused -Wimplicit -Wshadow -Wformat=2 -Wmissing-declarations -Wno-missing-prototypes -Wwrite-strings -Wbad-function-cast -Wnested-externs -Wcomment -Winline -Wchar-subscripts -Wcast-align -Wno-format-nonliteral -Wsequence-point -Wextra -Wdeclaration-after-statement -c interface.c In file included from /usr/include/linux/rtnetlink.h:5, from interface.c:33: /usr/include/linux/if_link.h:43: error: expected specifier-qualifier-list before
like dhcpcd cc -D_BSD_SOURCE -O2 -pipe -pedantic -std=c99 -Wall -Wunused -Wimplicit -Wshadow -Wformat=2 -Wmissing-declarations -Wno-missing-prototypes -Wwrite-strings -Wbad-function-cast -Wnested-externs -Wcomment -Winline -Wchar-subscripts -Wcast-align -Wno-format-nonliteral -Wsequence-point -Wextra -Wdeclaration-after-statement -c interface.c In file included from /usr/include/linux/rtnetlink.h:5, from interface.c:33: /usr/include/linux/if_link.h:43: error: expected specifier-qualifier-list before __u64 In file included from /usr/include/linux/rtnetlink.h:7, from interface.c:33: /usr/include/linux/neighbour.h:92: error: expected specifier-qualifier-list before __u64 make: *** [interface.o] Error 1 This error is generated because asm/types.h does not define __u64 if __STRICT_ANSI__ is defined by the std=c99 flag. Removal of this flag means we compile ok. This error is new to 2.6.19
Created attachment 104517 [details, diff] Fix u64 when using c99 u64 is defined by ISO C99, so this patch checks against the right define making dhcpcd work.
I'm a nice guy - filed upstream http://bugzilla.kernel.org/show_bug.cgi?id=7724
yeah that's wrong ... the purpose was to make sure u64 never makes it while strict ansi is defined i think your trouble lies with the fact that -std=c99 turns on strict ansi while -std=gnu99 does not vapier@G5[ppc] 0 ~ $ echo "" | cpp -dD | grep -i ansi vapier@G5[ppc] 0 ~ $ echo "" | cpp -dD -std=c99 | grep -i ansi #define __STRICT_ANSI__ 1 vapier@G5[ppc] 0 ~ $ echo "" | cpp -dD -std=gnu99 | grep -i ansi vapier@G5[ppc] 0 ~ $
we'll just take this to the upstream URL