Tue 19 May 2009 06:06:40 PM UTC, comment #2:
Here's a smaller test case:
$ cat test.make
all: foo.suffix1 foo.suffix2 prefix1.foo prefix2.foo
prefix1.% prefix2.%: %.original
@echo $@
%.suffix1 %.suffix2: %.original
@echo $@
.PHONY: foo.original
# Expected output
$ make -f test.make
foo.suffix1
prefix1.foo
# Actual output
$ ./make -f test.make
foo.suffix1
foo.suffix2
make: file.c:147: enter_file: Assertion `*name != '\0'' failed.
Aborted
|
Sat 16 May 2009 02:19:19 PM UTC, original submission:
I got the following assertion failure when building GNU libc with the current CVS version of make:
make[1]: Leaving directory `/work/nacl/2/googleclient/native_client/glibc-2.9/elf'
make: file.c:147: enter_file: Assertion `*name != '\0'' failed.
Program received signal SIGABRT, Aborted.
[Switching to Thread 0xf7e516b0 (LWP 21888)]
0xffffe410 in __kernel_vsyscall ()
(gdb) bt
#0 0xffffe410 in __kernel_vsyscall ()
#1 0xf7e96085 in raise () from /lib/tls/i686/cmov/libc.so.6
#2 0xf7e97a01 in abort () from /lib/tls/i686/cmov/libc.so.6
#3 0xf7e8f10e in __assert_fail () from /lib/tls/i686/cmov/libc.so.6
#4 0x0804eba2 in enter_file (name=0x807205f "") at file.c:147
#5 0x080532c7 in pattern_search (file=0x8219f78,
archive=<value optimized out>, depth=7, recursions=0) at implicit.c:933
#6 0x08053ab0 in try_implicit_rule (file=0x8219f78, depth=7) at implicit.c:47
#7 0x08060734 in update_file (file=0x8219f78, depth=6) at remake.c:454
#8 0x080610c7 in check_dep (file=0x8219f78, depth=6,
this_mtime=1332272353123500035, must_make_ptr=0xffb8c4e0) at remake.c:945
#9 0x0805fefa in update_file (file=0x81a8d90, depth=4) at remake.c:509
#10 0x080610c7 in check_dep (file=0x81a8d90, depth=4, this_mtime=1,
must_make_ptr=0xffb8c5d0) at remake.c:945
#11 0x0805fefa in update_file (file=0x81ade28, depth=2) at remake.c:509
#12 0x080610c7 in check_dep (file=0x81ade28, depth=2, this_mtime=1,
must_make_ptr=0xffb8c6c0) at remake.c:945
#13 0x0805fefa in update_file (file=0x807a440, depth=0) at remake.c:509
#14 0x0806155b in update_goal_chain (goals=0x81c4160) at remake.c:155
#15 0x08058f22 in main (argc=8, argv=0xffb8e144, envp=Cannot access memory at address 0x5588
) at main.c:2219
The problem is in this change:
http://cvs.savannah.gnu.org/viewvc/make/implicit.c?root=make&r1=1.64&r2=1.65
This assignment is using the wrong string:
new->name = strcache_add (p);
I'll attach a patch that fixes this.
|