Subject: Re: make -j and failure modes
To: Christos Zoulas <>
From: James Chacon <>
List: tech-toolchain
Date: 12/09/2003 19:52:33
On Wed, Dec 10, 2003 at 12:48:28AM +0000, Christos Zoulas wrote:
> In article <>,
> James Chacon <> wrote:

> >1. Have make scan the command for parens and if it finds them, exec via
> >   the compat methods.
> >2. Fix sh to deal with group'd commands and -e. Then provide nbsh as a host
> >   tool and tell make to use it.
> >3. Go through all the Makefile's and change (... && ...) into .... && ...
> >
> >(I'm leaning towards #2 but I need opinions/knowledge on whether sh is
> >doing the right thing or not.)
> >
> 4. fix make so that it outputs:
> 	cmd1 && cmd2
>    instead of cmd1\ncmd2\n

I don't follow..What would this fix? The problem is the sh not exiting on
error in all cases with -e.

> 5. use -B when using -j

By having make force this under the covers? Right now -j is documented 
specifically to disable this and expecting users to know to add -B in
is pretty much a no-go as it just won't happen and people will continue to
file PR's that make -j doesn't work with the main source tree.

The performance gains in passing the entire target commands to 1 sh are nice 
and this should work without jumping through lots of hoops. I think Ben's 
suggestion might be the best fix overall if folks actually beleive /bin/sh is
acting correctly WRT -e.