Compute Must Values Automatically
[satune.git] / src / Test / Makefile
index ca9a632b022fb867a0965506820d75174da6c888..0f1bc39a80de5ebd6b4f31b2314633c18250ca3b 100644 (file)
@@ -1,19 +1,22 @@
 BASE := ..
 
-OBJECTS := $(patsubst %.c, %, $(wildcard *.c))
+OBJECTS := $(patsubst %.cc, ../bin/%, $(wildcard *.cc))
 
 include $(BASE)/common.mk
 
 DEPS := $(join $(addsuffix ., $(dir $(OBJECTS))), $(addsuffix .d, $(notdir $(OBJECTS))))
 
-CPPFLAGS += -I$(BASE) -I$(BASE)/AST -I$(BASE)/Collections
+CPPFLAGS += -I$(BASE) -I$(BASE)/AST -I$(BASE)/Collections -I$(BASE)/Backend
 
-all: $(OBJECTS)
+all: $(OBJECTS) ../bin/run.sh
 
 -include $(DEPS)
 
-%: %.c
-       $(CC) -MMD -MF $(@D)/.$(@F).d -o $@ $< $(CPPFLAGS) -L$(BASE)/bin/ -l_cons_comp
+../bin/%: %.cc
+       $(CXX) -MMD -MF $(@D)/.$(@F).d -o ../bin/$@ $< $(CPPFLAGS) -L$(BASE)/bin/ -l_cons_comp
+
+../bin/run.sh: run.sh
+       cp run.sh ../bin/run.sh
 
 clean::
-       rm -f $(OBJECTS) $(DEPS)
+       rm -f $(OBJECTS) $(DEPS) ../bin/run.sh