cvs build problem with 2.95

Baurjan Ismagulov ibr@ata.cs.hun.edu.tr
Sat Apr 17 14:35:00 GMT 2004


Hello,

I'm trying to build the latest cvs with gcc 2.95 on a Debian woody/sid
system. Compilation of tcl/generic/tclPipe.c fails at the line 281 with
an error of "storage size of `waitStatus' isn't known". The variable is
declared as "WAIT_STATUS_TYPE waitStatus", which expands to "union
wait". NO_SYS_WAIT_H is set, and sys/wait.h doesn't get included from
tcl/unix/tclUnixPort.h.

configure invoked from make in one of subdirectories says "checking for
sys/wait.h... no". An excerpt from tcl/unix/config.log is given below. I
am not sure why gcc -E should return a non-zero exit status in case of
warnings. Besides, I've tried to reproduce the problem by preprocessing
the sample from config.log with a confdefs.h from libiberty/config.log;
the sample compiled without problems and gcc -E returned 0.

So, the questions:

1. How should I correct this problem? I want to compile the latest cvs.

2. Where is the correct confdefs.h? I want to be able to reproduce
   configure tests.

Thanks in advance,
Baurjan.

Here is the excerpt from tcl/unix/config.log:

configure:2578: checking for sys/wait.h
configure:2588: gcc-2.95 -E  conftest.c >/dev/null 2>conftest.out
In file included from /usr/include/asm/sigcontext.h:4,
                 from /usr/include/bits/sigcontext.h:28,
                 from /usr/include/signal.h:326,
                 from /usr/include/sys/wait.h:30,
                 from configure:2584:
/usr/include/linux/compiler.h:17: warning: `__attribute_used__' redefined
/usr/include/sys/cdefs.h:195: warning: this is the location of the previous definition
configure: failed program was:
#line 2583 "configure"
#include "confdefs.h"
#include <sys/wait.h>

I don't see why this should fail. cpp-2.95(1) doesn't say anything about
the exit status. gcc-2.95(1) states that it should return 0 unless there
are errors or -Werror is given and there are warnings.

And here is the output from make:

gcc-2.95 -c -g -O2 -Wall -Wconversion -Wno-implicit-int -fPIC -I../../../gdb-20040415.orig/tcl/unix/../generic -I../../../gdb-20040415.orig/tcl/unix -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1 -D_LARGEFILE64_SOURCE=1 -DTCL_WIDE_INT_TYPE=long\ long -DHAVE_STRUCT_STAT64=1 -DHAVE_TYPE_OFF64_T=1 -DHAVE_GETCWD=1 -DHAVE_OPENDIR=1 -DHAVE_STRSTR=1 -DHAVE_STRTOL=1 -DHAVE_STRTOLL=1 -DHAVE_STRTOULL=1 -DHAVE_TMPNAM=1 -DHAVE_WAITPID=1 -DNO_SYS_WAIT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_PARAM_H=1 -DUSE_TERMIOS=1 -DHAVE_SYS_TIME_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_TM_ZONE=1 -DHAVE_GMTIME_R=1 -DHAVE_LOCALTIME_R=1 -DHAVE_TM_GMTOFF=1 -DHAVE_TIMEZONE_VAR=1 -DHAVE_ST_BLKSIZE=1 -DSTDC_HEADERS=1 -DHAVE_SIGNED_CHAR=1 -DHAVE_LANGINFO=1 -DSTATIC_BUILD=1 -DPEEK_XCLOSEIM=1 -DHAVE_SYS_IOCTL_H=1         -DTCL_SHLIB_EXT=\".so\" ../../../gdb-20040415.orig/tcl/unix/../generic/tclPipe.c
In file included from /usr/include/asm/sigcontext.h:4,
                 from /usr/include/bits/sigcontext.h:28,
                 from /usr/include/signal.h:326,
                 from ../../../gdb-20040415.orig/tcl/unix/../generic/../unix/tclUnixPort.h:45,
                 from ../../../gdb-20040415.orig/tcl/unix/../generic/tclPort.h:27,
                 from ../../../gdb-20040415.orig/tcl/unix/../generic/tclPipe.c:17:
/usr/include/linux/compiler.h:17: warning: `__attribute_used__' redefined
/usr/include/sys/cdefs.h:195: warning: this is the location of the previous definition
../../../gdb-20040415.orig/tcl/unix/../generic/tclPipe.c: In function `TclCleanupChildren':
../../../gdb-20040415.orig/tcl/unix/../generic/tclPipe.c:281: storage size of `waitStatus' isn't known
../../../gdb-20040415.orig/tcl/unix/../generic/tclPipe.c:281: warning: unused variable `waitStatus'
make[2]: *** [tclPipe.o] Fehler 1
make[2]: Leaving directory `/mnt/hda5/ibr/src/gdb-20040415-295/tcl/unix'
make[1]: *** [all] Fehler 2



More information about the Gdb mailing list