build.mk 1.2 KB
Newer Older
Jeroen Vreeken's avatar
Jeroen Vreeken committed
1
2
3
4
5
6
7

CONTROLLER_TARGETS += $(LIBDIR)/libcontroller.la

CONTROLLER_SRCS= \
	$(DIR)/controller_block.c \
	$(DIR)/controller_block_param.c \
	$(DIR)/controller_block_trace.c \
8
	$(DIR)/controller_bus.c \
Jeroen Vreeken's avatar
Jeroen Vreeken committed
9
	$(DIR)/controller_command.c \
10
	$(DIR)/controller_mem.c \
Jeroen Vreeken's avatar
Jeroen Vreeken committed
11
	$(DIR)/controller_module.c \
Jeroen Vreeken's avatar
Jeroen Vreeken committed
12
	$(DIR)/controller_time.c \
Jeroen Vreeken's avatar
Jeroen Vreeken committed
13
14
15
16
17
18
19
20
21
22
	$(DIR)/controller_trace.c \
	$(DIR)/controller_sample.c \
	$(DIR)/controller_dumpdot.c \
	$(DIR)/controller_load.c \
	$(DIR)/controller_load_variable.c \
	$(DIR)/controller_load_parser.tab.c \
	$(DIR)/controller_load_parser.yy.c
CONTROLLER_OBJS := $(CONTROLLER_SRCS:.c=.lo)


23
$(CONTROLLER_OBJS): CFLAGS += -g -Wall -pthread
Jeroen Vreeken's avatar
Jeroen Vreeken committed
24
$(LIBDIR)/libcontroller.la: libshell.la libcommand.la libtrace.la
25
26
27
28
29
30
$(LIBDIR)/libcontroller.la_LDFLAGS += -lshell  -pthread -lrt -lcommand -ltrace

ifneq ($(OS), FreeBSD)
$(LIBDIR)/libcontroller.la_LDFLAGS += -ldl
endif

Jeroen Vreeken's avatar
Jeroen Vreeken committed
31
32
33
34
35
36
37
38
39
40
41
$(LIBDIR)/libcontroller.la: $(CONTROLLER_OBJS)
	$(LIB_LINK)

$(DIR)/controller_load_parser.tab.lo: $(DIR)/controller_load_parser.yy.c
$(DIR)/controller_load.lo: $(DIR)/controller_load_parser.tab.h
$(DIR)/controller_load.lo: $(DIR)/controller_load_parser.yy.h


TARGETS += $(CONTROLLER_TARGETS)
CLEAN += $(CONTROLLER_TARGETS) $(CONTROLLER_OBJS)
SRCS += $(CONTROLLER_SRCS)