makefile.unix: add simple dist target

Change-Id: I31647a97f5892b2dbdc9f4555ea38e2824ac3788
This commit is contained in:
James Zern 2011-08-25 21:33:28 -04:00
parent 87d58ce9cd
commit c9e037ab3e
2 changed files with 10 additions and 1 deletions

1
.gitignore vendored
View File

@ -8,6 +8,7 @@
/config.* /config.*
/configure /configure
/depcomp /depcomp
/dist
/install-sh /install-sh
/libtool /libtool
/ltmain.sh /ltmain.sh

View File

@ -53,6 +53,7 @@ AR = ar
ARFLAGS = r ARFLAGS = r
CC = gcc -Isrc/ -Iexamples/ -Wall CC = gcc -Isrc/ -Iexamples/ -Wall
CFLAGS = -O3 -DNDEBUG $(EXTRA_FLAGS) CFLAGS = -O3 -DNDEBUG $(EXTRA_FLAGS)
INSTALL = install
LDFLAGS = $(EXTRA_LIBS) -lm LDFLAGS = $(EXTRA_LIBS) -lm
OBJS = src/enc/webpenc.o src/enc/bit_writer.o src/enc/syntax.o \ OBJS = src/enc/webpenc.o src/enc/bit_writer.o src/enc/syntax.o \
@ -84,6 +85,13 @@ examples/dwebp: examples/dwebp.o src/libwebp.a
examples/cwebp examples/dwebp: examples/cwebp examples/dwebp:
$(CC) -o $@ $^ $(LDFLAGS) $(CC) -o $@ $^ $(LDFLAGS)
dist: DESTDIR := dist
dist: all
$(INSTALL) -m755 -d $(DESTDIR)/include/webp $(DESTDIR)/lib
$(INSTALL) -m755 -s examples/cwebp examples/dwebp $(DESTDIR)
$(INSTALL) -m644 src/webp/*.h $(DESTDIR)/include/webp
$(INSTALL) -m644 src/libwebp.a $(DESTDIR)/lib
clean: clean:
$(RM) ${OUTPUT} *~ \ $(RM) ${OUTPUT} *~ \
src/enc/*.o src/enc/*~ \ src/enc/*.o src/enc/*~ \
@ -103,5 +111,5 @@ superclean: clean
$(RM) configure depcomp install-sh ltmain.sh missing src/libwebp.pc $(RM) configure depcomp install-sh ltmain.sh missing src/libwebp.pc
$(RM) m4/* $(RM) m4/*
.PHONY: all clean ex superclean .PHONY: all clean dist ex superclean
.SUFFIXES: .SUFFIXES: