# a BSD compatible 'install' program INSTALL = install include config.mak BINDIR = $(prefix)/lib/$(PROGNAME)/codecs # a BSD compatible 'install' program INSTALL = install DO_MAKE = @ for i in $(SUBDIRS); do $(MAKE) -C $$i $@ || exit; done LIB_NUPPELVIDEO=libnuppelvideo$(SLIBSUF) SRC_NUPPELVIDEO=nuppelvideo.c RTjpegN.c minilzo.c OBJ_NUPPELVIDEO=$(SRC_NUPPELVIDEO:.c=.o) # just for: make dep SRCS=$(SRC_NUPPELVIDEO) CFLAGS = $(MLIB_INC) $(OPTFLAGS) ifneq ($(TARGET_ARCH_X86),yes) CFLAGS += -fPIC endif .SUFFIXES: .c .o all: $(SUBDIRS) $(LIB_NUPPELVIDEO) .PHONY: subdirs $(SUBDIRS) subdirs: $(SUBDIRS) $(SUBDIRS): $(MAKE) -C $@ $(LIB_NUPPELVIDEO): $(OBJ_NUPPELVIDEO) ifeq ($(TARGET_OS),WIN32) $(CC) --shared -o $@ $(OBJ_NUPPELVIDEO) -lc else $(LD) --shared -soname $@ -o $@ $(OBJ_NUPPELVIDEO) -lc endif .c.o: $(CC) -c $(CFLAGS) -o $@ $< install: rm -f $(BINDIR)/*$(SLIBSUF) $(DO_MAKE) $(INSTALL) -m 755 -s -p *$(SLIBSUF) $(BINDIR) clean: rm -f *.o *$(SLIBSUF) $(DO_MAKE) distclean: $(DO_MAKE) rm -f config.h config.mak configure.log config.err rm -f *.o *$(SLIBSUF) uninstall: $(DO_MAKE) rm -f $(BINDIR)/*$(SLIBSUF) rmdir -p --ignore-fail-on-non-empty $(BINDIR) dep: depend depend: $(CC) -MM $(CFLAGS) $(SRCS) 1>.depend # # include dependency files if they exist # ifneq ($(wildcard .depend),) include .depend endif