C#: add stepA_more and core functions.
[jackhill/mal.git] / cs / Makefile
CommitLineData
afde2df0
JM
1#####################
2
3TESTS =
4
b18969c0 5SOURCES = readline.cs types.cs reader.cs printer.cs env.cs core.cs \
faee4d12 6 stepA_more.cs
b18969c0 7
53beaa0a 8OTHER_SOURCES = getline.cs
afde2df0
JM
9
10#####################
11
afdf531e 12SRCS = step0_repl.cs step1_read_print.cs step2_eval.cs step3_env.cs \
faa20db2 13 step4_if_fn_do.cs step5_tco.cs step6_file.cs step7_quote.cs \
faee4d12 14 step8_macros.cs stepA_more.cs
53beaa0a 15
53beaa0a 16LIB_SRCS = $(filter-out step%,$(OTHER_SOURCES) $(SOURCES))
afde2df0 17
b18969c0
JM
18FLAGS = -debug+
19
afde2df0
JM
20#####################
21
b18969c0 22all: mal.exe $(patsubst %.cs,%.exe,$(SRCS))
afde2df0 23
53beaa0a 24mal.exe: $(patsubst %.cs,%.exe,$(word $(words $(SOURCES)),$(SOURCES)))
afde2df0
JM
25 cp $< $@
26
53beaa0a
JM
27mal.dll: $(LIB_SRCS)
28 mcs $(FLAGS) -target:library $+ -out:$@
afde2df0 29
53beaa0a
JM
30%.exe: %.cs mal.dll
31 mcs $(FLAGS) -r:mal.dll $<
afde2df0
JM
32
33clean:
53beaa0a 34 rm -f *.dll *.exe *.mbd
afde2df0
JM
35
36.PHONY: stats tests $(TESTS)
37
38stats: $(SOURCES)
39 @wc $^
40
41tests: $(TESTS)
42
43$(TESTS):
44 @echo "Running $@"; \
45 ./$@ || exit 1; \