[Clfs-support] Diffutils 3.6 Fails to Build for PowerPC in Chapter 6

Gunnersky2002 at gunnerhooper.tk Gunnersky2002 at gunnerhooper.tk
Mon Nov 6 10:41:25 PST 2017


I'm currently building CLFS Systemd for PowerPC 32 Bit on my x86_64 
machine with Linux from Scratch installed. Everything succeeded until I 
attempted to build Diffutils 3.6 in Chapter 6, which gave me this error:

In file included from ./getopt.h:85:0,
                  from xstrtol.h:22,
                  from xstrtol.c:31:
./config.h:2070:25: warning: 'struct rpl_option' declared inside 
parameter list will not be visible outside of this definition or declaration
  #define __GETOPT_PREFIX rpl_
                          ^
./getopt-pfx-core.h:38:44: note: in expansion of macro '__GETOPT_PREFIX'
  #  define __GETOPT_ID(y) __GETOPT_XCONCAT (__GETOPT_PREFIX, y)
                                             ^~~~~~~~~~~~~~~
   CC       xstrtol-error.o
In file included from ./getopt.h:85:0,
                  from xstrtol.h:22,
                  from xstrtol-error.c:20:
./config.h:2070:25: warning: 'struct rpl_option' declared inside 
parameter list will not be visible outside of this definition or declaration
  #define __GETOPT_PREFIX rpl_
                          ^
./getopt-pfx-core.h:38:44: note: in expansion of macro '__GETOPT_PREFIX'
  #  define __GETOPT_ID(y) __GETOPT_XCONCAT (__GETOPT_PREFIX, y)
                                             ^~~~~~~~~~~~~~~
In file included from ./getopt.h:85:0,
                  from xstrtol.h:22,
                  from xstrtol.c:31,
                  from xstrtoul.c:6:
./config.h:2070:25: warning: 'struct rpl_option' declared inside 
parameter list will not be visible outside of this definition or declaration
  #define __GETOPT_PREFIX rpl_
                          ^
./getopt-pfx-core.h:38:44: note: in expansion of macro '__GETOPT_PREFIX'
  #  define __GETOPT_ID(y) __GETOPT_XCONCAT (__GETOPT_PREFIX, y)
                                             ^~~~~~~~~~~~~~~
./config.h:2070:25: warning: 'struct rpl_option' declared inside 
parameter list will not be visible outside of this definition or declaration
  #define __GETOPT_PREFIX rpl_
                          ^
./getopt-pfx-core.h:38:44: note: in expansion of macro '__GETOPT_PREFIX'
  #  define __GETOPT_ID(y) __GETOPT_XCONCAT (__GETOPT_PREFIX, y)
                                             ^~~~~~~~~~~~~~~
xstrtol-error.c: In function 'xstrtol_error':
xstrtol-error.c:84:26: error: invalid use of undefined type 'struct 
rpl_option'
      option = long_options[opt_idx].name;
                           ^
xstrtol-error.c:84:26: error: dereferencing pointer to incomplete type 
'const struct rpl_option'
In file included from ./getopt.h:85:0,
                  from xstrtol.h:22,
                  from xstrtol-error.c:20:
xstrtol-error.c: At top level:
./config.h:2070:25: warning: 'struct rpl_option' declared inside 
parameter list will not be visible outside of this definition or declaration
  #define __GETOPT_PREFIX rpl_
                          ^
./getopt-pfx-core.h:38:44: note: in expansion of macro '__GETOPT_PREFIX'
  #  define __GETOPT_ID(y) __GETOPT_XCONCAT (__GETOPT_PREFIX, y)
                                             ^~~~~~~~~~~~~~~
xstrtol-error.c:92:1: error: conflicting types for 'xstrtol_fatal'
  xstrtol_fatal (enum strtol_error err,
  ^~~~~~~~~~~~~
In file included from xstrtol-error.c:20:0:
xstrtol.h:69:16: note: previous declaration of 'xstrtol_fatal' was here
  _Noreturn void xstrtol_fatal (enum strtol_error,
                 ^~~~~~~~~~~~~
xstrtol-error.c: In function 'xstrtol_fatal':
xstrtol-error.c:96:35: warning: passing argument 4 of 'xstrtol_error' 
from incompatible pointer type [-Wincompatible-pointer-types]
    xstrtol_error (err, opt_idx, c, long_options, arg, exit_failure);
                                    ^~~~~~~~~~~~
xstrtol-error.c:47:1: note: expected 'const struct rpl_option *' but 
argument is of type 'const struct rpl_option *'
  xstrtol_error (enum strtol_error err,
  ^~~~~~~~~~~~~
make[2]: *** [Makefile:1822: xstrtol-error.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory '/mnt/clfs/sources/diffutils-3.6/lib'
make[1]: *** [Makefile:1577: all] Error 2
make[1]: Leaving directory '/mnt/clfs/sources/diffutils-3.6/lib'
make: *** [Makefile:1337: all-recursive] Error 1

I'm building CLFS on my x86_64 Linux from Scratch 20170713-systemd 
installation. The book I'm using for CLFS is GIT-20170803-PowerPC. I 
decided to build Linux Headers 4.13.11, Binutils 2.29.1, Glibc 2.26, and 
GCC 7.2.0 for the cross tools.

Any help will be appreciated.

Thanks.



More information about the Clfs-support mailing list