On 11/18/17, Paul Smith <[email protected]> wrote: > On Tue, 2017-11-07 at 13:43 -0500, Nick Bowler wrote: >> Is this behaviour intended? I noticed the manual says "make may take >> shortcuts that do not affect the results" but in this instance a change >> in results is definitely observed. > > Well, technically "command" is not a valid POSIX shell built-in > command, so relying on it in your makefile scripts without changing the > SHELL variable to /bin/bash (or some other shell that supports > "command") is incorrect.
"command" is a standard utility defined in POSIX. It is an ordinary utility (under the "Utilities" heading), rather than a special built-in. However "command" can only reasonably be implemented as a shell built-in because (among other things) the -V option has to know about currently- defined shell aliases. > However, even if you were to change SHELL to /bin/bash, it would still > not work properly :). > > I updated the built-in command list to contain "command". But what > should really happen is make should re-try the slow path if the fast > path fails with a "command not found" error... then we wouldn't have to > keep adding non-standard built-ins to these lists. Sounds great. Thanks, Nick _______________________________________________ Bug-make mailing list [email protected] https://lists.gnu.org/mailman/listinfo/bug-make
