Mail Archives: djgpp/1996/04/16/11:57:45
Date: Mon, 15 Apr 1996 21:31:31 -0400
From: dj AT delorie DOT com (DJ Delorie)
> Yes, as pointed out above, there is something wrong: in a nutshell, you
> should *never* have make build more than one file per rule. In the
> case given above, I think this should be changed to something like:
Amazingly enough, this works just fine with GNU make. How else would
you tell make that this one command produces these two files?
If my memory of the original message is accurate, his big problem is that he
produces both targets manually in the command list. If either is out of date
then both get rebuilt. Instead he should be producing '$@' the out of date
target.
BTW: Broeker should note that such a double target can only be used as a
subsidiary target (a dependency of a single primary target). Only the first
target listed will be recognized as a primary target and the second not 'made'
at all if the multiple-target line is the first in the makefile.
--
Art S. Kagel, kagel AT quasar DOT bloomberg DOT com
A proverb is no proverb to you 'till life has illustrated it. -- John Keats
- Raw text -