]> git.ipfire.org Git - thirdparty/make.git/commit
[SV 54233] Preserve higher command_state values on also_make targets.
authorPaul Smith <psmith@gnu.org>
Sat, 4 Aug 2018 23:07:59 +0000 (19:07 -0400)
committerPaul Smith <psmith@gnu.org>
Sat, 4 Aug 2018 23:07:59 +0000 (19:07 -0400)
commit05769ca009e630c1989f29ca8cb9d0ec4cf2a8d8
tree930594c7ab5747b3efc2060214d498216bd21547
parente2234bc1abe13bf3e3c4eb003b19e4d3cce188f3
[SV 54233] Preserve higher command_state values on also_make targets.

If multiple pattern rules have the same pattern as also-make targets
and we attempt to run them at the same time, we might downgrade the
command state from 'running' to 'deps_running'; this will prevent
that also_make from being considered complete causing make to wait
forever for it to finish.

Ensure that set_command_state never downgrades the state of a target.

* src/file.c (set_command_state): Don't downgrade command_state.
* src/filedef.h (struct file): Document the order prerequisite.
* test/scripts/features/patternrules: Test the behavior.
src/file.c
src/filedef.h
tests/scripts/features/patternrules