1 # Include configuration rules 2 VPATH = $(SRC) 3 include $(MAKEDIR)/com32.mk 4 5 REQFLAGS += -I$(SRC) 6 7 LIBOBJS := $(notdir $(patsubst %.c,%.o,$(wildcard $(SRC)/*.c))) 8 9 BINDIR = /usr/bin 10 LIBDIR = /usr/lib 11 DATADIR = /usr/share 12 AUXDIR = $(DATADIR)/syslinux 13 INCDIR = /usr/include 14 COM32DIR = $(AUXDIR)/com32 15 16 all: libcom32upload.a 17 18 libcom32upload.a : $(LIBOBJS) 19 rm -f $@ 20 $(AR) cq $@ $^ 21 $(RANLIB) $@ 22 23 tidy dist clean: 24 find . \( -name \*.o -o -name \*.a -o -name .\*.d -o -name \*.tmp \) -print0 | \ 25 xargs -0r rm -f 26 27 spotless: clean 28 rm -f *.a 29 rm -f *~ \#* */*~ */\#* 30 31 install: all 32 mkdir -m 755 -p $(INSTALLROOT)$(COM32DIR) 33 install -m 644 libcom32upload.a $(INSTALLROOT)$(COM32DIR) 34 mkdir -p $(INSTALLROOT)$(COM32DIR)/include/ 35 cp -r $(SRC)/*.h $(INSTALLROOT)$(COM32DIR)/include/ 36 37 -include .*.d */.*.d */*/.*.d 38