Revision e11386c0 chunker_player/Makefile

View differences:

chunker_player/Makefile
1 1
include ../common.mak
2 2

  
3
ifdef WINDOWS
4
OUTPUTFILE = chunker_player.exe
5
else
6
OUTPUTFILE = chunker_player
7
endif
8

  
9
ifeq ($(IO), httpevent)
10
CPPFLAGS += -DHTTPIO
11
endif
12

  
13
ifeq ($(IO), tcp)
14
CPPFLAGS += -DTCPIO
15
endif
16

  
3 17
#SDL config here
4
#LOCAL_SDL_CPPFLAGS = $(shell $(LOCAL_ABS_SDL)/bin/sdl-config --cflags;)
5
#LOCAL_SDL_LDFLAGS = $(shell $(LOCAL_ABS_SDL)/bin/sdl-config --static-libs;)
6 18
LOCAL_SDL_CPPFLAGS = -I$(LOCAL_ABS_SDL)/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT
7
#LOCAL_SDL_LDFLAGS = -L$(LOCAL_ABS_SDL)/lib -Wl,-rpath,$(LOCAL_ABS_SDL)/lib
8
LOCAL_SDL_LDFLAGS = -Wl,-rpath,$(LOCAL_ABS_SDL)/lib
9
LOCAL_SDL_LDLIBS = $(LOCAL_ABS_SDL)/lib/libSDL.a -ldl
19
ifdef MAC_OS
20
#force static linking to .a SDL libraries
21
LOCAL_SDL_LDFLAGS =  -framework OpenGL $(LOCAL_ABS_SDL)/lib/libSDLmain.a $(LOCAL_ABS_SDL)/lib/libSDL.a  -Wl,-framework,Cocoa -Wl,-framework,ApplicationServices -Wl,-framework,Carbon -Wl,-framework,AudioToolbox -Wl,-framework,AudioUnit -Wl,-framework,IOKit
22
else
23
LOCAL_SDL_LDFLAGS = -L$(LOCAL_ABS_SDL)/lib  
24
endif
25
ifndef WINDOWS
26
ifdef MAC_OS
27
LOCAL_SDL_LDLIBS =
28
else
29
LOCAL_SDL_LDLIBS = $(LOCAL_ABS_SDL)/lib/libSDL.a  -ldl $(LOCAL_ABS_SDL)/lib/libSDLmain.a
30
endif
31
endif
10 32

  
11 33
LOCAL_SDLIMAGE_CPPFLAGS = -I$(LOCAL_SDLIMAGE)/include/SDL
12
#LOCAL_SDLIMAGE_LDFLAGS = -L$(LOCAL_SDLIMAGE)/lib
13
LOCAL_SDLIMAGE_LDLIBS = $(LOCAL_SDLIMAGE)/lib/libSDL_image.a
34
ifdef WINDOWS
35
LOCAL_SDLIMAGE_LDLIBS = $(LOCAL_SDLIMAGE)/lib/libSDL_image.a $(LOCAL_LIBPNG)/lib/libpng.a $(LOCAL_LIBINTL)/lib/libintl.*.a $(LOCAL_LIBICONV)/lib/libiconv.a
36
else
37
LOCAL_SDLIMAGE_LDLIBS = $(LOCAL_SDLIMAGE)/lib/libSDL_image.a $(LOCAL_LIBPNG)/lib/libpng.a
38
endif
14 39

  
15
#LOCAL_FREETYPE_CPPFLAGS = $(shell $(LOCAL_FREETYPE)/bin/freetype-config --cflags;)
16
#LOCAL_FREETYPE_LDFLAGS = $(shell $(LOCAL_FREETYPE)/bin/freetype-config --libs;)
17 40
LOCAL_FREETYPE_CPPFLAGS = -I$(LOCAL_FREETYPE)/include/ -I$(LOCAL_FREETYPE)/include/freetype2
18
#LOCAL_FREETYPE_LDFLAGS = -L$(LOCAL_FREETYPE)/lib -Wl,--rpath -Wl,$(LOCAL_FREETYPE)/lib
19
LOCAL_FREETYPE_LDFLAGS = -Wl,--rpath -Wl,$(LOCAL_FREETYPE)/lib
41
LOCAL_FREETYPE_LDFLAGS = -Wl,-rpath -Wl,$(LOCAL_FREETYPE)/lib
42
#LOCAL_FREETYPE_LDFLAGS = -Wl,$(LOCAL_FREETYPE)/lib
20 43
LOCAL_FREETYPE_LDLIBS = $(LOCAL_FREETYPE)/lib/libfreetype.a
21 44

  
22 45
LOCAL_SDLTTF_CPPFLAGS = -I$(LOCAL_SDLTTF)/include/SDL
23
#LOCAL_SDLTTF_LDFLAGS = -L$(LOCAL_SDLTTF)/lib
24 46
LOCAL_SDLTTF_LDLIBS = $(LOCAL_SDLTTF)/lib/libSDL_ttf.a
25 47

  
26 48
#microhttpd config here
27
#LOCAL_MHD_CPPFLAGS = -I$(LOCAL_MHD) -I$(LOCAL_MHD)/src/daemon -I$(LOCAL_MHD)/src/include
28
#LOCAL_MHD_LDFLAGS = -L$(LOCAL_MHD)/src/daemon
29
#LOCAL_MHD_LDLIBS = -lmicrohttpd
30
#LOCAL_MHD_LDLIBS = $(LOCAL_MHD)/src/daemon/.libs/libmicrohttpd.a
31 49
LOCAL_MHD_CPPFLAGS = -I$(LOCAL_MHD)/include
32
#LOCAL_MHD_LDFLAGS = -L$(LOCAL_MHD)/lib
50
ifdef WINDOWS
51
LOCAL_MHD_LDLIBS = $(LOCAL_MHD)/lib/libmicrohttpd.a $(LOCAL_PLIBC)/lib/libplibc.dll.a $(LOCAL_PTHREAD)/lib/libpthread.a
52
else
33 53
LOCAL_MHD_LDLIBS = $(LOCAL_MHD)/lib/libmicrohttpd.a
54
endif
34 55

  
35 56
LOCAL_CONFUSE_CPPFLAGS = -I$(LOCAL_CONFUSE)/include
36 57
LOCAL_CONFUSE_LDLIBS = $(LOCAL_CONFUSE)/lib/libconfuse.a
......
48 69
LDLIBS += $(LOCAL_MHD_LDLIBS) $(LOCAL_CONFUSE_LDLIBS) $(LOCAL_FREETYPE_LDLIBS)
49 70
LDLIBS += $(LOCAL_FFMPEG_LDLIBS) $(LOCAL_COMMON_LDLIBS)
50 71

  
72
ifdef WINDOWS
73
LDLIBS += $(DYNAMIC_LDLIBS) -lmingw32 $(LOCAL_ABS_SDL)/lib/libSDLmain.a $(LOCAL_ABS_SDL)/lib/libSDL.dll.a -lwinmm -lgdi32
74
else
51 75
LDLIBS += $(DYNAMIC_LDLIBS)
76
endif
77

  
78
LINKER = $(CC)
79

  
80
all: $(OUTPUTFILE)
81

  
82
OBJS = ../chunk_transcoding/external_chunk_transcoding.o
83
ifeq ($(IO), httpevent)
84
OBJS += http_chunk_puller.o
85
endif
52 86

  
53
all: chunker_player
87
ifeq ($(IO), tcp)
88
OBJS += tcp_chunk_puller.o
89
endif
90
OBJS += chunker_player.o QoE_Estimator.o player_stats.o player_core.o player_gui.o
54 91

  
55
chunker_player: ../chunk_transcoding/external_chunk_transcoding.o chunk_puller.o chunker_player.o player_core.o player_gui.o
92
$(OUTPUTFILE): $(OBJS)
93
	$(LINKER) $(LDFLAGS) $^ $(LDLIBS) -o $@
56 94

  
57 95
clean:
58
	rm -f chunker_player
96
	rm -f $(OUTPUTFILE)
59 97
	rm -f *.o

Also available in: Unified diff