You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
1.2KB

  1. include ../config.mak
  2. VPATH=$(SRC_PATH_BARE)/vhook
  3. CFLAGS=-I$(BUILD_ROOT) -I$(SRC_PATH) -I$(SRC_PATH)/libavutil -I$(SRC_PATH)/libavcodec \
  4. -I$(SRC_PATH)/libavformat -I$(SRC_PATH)/libswscale $(VHOOKCFLAGS) -DHAVE_AV_CONFIG_H
  5. LDFLAGS+= -g
  6. HOOKS=null$(SLIBSUF) fish$(SLIBSUF) ppm$(SLIBSUF) watermark$(SLIBSUF)
  7. ALLHOOKS=$(HOOKS) imlib2$(SLIBSUF) drawtext$(SLIBSUF)
  8. ifeq ($(HAVE_IMLIB2),yes)
  9. HOOKS += imlib2$(SLIBSUF)
  10. CFLAGS += `imlib2-config --cflags`
  11. LIBS_imlib2$(SLIBSUF) = `imlib2-config --libs`
  12. endif
  13. ifeq ($(HAVE_FREETYPE2),yes)
  14. HOOKS += drawtext$(SLIBSUF)
  15. CFLAGS += `freetype-config --cflags`
  16. LIBS_drawtext$(SLIBSUF) = `freetype-config --libs`
  17. endif
  18. SRCS := $(HOOKS:$(SLIBSUF)=.c)
  19. all: $(HOOKS)
  20. depend dep: $(SRCS)
  21. $(CC) -MM $(CFLAGS) $^ 1>.depend
  22. install: $(HOOKS)
  23. install -d "$(shlibdir)/vhook"
  24. install -m 755 $(HOOKS) "$(shlibdir)/vhook"
  25. uninstall:
  26. rm -f $(addprefix $(shlibdir)/vhook/,$(ALLHOOKS))
  27. -rmdir "$(shlibdir)/vhook/"
  28. %$(SLIBSUF): %.o
  29. $(CC) $(LDFLAGS) -o $@ $(VHOOKSHFLAGS) $< $(VHOOKLIBS) $(LIBS_$@)
  30. clean:
  31. rm -f *.o *.d *~ *.a *.lib *.so *.dylib *.dll
  32. distclean: clean
  33. rm -f .depend
  34. .PHONY: all depend dep clean distclean install* uninstall*
  35. -include .depend