Statistics
| Branch: | Revision:

streamers / Makefile @ afabfeb9

History | View | Annotate | Download (1.5 KB)

1
include utils.mak
2

    
3
CFLAGS = -g -Wall
4
CFLAGS += $(call cc-option, -Wdeclaration-after-statement)
5
CFLAGS += $(call cc-option, -Wno-switch)
6
CFLAGS += $(call cc-option, -Wdisabled-optimization)
7
CFLAGS += $(call cc-option, -Wpointer-arith)
8
CFLAGS += $(call cc-option, -Wredundant-decls)
9
CFLAGS += $(call cc-option, -Wno-pointer-sign)
10
CFLAGS += $(call cc-option, -Wcast-qual)
11
CFLAGS += $(call cc-option, -Wwrite-strings)
12
CFLAGS += $(call cc-option, -Wtype-limits)
13
CFLAGS += $(call cc-option, -Wundef)
14

    
15
CFLAGS += $(call cc-option, -funit-at-a-time)
16

    
17
GRAPES ?= GRAPES
18

    
19
CPPFLAGS = -I$(GRAPES)/include
20
CPPFLAGS += -I$(GRAPES)/som
21

    
22
ifdef DEBUG
23
CPPFLAGS += -DDEBUG
24
endif
25

    
26
LDFLAGS = -L$(GRAPES)/som/TopologyManager -L$(GRAPES)/som/ChunkTrading -L$(GRAPES)/som/ChunkBuffer
27
LDLIBS = -ltrading -lcb -ltopman
28

    
29
OBJS = dumbstreamer.o streaming.o output.o net_helpers.o input.o
30
ifdef THREADS
31
OBJS += loop-mt.o
32
CFLAGS += -pthread
33
LDFLAGS += -pthread
34
else
35
OBJS += loop.o
36
endif
37

    
38
ifdef FFDIR
39
FFSRC ?= $(FFDIR)
40
OBJS += Chunkiser/input-stream-avs.o
41
LDFLAGS += -L$(FFDIR)/libavcodec -L$(FFDIR)/libavformat -L$(FFDIR)/libavutil
42
LDLIBS += -lavformat -lavcodec -lavutil
43
LDLIBS += -lm
44
LDLIBS += $(call ld-option, -lz)
45
LDLIBS += $(call ld-option, -lbz2)
46
else
47
OBJS += input-stream-dummy.o
48
endif
49

    
50
all: dumbstreamer
51

    
52
dumbstreamer: $(OBJS) $(GRAPES)/som/net_helper.o
53

    
54
Chunkiser/input-stream-avs.o: CPPFLAGS += -I$(FFSRC) 
55

    
56
GRAPES:
57
	git clone http://www.disi.unitn.it/~abeni/PublicGits/GRAPES.git
58

    
59
prepare: GRAPES
60
	make -C GRAPES/som
61

    
62
clean:
63
	rm -f dumbstreamer
64
	rm -f *.o