[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #65917] --dry-run doesn't handle pattern rules with multiple target
|
From: |
Hannes Domani |
|
Subject: |
[bug #65917] --dry-run doesn't handle pattern rules with multiple targets correctly |
|
Date: |
Mon, 24 Jun 2024 14:32:28 -0400 (EDT) |
Follow-up Comment #1, bug #65917 (group make):
I've come up with this patch:
diff --git a/src/remake.c b/src/remake.c
index ee8971e7..9d33351f 100644
--- a/src/remake.c
+++ b/src/remake.c
@@ -1090,11 +1090,16 @@ notice_finished_file (struct file *file)
d->file->update_status = file->update_status;
if (ran && !d->file->phony)
- /* Fetch the new modification time.
- We do this instead of just invalidating the cached time
- so that a vpath_search can happen. Otherwise, it would
- never be done because the target is already updated. */
- f_mtime (d->file, 0);
+ {
+ if (just_print_flag)
+ d->file->last_mtime = NEW_MTIME;
+ else
+ /* Fetch the new modification time.
+ We do this instead of just invalidating the cached time
+ so that a vpath_search can happen. Otherwise, it would
+ never be done because the target is already updated. */
+ f_mtime (d->file, 0);
+ }
}
/* If the target was created by an implicit rule, and it was updated,
Not sure how correct it is, but so far it's working for me.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?65917>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/