From afde2df05daa178cf4d4bddccc0f27093416a9c2 Mon Sep 17 00:00:00 2001 From: Joel Martin Date: Sun, 6 Apr 2014 19:23:28 -0500 Subject: C#: step0_repl using de Icaza's getline.cs --- cs/Makefile | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 cs/Makefile (limited to 'cs/Makefile') diff --git a/cs/Makefile b/cs/Makefile new file mode 100644 index 0000000..c03e6c9 --- /dev/null +++ b/cs/Makefile @@ -0,0 +1,46 @@ +##################### + +TESTS = + +SOURCES = readline.h readline.c types.h types.c \ + reader.h reader.c printer.h printer.c \ + env.c core.h core.c interop.h interop.c \ + stepA_more.c + +##################### + +SRCS = step0_repl.cs +OBJS = $(SRCS:%.cs=%.exe) +BINS = $(OBJS:%.o=%) +OTHER_OBJS = getline.dll + +##################### + +all: $(BINS) mal.exe + +mal.exe: $(word $(words $(OBJS)),$(OBJS)) + cp $< $@ + +$(OTHER_OBJS): %.dll: %.cs + mcs -target:library -out:$@ $+ + +$(OBJS): %.exe: %.cs $(OTHER_OBJS) + mcs $(foreach lib,$(OTHER_OBJS),-r:$(lib)) $(@:%.exe=%.cs) + +#$(patsubst %.o,%,$(filter step%,$(OBJS))): $(OTHER_OBJS) +#$(BINS): %: %.o +# gcc $+ -o $@ $(LDFLAGS) + +clean: + rm -f $(OBJS) $(OTHER_OBJS) mal.exe + +.PHONY: stats tests $(TESTS) + +stats: $(SOURCES) + @wc $^ + +tests: $(TESTS) + +$(TESTS): + @echo "Running $@"; \ + ./$@ || exit 1; \ -- cgit v1.2.3