-build: MiseRafturai.hs
- ghc --make HelloWorld -threaded -O3
- ghc --make Implanted -threaded -O3
+TARGETS = \
+ HelloWorld \
+ Implanted \
+ ImplantedSmall \
+ Multipart \
+ SSL \
+ $(NULL)
+
+IMPLANT ?= ../dist/build/lucu-implant-file/lucu-implant-file
+
+build: $(TARGETS)
+
+%: %.hs
+ ghc -Wall --make $@ -threaded -O3 -idist -odir dist -hidir dist
run: build
./HelloWorld
clean:
- rm -f HelloWorld Implanted MiseRafturai.hs *.hi *.o
+ rm -rf $(TARGETS) dist
+
+Implanted.hs: dist/MiseRafturai.hs
+dist/MiseRafturai.hs: mise-rafturai.html $(IMPLANT)
+ mkdir -p dist
+ $(IMPLANT) -m MiseRafturai -o $@ $<
-MiseRafturai.hs: mise-rafturai.html
- lucu-implant-file -m MiseRafturai -o $@ $<
+ImplantedSmall.hs: dist/SmallFile.hs
+dist/SmallFile.hs: small-file.txt $(IMPLANT)
+ mkdir -p dist
+ $(IMPLANT) -m SmallFile -o $@ $<
-.PHONY: build run clean
\ No newline at end of file
+.PHONY: build run clean