2002-11-21 03:50:36 +00:00
|
|
|
include ../config.mak
|
|
|
|
|
2002-11-26 03:35:18 +00:00
|
|
|
VPATH=$(SRC_PATH)/vhook
|
|
|
|
|
2005-08-01 20:07:05 +00:00
|
|
|
CFLAGS=-fPIC $(SHCFLAGS) -I.. -I$(SRC_PATH) -I$(SRC_PATH)/libavformat -I$(SRC_PATH)/libavcodec -I$(SRC_PATH)/libavutil -DHAVE_AV_CONFIG_H
|
2002-11-21 03:50:36 +00:00
|
|
|
|
2006-01-12 00:00:00 +00:00
|
|
|
#FIXME: This needs to be in configure/config.mak
|
2002-11-23 01:29:25 +00:00
|
|
|
ifeq ($(CONFIG_DARWIN),yes)
|
2006-01-12 00:00:00 +00:00
|
|
|
SHFLAGS = -dynamiclib -Wl,-single_module -flat_namespace -undefined suppress -Wl,-install_name,$(libdir)/vhook/$@
|
2002-11-23 01:29:25 +00:00
|
|
|
endif
|
2005-09-26 10:05:13 +00:00
|
|
|
HOOKS=null$(SLIBSUF) fish$(SLIBSUF) ppm$(SLIBSUF) watermark$(SLIBSUF)
|
2002-11-21 03:50:36 +00:00
|
|
|
|
|
|
|
ifeq ($(HAVE_IMLIB2),yes)
|
2005-09-26 10:05:13 +00:00
|
|
|
HOOKS += imlib2$(SLIBSUF)
|
2006-05-18 09:02:05 +00:00
|
|
|
LDFLAGS += -lImlib2
|
2005-12-17 18:14:38 +00:00
|
|
|
endif
|
2002-11-21 03:50:36 +00:00
|
|
|
|
2003-02-11 04:01:07 +00:00
|
|
|
ifeq ($(HAVE_FREETYPE2),yes)
|
2005-09-26 10:05:13 +00:00
|
|
|
HOOKS += drawtext$(SLIBSUF)
|
2003-02-11 04:01:07 +00:00
|
|
|
CFLAGS += `freetype-config --cflags`
|
2006-05-18 09:02:05 +00:00
|
|
|
LDFLAGS += `freetype-config --libs`
|
2005-12-17 18:14:38 +00:00
|
|
|
endif
|
2003-02-11 04:01:07 +00:00
|
|
|
|
2005-12-17 18:14:38 +00:00
|
|
|
all: $(HOOKS)
|
2002-11-21 03:50:36 +00:00
|
|
|
|
2005-09-26 10:05:13 +00:00
|
|
|
SRCS := $(HOOKS:$(SLIBSUF)=.c)
|
2003-01-22 09:53:25 +00:00
|
|
|
|
2003-02-01 20:56:39 +00:00
|
|
|
depend: $(SRCS)
|
2003-01-22 09:53:25 +00:00
|
|
|
$(CC) -MM $(CFLAGS) $^ 1>.depend
|
2003-01-14 15:30:42 +00:00
|
|
|
|
2006-03-24 20:34:00 +00:00
|
|
|
install: $(HOOKS)
|
2005-03-16 19:11:58 +00:00
|
|
|
install -d "$(libdir)/vhook"
|
|
|
|
install -m 755 $(HOOKS) "$(libdir)/vhook"
|
2002-11-21 03:50:36 +00:00
|
|
|
|
2006-05-18 12:14:02 +00:00
|
|
|
ALLHOOKS=$(HOOKS) imlib2$(SLIBSUF) drawtext$(SLIBSUF)
|
|
|
|
uninstall:
|
|
|
|
rm -f $(addprefix $(libdir)/vhook/,$(ALLHOOKS))
|
|
|
|
-rmdir "$(libdir)/vhook/"
|
|
|
|
|
2005-09-26 10:05:13 +00:00
|
|
|
%$(SLIBSUF): %.o
|
2005-07-11 00:15:37 +00:00
|
|
|
$(CC) $(LDFLAGS) -g -o $@ $(SHFLAGS) $<
|
2002-11-21 03:50:36 +00:00
|
|
|
|
|
|
|
clean:
|
2006-01-16 14:59:54 +00:00
|
|
|
rm -f *.o *.d *~ *.a *.lib *.so *.dylib *.dll
|
|
|
|
|
|
|
|
distclean: clean
|
2006-01-26 23:42:30 +00:00
|
|
|
rm -f .depend
|
2003-01-22 09:53:25 +00:00
|
|
|
|
|
|
|
ifneq ($(wildcard .depend),)
|
|
|
|
include .depend
|
|
|
|
endif
|