On 06/07 07:03:31, Bill Fischofer wrote: > Sorry but a bit more testing means I need to rescind my review. This > patch seems to break clang compilation:
You're right. Which is a bit strange because this macro comes from autoconf-archive package. Will see if there can be a workaround. > bill@Ubuntu64:~/linaro/gcc7fix$ make > Making all in platform/linux-generic > make[1]: Entering directory '/home/bill/linaro/gcc7fix/platform/linux-generic' > CC _fdserver.lo > error: unknown warning option '-Wimplicit-fallthrough=0'; did you mean > '-Wimplicit-fallthrough'? [-Werror,-Wunknown-warning-option] > error: unknown warning option '-Wformat-truncation=0' > [-Werror,-Wunknown-warning-option] > error: unknown warning option '-Wformat-overflow=0'; did you mean > '-Wshift-overflow'? [-Werror,-Wunknown-warning-option] > Makefile:920: recipe for target '_fdserver.lo' failed > make[1]: *** [_fdserver.lo] Error 1 > make[1]: Leaving directory '/home/bill/linaro/gcc7fix/platform/linux-generic' > Makefile:492: recipe for target 'all-recursive' failed > make: *** [all-recursive] Error 1 > > The new options should only apply to GCC-based builds, ./configure > CC=clang should not use these extensions. > > On Tue, Jun 6, 2017 at 7:49 AM, Bill Fischofer > <[email protected]> wrote: > > Sorry, my bad. The gcc-7 was installed as gcc-7 and I forgot to > > specify CC=gcc-7 on ./configure. Correcting that allows everything to > > compile cleanly. > > > > For this series: > > > > Reviewed-and-tested-by: Bill Fischofer <[email protected]> > > > > On Mon, Jun 5, 2017 at 10:36 PM, Brian Brooks <[email protected]> wrote: > >> On 06/05 22:29:22, Bill Fischofer wrote: > >>> On Mon, Jun 5, 2017 at 9:32 PM, Brian Brooks <[email protected]> wrote: > >>> > On 06/05 18:40:02, Bill Fischofer wrote: > >>> >> After installing a copy of GCC 7, It looks like this patch is an > >>> >> incomplete fix. With this patch applied older GCC 6.3.0 continues to > >>> >> work fine, but GCC 7.0.1 generates the following errors: > >>> >> > >>> >> Making all in platform/linux-generic > >>> >> make[1]: Entering directory > >>> >> '/home/bill/linaro/gcc7fix/platform/linux-generic' > >>> >> CC pktio/ipc.lo > >>> >> pktio/ipc.c: In function ‘ipc_close’: > >>> >> pktio/ipc.c:698:33: error: ‘%s’ directive output may be truncated > >>> >> writing up to 255 bytes into a region of size 32 > >>> >> [-Werror=format-truncation=] > >>> >> snprintf(name, sizeof(name), "%s", dev); > >>> > > >>> > It looks like ./bootstrap might not have been run after applying the > >>> > patch? > >>> > >>> I just retried the build on a clean directory with ./bootstrap and > >>> ./configure and get the same errors. > >> > >> Can you post the bottom part of ./configure output? > >> > >> Here is what I see: > >> > >> cc: gcc > >> cc version: 7.1.1 > >> cppflags: > >> am_cppflags: > >> am_cxxflags: -std=c++11 > >> cflags: -g -O2 > >> am_cflags: -pthread -DHAVE_PCAP > >> -DIMPLEMENTATION_NAME=odp-linux -DODP_DEBUG_PRINT=0 -DODPH_DEBUG_PRINT=0 > >> -DODP_DEBUG=0 -W -Wall -Werror -Wstrict-prototypes -Wmissing-prototypes > >> -Wmissing-declarations -Wold-style-definition -Wpointer-arith -Wcast-align > >> -Wnested-externs -Wcast-qual -Wformat-nonliteral -Wformat-security -Wundef > >> -Wwrite-strings -std=c99 -Wimplicit-fallthrough=0 -Wformat-truncation=0 > >> -Wformat-overflow=0 -mcx16 > >> ldflags: > >> am_ldflags: -latomic -pthread -lrt > >> libs: -lrt -lcunit -lcrypto -lpcap > >> defs: -DHAVE_CONFIG_H > >> static libraries: yes > >> shared libraries: yes > >> ABI compatible: yes > >> cunit: yes > >> test_vald: yes > >> test_perf: yes > >> test_perf_proc: yes > >> test_cpp: yes > >> test_helper: yes > >> test_example: yes > >> user_guides: no
