X-Git-Url: http://git.cielonegro.org/gitweb.cgi?a=blobdiff_plain;f=examples%2FMakefile;h=606117f31f43ffcd6489b0d3370668265979d997;hb=761b90ab4f413d2e83460f170082f3b15bbaef4f;hp=e1c2c5aecc6979afd98f191bc126b3b19462e6bf;hpb=453cecf83e146e1ec23545fb371f7b91ab6adea7;p=Lucu.git diff --git a/examples/Makefile b/examples/Makefile index e1c2c5a..606117f 100644 --- a/examples/Makefile +++ b/examples/Makefile @@ -1,10 +1,35 @@ -build: - ghc --make HelloWorld -threaded -fglasgow-exts -O3 +TARGETS = \ + HelloWorld \ + Implanted \ + ImplantedSmall \ + Multipart \ + SSL \ + $(NULL) + +IMPLANT ?= ../dist/build/lucu-implant-file/lucu-implant-file + +build: $(TARGETS) + +SSL: SSL.hs + -ghc -Wall --make $@ -threaded -O3 -idist -odir dist -hidir dist + +%: %.hs + ghc -Wall --make $@ -threaded -O3 -idist -odir dist -hidir dist run: build ./HelloWorld clean: - rm -f HelloWorld *.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 $@ $< + +ImplantedSmall.hs: dist/SmallFile.hs +dist/SmallFile.hs: small-file.txt $(IMPLANT) + mkdir -p dist + $(IMPLANT) -m SmallFile -t "text/plain; charset=\"UTF-8\"" -o $@ $< -.PHONY: build run clean \ No newline at end of file +.PHONY: build run clean