diff options
author | Paul Smith <psmith@gnu.org> | 2023-02-18 16:08:51 -0500 |
---|---|---|
committer | Paul Smith <psmith@gnu.org> | 2023-02-19 01:25:57 -0500 |
commit | 2449ef3c88e6b1369137681c3a7370d777c332c1 (patch) | |
tree | 2c6a333fcf24eeab3733873ca46abf8b606a07c2 /src/implicit.c | |
parent | fbf8c940e529934df53fb70d3f7b5f224cd77597 (diff) | |
download | make-git-2449ef3c88e6b1369137681c3a7370d777c332c1.tar.gz |
Clean up depth handling in debug output
The indentation shown in debug output was misleading. Increment the
depth when we are working on a prerequisite, not for the current
target.
* src/remake.c (check_dep): Increment depth only on recursion.
(update_file_1): Ditto. Don't show "Finished..." if prereqs are
still running.
* src/implicit.c (pattern_search): Increment depth for the entire
search.
* tests/scripts/features/output-sync: Support debug output when run
by hand.
Diffstat (limited to 'src/implicit.c')
-rw-r--r-- | src/implicit.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/implicit.c b/src/implicit.c index 22e8276d..5fa30944 100644 --- a/src/implicit.c +++ b/src/implicit.c @@ -272,6 +272,8 @@ pattern_search (struct file *file, int archive, PATH_VAR (stem_str); /* @@ Need to get rid of stem, stemlen, etc. */ + ++depth; + #ifndef NO_ARCHIVES if (archive || ar_name (filename)) lastslash = 0; @@ -893,7 +895,7 @@ pattern_search (struct file *file, int archive, if (pattern_search (int_file, 0, - depth + 1, + depth, recursions + 1, allow_compat_rules)) { @@ -1139,6 +1141,8 @@ pattern_search (struct file *file, int archive, free (tryrules); free (deplist); + --depth; + if (rule) { DBS (DB_IMPLICIT, (_("Found implicit rule '%s' for '%s'.\n"), |