On 9 December 2014 at 18:17, Bill Fischofer <[email protected]> wrote: > I suggest we turn on that by default. It's the one way to ensure that the > issues will get fixed. Is this a stop-on-first-error situation or can we > have it carry on so we get a complete list of what the c99 issues are? Just specifying -std=c99 to gcc will not actually limit it to using Standard C only, GCC is rather fond of its extensions and won't give up on them easily. Perhaps we should see what happens when adding "-ansi". To check for complete compliance, add "-pedantic" (this will break compilation as e.g. linux-generic relies in a lot of GCC extensions, possibly already -ansi will break compilation though). https://gcc.gnu.org/onlinedocs/gcc-4.7.0/gcc/C-Dialect-Options.html
> > On Tue, Dec 9, 2014 at 11:02 AM, Mike Holmes <[email protected]> wrote: >> >> This might also be the right time to adhere to the use of only C99 in >> linux-generics implementation ? >> >> CFLAGS=-std=c99 ./configure >> make >> >> Throws up other issues, the first is in packet_io >> >> mike@fedora1:~/git/odp$ make >> Making all in platform >> make[1]: Entering directory '/home/mike/git/odp/platform' >> Making all in linux-generic >> make[2]: Entering directory '/home/mike/git/odp/platform/linux-generic' >> CC odp_packet_io.lo >> odp_packet_io.c: In function 'odp_pktio_set_mtu': >> odp_packet_io.c:512:35: error: 'caddr_t' undeclared (first use in this >> function) >> ret = ioctl(sockfd, SIOCSIFMTU, (caddr_t)&ifr); >> ^ >> odp_packet_io.c:512:35: note: each undeclared identifier is reported only >> once for each function it appears in >> Makefile:560: recipe for target 'odp_packet_io.lo' failed >> >> >> >> Mike >> >> On 9 December 2014 at 11:48, Robbie King (robking) <[email protected]> >> wrote: >>> >>> After cloning tip just now, I found that I couldn’t build the fresh >>> >>> workspace due to having GCC 4.6.3 (the C11 changes to the atomics >>> >>> bumps minimum GCC up to 4.8 as best I can tell). I’m not very familiar >>> >>> with what “./configure” can and can’t do, but it seems we should verify >>> >>> the compiler supports these constructs and fail during the configure >>> >>> phase (as opposed to build time). >>> >>> >>> >>> Thanks, >>> >>> Robbie >>> >>> >>> _______________________________________________ >>> lng-odp mailing list >>> [email protected] >>> http://lists.linaro.org/mailman/listinfo/lng-odp >>> >> >> >> >> -- >> Mike Holmes >> Linaro Sr Technical Manager >> LNG - ODP >> >> _______________________________________________ >> lng-odp mailing list >> [email protected] >> http://lists.linaro.org/mailman/listinfo/lng-odp >> > > > _______________________________________________ > lng-odp mailing list > [email protected] > http://lists.linaro.org/mailman/listinfo/lng-odp > _______________________________________________ lng-odp mailing list [email protected] http://lists.linaro.org/mailman/listinfo/lng-odp
