cows = $(patsubst Forts/fortune_%.md,Cows/cow-%.txt,$(wildcard Forts/fortune_*.md)) $(cows): Cows/cow-%.txt: Forts/fortune_%.md @mkdir -p $(@D) cat $< | cowsay > $@ progs += forts progs += $(cows) dross += Cows/