NetBSD-Bugs archive

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

toolchain/55061: tools/nbconfig build failed on Linux



>Number:         55061
>Category:       toolchain
>Synopsis:       tools/nbconfig build failed on Linux
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    toolchain-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Mar 09 21:25:00 +0000 2020
>Originator:     Hiroyuki Bessho
>Release:        NetBSD current as of 2020 Mar 9
>Organization:
	Genetec corp.
>Environment:
System: Linux binchodeb 4.9.0-11-amd64 #1 SMP Debian 4.9.189-3+deb9u2 (2019-11-11) x86_64 GNU/Linux
Architecture: x86_64
Machine: amd64
>Description:
	build.sh tools with current source tree fails on Linux (Debian 9.12) at tools/config as follows.

--------------------------------------------
#   compile  config/pack.lo
cc -O  -DMAKE_BOOTSTRAP -I/u1/w/nb2/current/src/../tools/include/compat -I/u1/w/nb2/current/src/tools/compat -DHAVE_NBTOOL_CONFIG_H=1 -D_FILE_OFFSET_BITS=64 -I/u1/w/nb2/current/src/tools/config/../../usr.bin/config -I. -I/u1/w/nb2/current/src/usr.bin/cksum -c -o pack.lo.o    /u1/w/nb2/current/src/tools/config/../../usr.bin/config/pack.c
mv -f pack.lo.o pack.lo
#   compile  config/scan.lo
cc -O  -DMAKE_BOOTSTRAP -I/u1/w/nb2/current/src/../tools/include/compat -I/u1/w/nb2/current/src/tools/compat -DHAVE_NBTOOL_CONFIG_H=1 -D_FILE_OFFSET_BITS=64 -I/u1/w/nb2/current/src/tools/config/../../usr.bin/config -I. -I/u1/w/nb2/current/src/usr.bin/cksum -c -o scan.lo.o  -Wno-stringop-truncation    scan.c
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l: In function 'yylex':
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l:93:30: error: '__nothing' undeclared (first use in this function)
 # define IDS_PRINT(s, st, x) __nothing
                              ^
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l:97:2: note: in expansion of macro 'IDS_PRINT'
  IDS_PRINT(s, st, ">")
  ^~~~~~~~~
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l:197:3: note: in expansion of macro 'IDS_ENTER'
   if (IDS_PARENT_DISABLED || !getcurifdef()) {
   ^~~~~~~~~
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l:93:30: note: each undeclared identifier is reported only once for each function it appears in
 # define IDS_PRINT(s, st, x) __nothing
                              ^
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l:97:2: note: in expansion of macro 'IDS_PRINT'
  IDS_PRINT(s, st, ">")
  ^~~~~~~~~
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l:197:3: note: in expansion of macro 'IDS_ENTER'
   if (IDS_PARENT_DISABLED || !getcurifdef()) {
   ^~~~~~~~~
/u1/w/nb2/current/src/tools/config/../../usr.bin/config/scan.l: At top level:
cc1: warning: unrecognized command line option '-Wno-stringop-truncation'

*** Failed target:  scan.lo
*** Failed command: cc -O -DMAKE_BOOTSTRAP -I/u1/w/nb2/current/src/../tools/include/compat -I/u1/w/nb2/current/src/tools/compat -DHAVE_NBTOOL_CONFIG_H=1 -D_FILE_OFFSET_BITS=64 -I/u1/w/nb2/current/src/tools/config/../../usr.bin/config -I. -I/u1/w/nb2/current/src/usr.bin/cksum -c -o scan.lo.o -Wno-stringop-truncation scan.c
*** Error code 1
------------------------------------------------
>How-To-Repeat:
	run build.sh tools on linux.
>Fix:
  we need __nothing defined in tools/compat/compat_defs.h

diff --git a/tools/compat/compat_defs.h b/tools/compat/compat_defs.h
index 2454c8e0766..93aa45161cf 100644
--- a/tools/compat/compat_defs.h
+++ b/tools/compat/compat_defs.h
@@ -232,6 +232,8 @@ struct group;
 #define __type_min(t) (__type_is_signed(t) ? __type_min_s(t) : __type_min_u(t))
 #undef __type_max
 #define __type_max(t) (__type_is_signed(t) ? __type_max_s(t) : __type_max_u(t))
+#undef __nothing
+#define __nothing	(/*LINTED*/(void)0)
 
 /* Dirent support. */
 



Home | Main Index | Thread Index | Old Index