Paul D. Smith <[EMAIL PROTECTED]> writes: > This sounds familiar to me: pls. send it. Thx.
Patch and test makefile are attached. -boris
diff -u -b -B --minimal make-cvs-orig/file.c make-cvs-patched/file.c --- make-cvs-orig/file.c 2004-05-16 19:19:57.000000000 -0500 +++ make-cvs-patched/file.c 2004-09-17 13:38:46.000000000 -0500 @@ -455,8 +455,9 @@ for (d = f->deps; d != 0; d = d->next) for (f2 = d->file; f2 != 0; f2 = f2->prev) { - /* Mark this file as phony and nonexistent. */ + /* Mark this file as phony nonexistent target. */ f2->phony = 1; + f2->is_target = 1; f2->last_mtime = NONEXISTENT_MTIME; f2->mtime_before_update = NONEXISTENT_MTIME; } diff -u -b -B --minimal make-cvs-orig/implicit.c make-cvs-patched/implicit.c --- make-cvs-orig/implicit.c 2004-01-07 21:17:08.000000000 -0600 +++ make-cvs-patched/implicit.c 2004-09-17 13:41:17.000000000 -0500 @@ -342,6 +342,8 @@ deps_found = 0; for (dep = rule->deps; dep != 0; dep = dep->next) { + struct file *f = 0; + /* If the dependency name has a %, substitute the stem. */ p = strchr (dep_name (dep), '%'); if (p != 0) @@ -396,7 +398,7 @@ directory (the one gotten by prepending FILENAME's directory), so it might actually exist. */ - if (lookup_file (p) != 0 + if (((f = lookup_file (p)) != 0 && f->is_target) || ((!dep->changed || check_lastslash) && file_exists_p (p))) { found_files_im[deps_found] = dep->ignore_mtime;
.PHONY: all all: case.1 case.2 case.3 a: void # 1 - existing file # %.1: void @false %.1: makefile @true # 2 - phony # %.2: void @false %.2: 2.phony @true .PHONY: 2.phony # 3 - implicit-phony # %.3: void @false %.3: 3.implicit-phony @true 3.implicit-phony:
signature.asc
Description: Digital signature
_______________________________________________ Bug-make mailing list [EMAIL PROTECTED] http://lists.gnu.org/mailman/listinfo/bug-make