genwebgallery
annotate Makefile @ 19:76f0d56dcf34
better debian/copyright
author | meillo@marmaro.de |
---|---|
date | Sat, 10 May 2008 21:45:23 +0200 |
parents | 6273a788c4fd |
children | 332ea19d9aaf |
rev | line source |
---|---|
meillo@0 | 1 # genwebgallery by meillo@marmaro.de |
meillo@0 | 2 |
meillo@0 | 3 |
meillo@0 | 4 NAME=genwebgallery |
meillo@15 | 5 VERSION = 0.5 |
meillo@0 | 6 NV=${NAME}-${VERSION} |
meillo@2 | 7 |
meillo@4 | 8 DOCS=COPYRIGHT ChangeLog TODO |
meillo@15 | 9 |
meillo@15 | 10 # paths |
meillo@0 | 11 PREFIX = /usr |
meillo@0 | 12 BINDIR = ${PREFIX}/bin |
meillo@0 | 13 MANDIR = ${PREFIX}/share/man |
meillo@0 | 14 |
meillo@0 | 15 all: |
meillo@0 | 16 @echo usage: make [un]install |
meillo@0 | 17 |
meillo@0 | 18 build: |
meillo@0 | 19 @echo build unneeded |
meillo@0 | 20 |
meillo@2 | 21 dist: changelog |
meillo@0 | 22 @mkdir ${NV} |
meillo@2 | 23 @cp -f ${NAME} ${NAME}.1 Makefile ${DOCS} ${NV} |
meillo@0 | 24 @tar -czhof ${NV}.tar.gz ${NV} |
meillo@0 | 25 @rm -rf ${NV} |
meillo@0 | 26 |
meillo@2 | 27 deb: dist |
meillo@2 | 28 @mkdir -p Packages |
meillo@2 | 29 @cp ${NV}.tar.gz Packages/ |
meillo@11 | 30 @( \ |
meillo@2 | 31 cd Packages/ ;\ |
meillo@2 | 32 tar -xzf ${NV}.tar.gz ;\ |
meillo@2 | 33 mv ${NV}.tar.gz ${NAME}_${VERSION}.orig.tar.gz ;\ |
meillo@2 | 34 cd ${NV}/ ;\ |
meillo@2 | 35 cp -r ../../debian/ . ;\ |
meillo@14 | 36 debuild -as ;\ |
meillo@2 | 37 ) |
meillo@2 | 38 |
meillo@2 | 39 changelog: |
meillo@2 | 40 @echo generating changelog from mercurial log |
meillo@4 | 41 @hg log -v --style changelog > ChangeLog |
meillo@2 | 42 |
meillo@0 | 43 install: |
meillo@0 | 44 @echo installing executable file to ${DESTDIR}${BINDIR} |
meillo@0 | 45 @mkdir -p ${DESTDIR}${BINDIR} |
meillo@0 | 46 @cp -f ${NAME} ${DESTDIR}${BINDIR} |
meillo@0 | 47 @chmod 755 ${DESTDIR}${BINDIR}/${NAME} |
meillo@0 | 48 @echo installing manual page to ${DESTDIR}${MANDIR}/man1 |
meillo@0 | 49 @mkdir -p ${DESTDIR}${MANDIR}/man1 |
meillo@0 | 50 @sed 's/VERSION/${VERSION}/g' < ${NAME}.1 > ${DESTDIR}${MANDIR}/man1/${NAME}.1 |
meillo@0 | 51 @chmod 644 ${DESTDIR}${MANDIR}/man1/${NAME}.1 |
meillo@0 | 52 |
meillo@0 | 53 uninstall: |
meillo@0 | 54 @echo removing executable file from ${DESTDIR}${BINDIR} |
meillo@0 | 55 @rm -f ${DESTDIR}${BINDIR}/${NAME} |
meillo@0 | 56 @echo removing manual page from ${DESTDIR}${MANDIR}/man1 |
meillo@0 | 57 @rm -f ${DESTDIR}${MANDIR}/man1/${NAME}.1 |
meillo@0 | 58 |
meillo@0 | 59 clean: |
meillo@0 | 60 @echo clean unneeded |
meillo@0 | 61 |
meillo@0 | 62 distclean: clean |
meillo@5 | 63 @rm -f ${NAME}-*.tar.gz ChangeLog |
meillo@0 | 64 |
meillo@2 | 65 debclean: distclean |
meillo@0 | 66 @cd Packages/${NV}/ ; debuild clean ; |
meillo@0 | 67 |
meillo@0 | 68 |
meillo@2 | 69 .PHONY: all dist deb changelog clean distclean debclean build install uninstall |