bug-make
[Top][All Lists]
Advanced

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

make/3.80 dumps core using '-t' with more than 1 target


From: Richard H. Broberg
Subject: make/3.80 dumps core using '-t' with more than 1 target
Date: Fri, 7 Mar 2003 13:40:26 -0500 (EST)

platform is sparc-sun-solaris/2.8
make built with gcc/3.2.2

here is the backtrace:

skunk :make-3.80 % gdb ./make /system/tmp/core
GNU gdb 5.3
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "sparc-sun-solaris2.8"...
Core was generated by `make -I/system/build/head/buildsvc/03030710.34/include 
VERSION=03030710.34 PACK'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /usr/lib/libkstat.so.1...done.
Loaded symbols for /usr/lib/libkstat.so.1
Reading symbols from /usr/lib/librt.so.1...done.
Loaded symbols for /usr/lib/librt.so.1
Reading symbols from /usr/lib/libnsl.so.1...done.
Loaded symbols for /usr/lib/libnsl.so.1
Reading symbols from /usr/lib/libsocket.so.1...done.
Loaded symbols for /usr/lib/libsocket.so.1
Reading symbols from /usr/lib/libc.so.1...done.
Loaded symbols for /usr/lib/libc.so.1
Reading symbols from /usr/lib/libaio.so.1...done.
Loaded symbols for /usr/lib/libaio.so.1
Reading symbols from /usr/lib/libdl.so.1...done.
Loaded symbols for /usr/lib/libdl.so.1
Reading symbols from /usr/lib/libmp.so.2...done.
Loaded symbols for /usr/lib/libmp.so.2
Reading symbols from /usr/platform/SUNW,Ultra-60/lib/libc_psr.so.1...done.
Loaded symbols for /usr/platform/SUNW,Ultra-60/lib/libc_psr.so.1
#0  0x00027e34 in notice_finished_file (file=0x73618) at remake.c:790
790               for (i = file->cmds->ncommand_lines; i > 0; --i)
(gdb) where
#0  0x00027e34 in notice_finished_file (file=0x73618) at remake.c:790
#1  0x00028658 in remake_file (file=0x73618) at remake.c:1061
#2  0x00027b78 in update_file_1 (file=0x73618, depth=3) at remake.c:690
#3  0x00026d34 in update_file (file=0x51c00, depth=2) at remake.c:310
#4  0x00027fe4 in check_dep (file=0x73618, depth=2, this_mtime=1, 
    must_make_ptr=0xffbed9a4) at remake.c:857
#5  0x000272c8 in update_file_1 (file=0x586b8, depth=1) at remake.c:463
#6  0x00026d34 in update_file (file=0x51c00, depth=0) at remake.c:310
#7  0x0002698c in update_goal_chain (goals=0x681a0, makefiles=0)
    at remake.c:157
#8  0x0002091c in main (argc=10, argv=0xffbee89c, envp=0x8) at main.c:1946
(gdb) 

----

the problem is that 'file->cmds' is NULL, on the second iteration through
this loop.

here is how I ran it:

make -t

here is my makefile:

------------------------------------------------------------
all:    a

a:
        echo $@

------------------------------------------------------------

the problem doesn't happen if I just do 'make a'; it has to
be a target which causes a dependency to be created.

(strictly speaking my stack trace above is from when I ran it on a
_real_ makefile, but I didn't recapture the output (it was the same)
after I created the much smaller test makefile and targets above)




reply via email to

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