diff options
author | Ron Yorston <rmy@pobox.com> | 2023-09-12 08:43:30 +0100 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2023-09-12 08:54:02 +0100 |
commit | faf0d38e40e099eebccac4013ab2692e545f612e (patch) | |
tree | 5fef3d804f124bd9e9bc36743227744086150e7e | |
parent | 00db3770b031c580feba47610169f077ac81dc4a (diff) | |
download | busybox-w32-faf0d38e40e099eebccac4013ab2692e545f612e.tar.gz busybox-w32-faf0d38e40e099eebccac4013ab2692e545f612e.tar.bz2 busybox-w32-faf0d38e40e099eebccac4013ab2692e545f612e.zip |
make: avoid more warnings
The tracking of progress introduced in commit fb4be267c (make: fixes
to warning messages) failed to account for runs with the '-t' or '-n'
options. Without this the following makefile:
dummy_target: dummy_rule
dummy_rule:
@:
issues the warning 'make: nothing to be done for dummy_target' when
run with '-t' or '-n' and no 'dummy_rule' file present.
(GitHub issue #354)
-rw-r--r-- | miscutils/make.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/miscutils/make.c b/miscutils/make.c index 08b9d806e..d554a5f7f 100644 --- a/miscutils/make.c +++ b/miscutils/make.c | |||
@@ -2165,7 +2165,6 @@ docmds(struct name *np, struct cmd *cp) | |||
2165 | target = np; | 2165 | target = np; |
2166 | status = system(cmd); | 2166 | status = system(cmd); |
2167 | target = NULL; | 2167 | target = NULL; |
2168 | estat = MAKE_DIDSOMETHING; | ||
2169 | // If this command was being run to create an include file | 2168 | // If this command was being run to create an include file |
2170 | // or bring it up-to-date errors should be ignored and a | 2169 | // or bring it up-to-date errors should be ignored and a |
2171 | // failure status returned. | 2170 | // failure status returned. |
@@ -2184,6 +2183,8 @@ docmds(struct name *np, struct cmd *cp) | |||
2184 | exit(status); | 2183 | exit(status); |
2185 | } | 2184 | } |
2186 | } | 2185 | } |
2186 | if (sdomake || dryrun || dotouch) | ||
2187 | estat = MAKE_DIDSOMETHING; | ||
2187 | free(command); | 2188 | free(command); |
2188 | } | 2189 | } |
2189 | makefile = NULL; | 2190 | makefile = NULL; |