CC = (getenv CC cc) OBJ = (extreplace (glob *.c) .c .o) rule test $OBJ [ echo " LD" $target shell $CC -o $target $sources ] rule %.o %.c [ echo " CC" $target shell $CC -c -o $target $source ] action clean [ echo " CLEAN" $OBJ test shell rm -f $OBJ test ] action info [ echo compiler: $CC echo number of CPUs: $numcpus echo number of jobs: $numjobs ] action test_invoke [ invoke test ] // dependencies depend foo.o foo.h depend bar.o bar.h depend test.o [foo.h bar.h] // default rule rule default test