On Tue, 2011-05-03 at 13:00 -0400, David Boyce wrote: > > The other thing I was thinking is that this feature might want to be > > enabled via a command-line argument. All the complex makefiles > > generated by automake, etc. for example cannot take advantage of this if > > you have to modify every makefile to add the special target. > > Hmm, it feels like you've reversed position since last year? When I > submitted the patch for .ONESHELL it included a new "--one-shell" flag > and you rejected the flag part saying you didn't want make to "end up > like GNU tar" in the sense of having an overwhelming number of > options.
Heh. Consistency is for suckers :-). However, I still feel that .ONESHELL is not something you can always just set on the command line and have things work just as before. Although _sometimes_ that's true, other times recipes are written in a particular way that can cause problems if .ONESHELL was set. And certainly if you write your makefile assuming .ONESHELL then anyone who runs make _without_ setting it will not be happy... the build will absolutely fail. For these reasons I'm less happy about having the user add it via the command line. To me .ONESHELL is a feature that the makefile AUTHOR chooses for her makefile, not (generally) something that the makefile USER would select (although certainly for some well-formed makefiles you can turn it on and off with no difference in behavior). For this SYNC feature, it will not make any difference whatsoever whether the person invoking the command uses it or not. In fact, in a way it's MORE appropriate for the command line, to allow the user to choose whether or not to use it (just like -j itself); it seems like forcing this to always be on by setting a pseudo target is somewhat antisocial; now if people want to avoid this behavior they have to edit the makefiles. In that way, SYNC is a feature that the makefile USER selects, or not, and not something the makefile AUTHOR would choose. Does that make sense? > That was when you came up with the --eval option, which I found > brilliant BTW. So I guess the first-order answer to your point would > be "there is a way to enable this at the command line and you invented > it": --eval=.PARALLELSYNC:". However, I personally like command-line > options and if you want a first-class flag you'll get no argument > here. Except, I don't remember if --eval is passed down to sub-makes? The mind goes first... -- ------------------------------------------------------------------------------- Paul D. Smith <psm...@gnu.org> Find some GNU make tips at: http://www.gnu.org http://make.mad-scientist.net "Please remain calm...I may be mad, but I am a professional." --Mad Scientist _______________________________________________ Bug-make mailing list Bug-make@gnu.org https://lists.gnu.org/mailman/listinfo/bug-make