delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1994/06/19/00:20:52

From: "Ian T. Zimmerman" <itz AT crl DOT com>
Subject: make ALL?
To: djgpp AT sun DOT soe DOT clarkson DOT edu (DJ Delorie)
Date: Sat, 18 Jun 1994 21:07:37 -0700 (PDT)

Hello again.

I'm just trying to use gmake for my first nontrivial project, and I have 
run into the following hurdle:

DOS-based make programs usually have a command line flag "full build" ie. 
execute all commands disregarding timestamps. This is used for instance 
when one changes compiler or linker flags. I use it quite often for 
switching between debug and release builds. Gmake doesn't have this flag (or 
if it does, it isn't documented). I assume that's because with U*x shells 
the same effect can easily be achieved by doing something like

ALL:
	touch $(SOURCES)
	$(MAKE)

ALAS, this won't work in DOS if the SOURCES list is moderately long, 
because of the justly infamous command-line limitation. Now I have tried 
to think of millions of ways around this, but there's always a catch. In 
particular I cannot use foreach because the expansion string for foreach 
can't contain a newline, and DOS can't take multiple commands on a single 
line.

If anyone can think of a solution (other than 'Get a real operating 
system, dude' or 'just touch the source files separately, one per line') 
I would be very grateful. Thanks!

Ian T Zimmerman            +-------------------------------------------+
P.O. Box 13445             I    With so many executioners available,   I
Berkeley, California 94712 I suicide is a really foolish thing to do.  I
USA                        +-------------------------------------------+


- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019