mk doesn't work the way I expect
Guy Middleton
gamiddleton at watmath.waterloo.edu
Fri Mar 31 12:54:49 AEST 1989
We just got mk, and I tried running this mkfile:
PROGS = host addr hostaddr
all:V: $PROGS
$PROGS:
$CC -o $target $target.c
I expected this to happen:
cc -o host host.c
cc -o addr addr.c
cc -o hostaddr hostaddr.c
Instead, I got this:
cc -o host addr hostaddr host addr hostaddr.c
I got what I expected when the "all:V: $PROGS" line was removed.
Why does it work this way? Am I missing something obvious?
-Guy Middleton, University of Waterloo gamiddleton at watmath.waterloo.edu
More information about the Comp.unix.wizards
mailing list