source: sources/test_regression/Makefile.common @ 56

Last change on this file since 56 was 56, checked in by meunier, 11 years ago
  • Tried to fix a problem with echo
  • Started to resolve some tests failing (often because of the test itself)
File size: 1.3 KB
Line 
1
2SYSTEM    = system.cpp
3EXE_SCASS = $(SYSTEM:.cpp=_systemcass.x)
4EXE_SC    = $(SYSTEM:.cpp=_systemc.x)
5OBJ_SC    = $(EXE_SC:.x=.o) $(SRC:.cpp=_systemc.o)
6OBJ_SCASS = $(EXE_SCASS:.x=.o) $(SRC:.cpp=_systemcass.o)
7EXE       = $(EXE_SCASS) $(EXE_SC)
8LOG_SC    = $(EXE_SC:.x=.log)
9LOG_SCASS = $(EXE_SCASS:.x=.log)
10LOG       = $(LOG_SC) $(LOG_SCASS)
11OBJECTS   = $(OBJ_SC) $(OBJ_SCASS)
12
13OK = \033[00;32mOK\033[0m
14KO = \033[00;31mKO\033[0m
15
16
17all: msg $(EXE)
18
19msg:
20        @echo "| Compiling $$(basename $$(pwd))"
21
22
23$(EXE_SC): $(OBJ_SC) $(SYSTEMC_LIB)
24        @echo "| $@"
25        $(SILENCE)$(CXX) -o $@ $(OBJ_SC) $(LFLAGS_SYSTEMC) 2>&1 | $(CPPFILT)
26
27$(EXE_SCASS): $(OBJ_SCASS) $(SYSTEMCASS_LIB)
28        @echo "| $@"
29        $(SILENCE)$(CXX) -o $@ $(OBJ_SCASS) $(LFLAGS_SYSTEMCASS) 2>&1 | $(CPPFILT)
30
31-include Makefile.deps
32
33%_systemc.o: %.cpp
34        @echo "| $@"
35        $(SILENCE)$(CXX) $(CFLAGS_SYSTEMC) -MM $< > Makefile.deps
36        $(SILENCE)$(CXX) $(CFLAGS_SYSTEMC) -c $< -o $@
37
38%_systemcass.o: %.cpp
39        @echo "| $@"
40        $(SILENCE)$(CXX) $(CFLAGS_SYSTEMCASS) -MM $< > Makefile.deps
41        $(SILENCE)$(CXX) $(CFLAGS_SYSTEMCASS) -c $< -o $@
42
43clean :
44        @echo "| Cleaning $$(basename $$(pwd))"
45        $(SILENCE)rm -f Makefile.deps
46        $(SILENCE)rm -f *.o
47        $(SILENCE)rm -f $(LOG)
48        $(SILENCE)rm -f methodprocess_graph.dot reduced_signal_graph.dot signal_order.txt signal_graph.dot port_graph.dot trace_file.vcd
49        $(SILENCE)rm -f $(EXE) $(OBJECTS) $(ERASE)
50       
Note: See TracBrowser for help on using the repository browser.