malloc padding to avoid reading past the malloc()ed area.
[libav.git] / vhook / Makefile
... / ...
CommitLineData
1include ../config.mak
2
3VPATH=$(SRC_PATH)/vhook
4
5CFLAGS=-fPIC $(SHCFLAGS) -I.. -I$(SRC_PATH) -I$(SRC_PATH)/libavformat -I$(SRC_PATH)/libavcodec -I$(SRC_PATH)/libavutil -DHAVE_AV_CONFIG_H
6
7ifeq ($(CONFIG_DARWIN),yes)
8 SHFLAGS += -flat_namespace -undefined suppress
9endif
10HOOKS=null$(SLIBSUF) fish$(SLIBSUF) ppm$(SLIBSUF) watermark$(SLIBSUF)
11
12ifeq ($(HAVE_IMLIB2),yes)
13 HOOKS += imlib2$(SLIBSUF)
14endif
15
16ifeq ($(HAVE_FREETYPE2),yes)
17 HOOKS += drawtext$(SLIBSUF)
18 CFLAGS += `freetype-config --cflags`
19endif
20
21all: $(HOOKS)
22
23SRCS := $(HOOKS:$(SLIBSUF)=.c)
24
25depend: $(SRCS)
26 $(CC) -MM $(CFLAGS) $^ 1>.depend
27
28install:
29 install -d "$(libdir)/vhook"
30 install -m 755 $(HOOKS) "$(libdir)/vhook"
31
32imlib2$(SLIBSUF): imlib2.o
33 $(CC) $(LDFLAGS) -g -o $@ $(SHFLAGS) $< -lImlib2
34
35drawtext$(SLIBSUF): drawtext.o
36 $(CC) $(LDFLAGS) -g -o $@ $(SHFLAGS) $< `freetype-config --libs`
37
38%$(SLIBSUF): %.o
39ifeq ($(CONFIG_DARWIN),yes)
40 $(CC) $(LDFLAGS) $(SHFLAGS) -Wl,-install_name,$(libdir)/vhook/$@ -g -o $@ $<
41else
42 $(CC) $(LDFLAGS) -g -o $@ $(SHFLAGS) $<
43endif
44
45clean:
46 rm -f *.o *.d .depend *$(SLIBSUF) *~
47
48ifneq ($(wildcard .depend),)
49include .depend
50endif