forked from xfguo/nirgam
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile.defs
executable file
·46 lines (31 loc) · 1.16 KB
/
Makefile.defs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
## Variable that points to SystemC installation path
#SYSTEMC = ../../..
SYSTEMC = ./systemC
INCDIR = -I. -I.. -I$(SYSTEMC)/include
LIBDIR = -L. -L.. -L$(SYSTEMC)/lib-$(TARGET_ARCH)
LIBS = -lsystemc -lm -ldl $(EXTRA_LIBS)
EXE = $(MODULE)
.SUFFIXES: .cc .cpp .o .x .so
$(EXE): $(CORE_OBJS) $(APP_OBJS) $(APP_LIB) $(ROUTER_OBJS) $(ROUTER_LIB) $(SYSTEMC)/lib-$(TARGET_ARCH)/libsystemc.a
$(CC) $(CFLAGS) $(INCDIR) $(LIBDIR) -o $@ $(CORE_OBJS) $(LIBS) 2>&1 | c++filt
application/src/CBR.o : application/src/TG.o
application/src/Multimedia.o : application/src/TG.o
application/src/VBR.o : application/src/TG.o
application/src/Bursty.o : application/src/TG.o
application/src/Trace_traffic.o : application/src/TG.o
.cpp.o:
$(CC) $(CFLAGS) $(INCDIR) -o $@ -c $<
.cc.o:
$(CC) $(CFLAGS) $(INCDIR) -o $@ -c $<
application/lib/%.so : application/src/%.o
$(CC) -shared -W1,-soname,$@ -o $@ $<
router/lib/%.so : router/src/%.o
$(CC) -shared -W1,-soname,$@ -o $@ $<
ultraclean : clean cleanlogs cleanresults
clean:
rm -f $(CORE_OBJS) $(APP_OBJS) $(ROUTER_OBJS) $(EXE) $(APP_LIB) $(ROUTER_LIB)
#rm -f `find -name "*~"`
cleanlogs:
rm -rf log/*/*
cleanresults:
rm -rf results/*