2 ms·
A rule can depend on imported files and exclude them with a modification to the variable for rule dependencies: a.o: a.c a.h cc -o ${.TARGET} ${.AL
by gkya 10y ago
A rule can depend on imported files and exclude them with a modification to the variable for rule dependencies:
a.o: a.c a.h
cc -o ${.TARGET} ${.ALLSRC:M*.c}
This is bmake though, I don't know the posix way because I always confuse $*, $>, $+ etc. There is also mkdep(1), tho I didn't ever use it.