Re: .ONESHELL enhancement?
Eli Zaretskii <[email protected]>
| Newsgroups | gmane.comp.gnu.make.devel |
|---|---|
| Message-ID | <[email protected]> |
> Date: Tue, 22 Sep 2009 12:29:51 -0400 > From: David Boyce <[email protected]> > > I have an interest in seeing the .ONESHELL special target enhancement > implemented, as recommended by POSIX (see the RATIONALE section within > http://www.opengroup.org/onlinepubs/009695399/). So I have a few > questions for the GNU make gatekeepers: I'm not the GNU Make maintainer, just one of the apprentices, so please wait for Paul to give you the definitive answer. > - This _feels_ like a pretty easy feature to add; though I don't know > the sources well, it appears that the "recipe" is contained within > file->cmds->commands in a newline-separated sequence of commands. > AFAICT it seems like a simple matter of splitting this on newlines and > replacing them with " && ", which is supported by both POSIX and > Windows shells. "&&" works on Windows only with cmd.exe (and probably also 4nt and friends), but not for command.com. The latter cannot support multiple commands on a single command line, so we will need to punt. And for the DOS (a.k.a. DJGPP) port, you will need to use ";" instead, since the `system' function in DJGPP enhances the system shell with several features, including this one.