build.mk 1.65 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12

TRACE_TARGETS += $(LIBDIR)/libtrace.la
TRACE_TARGETS += $(DIR)/trace_dump
TRACE_TARGETS += $(DIR)/trace_dumpdiff
#TRACE_TARGETS += $(DIR)/trace_fft
TRACE_TARGETS += $(DIR)/trace_list
TRACE_TARGETS += $(DIR)/trace_view

ARCHSRCS := $(DIR)/trace.c $(DIR)/trace_tcp.c
ARCHOBJS := $(ARCHSRCS:.c=.lo)


Jeroen Vreeken's avatar
Jeroen Vreeken committed
13
$(LIBDIR)/libtrace.la: libutils.la liblog.la
14
$(LIBDIR)/libtrace.la: CFLAGS += -Wall -O3 -fPIC
Jeroen Vreeken's avatar
Jeroen Vreeken committed
15
$(LIBDIR)/libtrace.la: LDFLAGS += -lutils -llog -lm
16
17
18
19
20
$(LIBDIR)/libtrace.la: $(ARCHOBJS)
	$(LIB_LINK)

TRACE_DUMP_SRCS := $(DIR)/trace_dump.c
TRACE_DUMP_OBJS := $(TRACE_DUMP_SRCS:.c=.o)
Jeroen Vreeken's avatar
Jeroen Vreeken committed
21
$(DIR)/trace_dump: libtrace.la
22
23
24
25
26
$(DIR)/trace_dump: LDFLAGS += -ltrace
$(DIR)/trace_dump: $(TRACE_DUMP_OBJS)

TRACE_DUMPDIFF_SRCS := $(DIR)/trace_dumpdiff.c
TRACE_DUMPDIFF_OBJS := $(TRACE_DUMPDIFF_SRCS:.c=.o)
Jeroen Vreeken's avatar
Jeroen Vreeken committed
27
$(DIR)/trace_dumpdiff: libtrace.la
28
29
30
31
32
$(DIR)/trace_dumpdiff: LDFLAGS += -ltrace
$(DIR)/trace_dumpdiff: $(TRACE_DUMPDIFF_OBJS)

TRACE_FFT_SRCS := $(DIR)/trace_fft.c
TRACE_FFT_OBJS := $(TRACE_FFT_SRCS:.c=.o)
Jeroen Vreeken's avatar
Jeroen Vreeken committed
33
$(DIR)/trace_fft: libtrace.la
34
35
36
37
38
$(DIR)/trace_fft: LDFLAGS += -ltrace -lm -lfftw3
$(DIR)/trace_fft: $(TRACE_FFT_OBJS)

TRACE_LIST_SRCS := $(DIR)/trace_list.c
TRACE_LIST_OBJS := $(TRACE_LIST_SRCS:.c=.o)
Jeroen Vreeken's avatar
Jeroen Vreeken committed
39
$(DIR)/trace_list: libtrace.la
40
41
42
43
44
$(DIR)/trace_list: LDFLAGS += -ltrace
$(DIR)/trace_list: $(TRACE_LIST_OBJS)

TRACE_VIEW_SRCS := $(DIR)/trace_view.c
TRACE_VIEW_OBJS := $(TRACE_VIEW_SRCS:.c=.o)
Jeroen Vreeken's avatar
Jeroen Vreeken committed
45
$(DIR)/trace_view: libtrace.la
46
47
48
49
50
51
52
53
54
55
$(DIR)/trace_view: LDFLAGS += -ltrace
$(DIR)/trace_view: $(TRACE_VIEW_OBJS)

TARGETS += $(TRACE_TARGETS)
CLEAN += $(TRACE_TARGETS) $(ARCHOBJS)
CLEAN += $(TRACE_DUMP_OBJS)
CLEAN += $(TRACE_DUMPDIFF_OBJS)
CLEAN += $(TRACE_FFT_OBJS)
CLEAN += $(TRACE_LIST_OBJS)
CLEAN += $(TRACE_VIEW_OBJS)