HS_SRCS = $(shell find . -name 'day*.hs') HS_TARGETS = $(HS_SRCS:.hs=) all: $(HS_TARGETS) %: %.hs ghc $< clean: $(HS_TARGETS) rm -rf $(HS_TARGETS) .PHONY: all clean