source: sources/test_regression/29032005/Makefile @ 6

Last change on this file since 6 was 1, checked in by buchmann, 17 years ago

Initial import from CVS repository

File size: 1.9 KB
Line 
1include ../env.mk
2
3EXE_SCASS = system_systemcass.x
4EXE_SC    = system_systemc.x
5EXE       = ${EXE_SCASS} ${EXE_SC}
6OBJECTS   = $(EXE:.x=.o)
7LINKS     = $(OBJECTS:.o=.cpp)
8
9.SECONDARY:
10
11main : $(EXE) 
12
13test : ${EXE}
14        @for i in ${EXE_SCASS} ; do \
15  ./$$i --p --t --k; \
16  (tail -n +3 port_graph.dot | diff port_graph_reference.dot -) || eval ${failcom} ; \
17  ((tail -n +3 signal_graph.dot | diff signal_graph_reference.dot -) \
18  || (tail -n +3 signal_graph.dot | diff signal_graph_reference2.dot -)) \
19  || eval ${failcom} ; \
20  ((tail -n +3 process_order.dot | diff process_order_reference.dot -) \
21  || (tail -n +3 process_order.dot | diff process_order_reference2.dot -)) \
22  || eval ${failcom} ; \
23  (diff signal_order_reference.txt signal_order.txt) \
24  || (diff signal_order_reference2.txt signal_order.txt) \
25  || eval ${failcom} ; \
26  done
27        @echo Test OK.
28
29%.gif : %.dot
30        dot -Tgif -o $*.gif $*.dot
31
32%_systemc.x : %_systemc.o $(SYSTEMC_LIB)
33        $(CXX) -o $@ $*_systemc.o $(LFLAGS_SYSTEMC) 2>&1 | $(CPPFILT)
34
35%_systemcass.x : %_systemcass.o  $(SYSTEMCASS_LIB)
36        $(CXX) -o $@ $*_systemcass.o $(LFLAGS_SYSTEMCASS) 2>&1 | $(CPPFILT)
37
38include Makefile.deps
39
40%_systemc.cpp : %.cpp
41        ln -s $*.cpp $*_systemc.cpp
42
43%_systemcass.cpp : %.cpp
44        ln -s $*.cpp $*_systemcass.cpp
45
46%_systemc.o : %_systemc.cpp
47        $(CXX) $(CFLAGS_SYSTEMC) -MM $*_systemc.cpp >> Makefile.deps
48        $(CXX) $(CFLAGS_SYSTEMC) -c $*_systemc.cpp -o $*_systemc.o
49
50%_systemcass.o : %_systemcass.cpp
51        $(CXX) $(CFLAGS_SYSTEMCASS) -MM $*_systemcass.cpp >> Makefile.deps
52        $(CXX) $(CFLAGS_SYSTEMCASS) -c $*_systemcass.cpp -o $*_systemcass.o
53
54clean :
55        -echo > Makefile.deps
56        -rm -f *.o gmon.out
57        -rm -f signal_order.txt module_order.dot signal_graph.dot
58        -rm -f $(EXE) $(OBJECTS) 
59        -for i in $(LINKS) ; do unlink $$i ; done 2> /dev/null
60        -rm -f core*
61        -rm -rf generated_by_systemcass
62        -rm -rf tracesystem_systemcass.x.vcd tracesystem_systemc.x.vcd
63       
Note: See TracBrowser for help on using the repository browser.