diff options
Diffstat (limited to '2021/Makefile')
-rw-r--r-- | 2021/Makefile | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/2021/Makefile b/2021/Makefile index 7ad280f..bacaeff 100644 --- a/2021/Makefile +++ b/2021/Makefile @@ -3,6 +3,7 @@ GHCBASEFLAGS = -package parsec -package array GHCFLAGS = $(GHCBASEFLAGS) -Wall -O2 -threaded -fdefer-typed-holes CXX = g++ CXXFLAGS = -Wall -Wextra -std=c++17 -O2 +FUTHARK = futhark OBJDIR = obj @@ -12,8 +13,10 @@ HASKELL_SRC := $(filter-out $(HASKELL_AUX),$(wildcard *.hs)) CPP_SRC := $(filter-out $(CPP_AUX),$(wildcard *.cpp)) HASKELL_BIN := $(HASKELL_SRC:.hs=) CPP_BIN := $(CPP_SRC:.cpp=) +FUTHARK_SRC := $(wildcard *.fut) +FUTHARK_BIN := $(FUTHARK_SRC:.fut=) -BINARIES := $(HASKELL_BIN) $(CPP_BIN) +BINARIES := $(HASKELL_BIN) $(CPP_BIN) $(FUTHARK_BIN) .PHONY: all clean depend @@ -36,6 +39,9 @@ $(HASKELL_BIN): %: %.hs | $(OBJDIR)/% $(CPP_BIN): %: %.cpp $(CPP_AUX) | $(OBJDIR) $(CXX) $(CXXFLAGS) -o $@ $< +$(FUTHARK_BIN): %: %.fut + $(FUTHARK) c $< + $(OBJDIR)/%: mkdir -p $@ |