advent-of-code/Makefile

14 lines
245 B
Makefile
Raw Permalink Normal View History

2024-12-03 00:29:42 +11:00
HS_SRCS = $(shell find . -name 'day*.hs')
HS_TARGETS = $(HS_SRCS:.hs=)
2024-12-04 17:21:12 +11:00
HI_TARGETS = $(HS_SRCS:.hs=.hi)
O_TARGETS = $(HS_SRCS:.hs=.o)
2024-12-03 00:29:42 +11:00
all: $(HS_TARGETS)
%: %.hs
ghc $<
2024-12-04 17:21:12 +11:00
clean:
rm -rf $(HS_TARGETS) $(HI_TARGETS) $(O_TARGETS)
2024-12-03 00:29:42 +11:00
.PHONY: all clean