From 0fced72ad1293ce1c5500ec147f6d492dbdfda1b Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Fri, 25 May 2007 18:00:34 +0000 Subject: [PATCH] Makefile: Improve building of Debian packages 2007-05-25 Michael Olson * Makefile (debclean, debprepare, debbuild, debinstall, deb): New way of building Debian packages that preserves the original release tarball and is more modular. (debrevision, debrelease): Remove. git-archimport-id: mwolson@gnu.org--2006/muse--main--1.0--patch-317 --- ChangeLog | 7 +++++++ Makefile | 38 +++++++++++++++++++------------------- 2 files changed, 26 insertions(+), 19 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2561c2c..c985986 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2007-05-25 Michael Olson + + * Makefile (debclean, debprepare, debbuild, debinstall, deb): New + way of building Debian packages that preserves the original + release tarball and is more modular. + (debrevision, debrelease): Remove. + 2007-05-24 Michael Olson * NEWS: Drop vague entries and position interesting entries closer diff --git a/Makefile b/Makefile index adb9f6c..a88d4bf 100644 --- a/Makefile +++ b/Makefile @@ -69,6 +69,19 @@ release: dist gpg --detach $(PROJECT)-$(VERSION).tar.gz && \ gpg --detach $(PROJECT)-$(VERSION).zip) +debclean: + -rm -f ../../dist/$(DISTRIBUTOR)/$(DEBNAME)_* + -rm -fr ../$(DEBNAME)_$(VERSION)* + +debprepare: + -rm -rf ../$(DEBNAME)-$(VERSION) + (cd .. && tar -xzf ../$(PROJECT)-$(VERSION).tar.gz) + mv ../$(PROJECT)-$(VERSION) ../$(DEBNAME)-$(VERSION) + (cd .. && tar -czf $(DEBNAME)_$(VERSION).orig.tar.gz \ + $(DEBNAME)-$(VERSION)) + cp -r debian ../$(DEBNAME)-$(VERSION) + -rm -fr ../$(DEBNAME)-$(VERSION)/debian/.arch-ids + debbuild: (cd ../$(DEBNAME)-$(VERSION) && \ dpkg-buildpackage -v$(LASTUPLOAD) $(BUILDOPTS) \ @@ -76,28 +89,15 @@ debbuild: echo "Running lintian ..." && \ lintian -i ../$(DEBNAME)_$(VERSION)*.deb || : && \ echo "Done running lintian." && \ + echo "Running linda ..." && \ + linda -i ../$(DEBNAME)_$(VERSION)*.deb || : && \ + echo "Done running linda." && \ debsign) - cp ../$(DEBNAME)_$(VERSION)* ../../dist/$(DISTRIBUTOR) - -debclean: - -rm -f ../../dist/$(DISTRIBUTOR)/$(DEBNAME)_* - -rm -fr ../$(DEBNAME)-$(VERSION) -debrevision: debclean dist - -rm -f ../$(DEBNAME)_$(VERSION)-* - mv ../$(PROJECT)-$(VERSION) ../$(DEBNAME)-$(VERSION) - cp -r debian ../$(DEBNAME)-$(VERSION) - -rm -fr ../$(DEBNAME)-$(VERSION)/debian/.arch-ids - $(MAKE) debbuild +debinstall: + cp ../$(DEBNAME)_$(VERSION)* ../../dist/$(DISTRIBUTOR) -debrelease: debclean dist - -rm -f ../$(DEBNAME)_$(VERSION)* - mv ../$(PROJECT)-$(VERSION) ../$(DEBNAME)-$(VERSION) - (cd .. && tar -czf $(DEBNAME)_$(VERSION).orig.tar.gz \ - $(DEBNAME)-$(VERSION)) - cp -r debian ../$(DEBNAME)-$(VERSION) - -rm -fr ../$(DEBNAME)-$(VERSION)/debian/.arch-ids - $(MAKE) debbuild +deb: debclean debprepare debbuild debinstall upload: release (cd .. && \ -- 2.11.4.GIT