coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

latest gcc.git vs latest coreutils.git


From: Jim Meyering
Subject: latest gcc.git vs latest coreutils.git
Date: Tue, 19 Dec 2017 21:25:25 -0800

I built the very latest gcc from git:

  gcc version 8.0.0 20171219 (experimental) (GCC)

Then used it to build latest coreutils.git configured with
--enable-gcc-warnings.  That shows that a few of gcc's new
warnings trigger in latest coreutils and gnulib.

I haven't looked at these enough yet to say whether to accommodate or
to suppress them:

-------------
make  all-recursive
make[1]: Entering directory '/home/j/w/co/cu'
Making all in po
make[2]: Entering directory '/home/j/w/co/cu/po'
make[2]: Nothing to be done for 'all'.
make[2]: Leaving directory '/home/j/w/co/cu/po'
Making all in .
make[2]: Entering directory '/home/j/w/co/cu'
  GEN      doc/constants.texi
  CC       lib/sig-handler.o
  CC       lib/nanosleep.o
  CC       lib/readutmp.o
  CC       src/who.o
  CC       src/chgrp.o
  CC       src/chown-core.o
  CC       src/chown.o
In file included from lib/sig-handler.c:3:
lib/sig-handler.h: In function 'get_handler':
lib/sig-handler.h:47:12: error: cast between incompatible function types from 
'void (* const)(int,  siginfo_t *, void *)' {aka 'void (* const)(int,  struct 
<anonymous> *, void *)'} to 'void (*)(int)' [-Werror=cast-function-type]
     return (sa_handler_t) a->sa_sigaction;
            ^
cc1: all warnings being treated as errors
make[2]: *** [Makefile;9609: lib/sig-handler.o] Error 1
In file included from lib/nanosleep.c:26:
lib/sig-handler.h: In function 'get_handler':
lib/sig-handler.h:47:12: error: cast between incompatible function types from 
'void (* const)(int,  siginfo_t *, void *)' {aka 'void (* const)(int,  struct 
<anonymous> *, void *)'} to 'void (*)(int)' [-Werror=cast-function-type]
     return (sa_handler_t) a->sa_sigaction;
            ^
cc1: all warnings being treated as errors
make[2]: *** [Makefile;9609: lib/nanosleep.o] Error 1
lib/readutmp.c: In function 'extract_trimmed_name':
lib/readutmp.c:50:47: error: argument to 'sizeof' in 'strncpy' call is the same 
expression as the source; did you mean to use the size of the destination? 
[-Werror=sizeof-pointer-memaccess]
   strncpy (trimmed_name, UT_USER (ut), sizeof (UT_USER (ut)));
                                               ^
cc1: all warnings being treated as errors
make[2]: *** [Makefile;9609: lib/readutmp.o] Error 1
In file included from src/chown.c:25:
src/chown-core.h:72:20: error: 'pure' attribute on function returning 'void' 
[-Werror=attributes]
 chopt_free (struct Chown_option *);
                    ^~~~~~~~~~~~
src/chown-core.h:72:20: error: 'const' attribute on function returning 'void' 
[-Werror=attributes]
src/chown-core.h:72:20: error: ignoring attribute 'const' because it conflicts 
with attribute 'pure' [-Werror=attributes]
cc1: all warnings being treated as errors
make[2]: *** [Makefile;9609: src/chown.o] Error 1
In file included from src/chgrp.c:26:
src/chown-core.h:72:20: error: 'pure' attribute on function returning 'void' 
[-Werror=attributes]
 chopt_free (struct Chown_option *);
                    ^~~~~~~~~~~~
src/chown-core.h:72:20: error: 'const' attribute on function returning 'void' 
[-Werror=attributes]
src/chown-core.h:72:20: error: ignoring attribute 'const' because it conflicts 
with attribute 'pure' [-Werror=attributes]
cc1: all warnings being treated as errors
make[2]: *** [Makefile;9609: src/chgrp.o] Error 1
In file included from src/chown-core.c:26:
src/chown-core.h:72:20: error: 'pure' attribute on function returning 'void' 
[-Werror=attributes]
 chopt_free (struct Chown_option *);
                    ^~~~~~~~~~~~
src/chown-core.h:72:20: error: 'const' attribute on function returning 'void' 
[-Werror=attributes]
src/chown-core.h:72:20: error: ignoring attribute 'const' because it conflicts 
with attribute 'pure' [-Werror=attributes]
cc1: all warnings being treated as errors
make[2]: *** [Makefile;9609: src/chown-core.o] Error 1
src/who.c: In function 'make_id_equals_comment':
src/who.c:96:19: error: argument to 'sizeof' in 'strncat' call is the same 
expression as the source; did you mean to use the size of the destination? 
[-Werror=sizeof-pointer-memaccess]
 # define UT_ID(U) ((U)->ut_id)
                   ^
src/who.c:453:46: note: in expansion of macro 'UT_ID'
   strncat (comment, UT_ID (utmp_ent), sizeof UT_ID (utmp_ent));
                                              ^~~~~
cc1: all warnings being treated as errors



reply via email to

[Prev in Thread] Current Thread [Next in Thread]