genwebgallery
annotate Makefile @ 4:83b0adfdd297
renamed CHANGELOG to ChangeLog (file not in repo)
author | meillo@marmaro.de |
---|---|
date | Thu, 22 Nov 2007 23:12:21 +0100 |
parents | abe1e48e0708 |
children | a963f51cfd80 |
rev | line source |
---|---|
meillo@0 | 1 # genwebgallery by meillo@marmaro.de |
meillo@0 | 2 |
meillo@0 | 3 |
meillo@0 | 4 NAME=genwebgallery |
meillo@0 | 5 VERSION = 0.3 |
meillo@0 | 6 NV=${NAME}-${VERSION} |
meillo@2 | 7 |
meillo@4 | 8 DOCS=COPYRIGHT ChangeLog TODO |
meillo@0 | 9 |
meillo@0 | 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@2 | 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@2 | 36 debuild ;\ |
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@2 | 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 |