all: foo bar foo bar: $@.txt cp $@.txt $@ foo.txt: echo FOO >$@ bar.txt: echo BAR >$@