# -*- makefile -*- # $Id$ # # Release (nondistributed) Makefile targets # include ../Makefile.rules REPOSITORY = linux.kernel.org:autofs RELEASE := $(shell cat ../.version) LASTREL := $(shell cat ../.lastrel) PREREL := $(shell cat ../.prerel 2>/dev/null || echo 1) .PHONY: release newrelease reldir: -rm -rf autofs-$(RELEASE) autofs-$(RELEASE).tar.gz mkdir autofs-$(RELEASE) cd ..; cp -R $(SUBDIRS) $(INCDIRS) releases/autofs-$(RELEASE) cd ..; for file in $(INCFILES); do if [ -f $$file ]; then cp -R $$file releases/autofs-$(RELEASE); fi; done $(MAKE) -C autofs-$(RELEASE) distclean find autofs-$(RELEASE) -noleaf \( -name \*norel -o -name CVS \) -print0 | xargs -0 rm -rf release: reldir -rm -f ../.prerel ../.lastrel cp ../.version ../.lastrel tar cvvf - autofs-$(RELEASE) | gzip -9 > autofs-$(RELEASE).tar.gz since: mv -f ../NEWS ../NEWS.old echo 'Since autofs-$(RELEASE):' > ../NEWS echo 'Since autofs-$(RELEASE):' | sed -e 's/./-/g' >> ../NEWS echo '' >> ../NEWS cat ../NEWS.old >> ../NEWS newrelease: since echo `cut -d. -f1-2 < ../.version`.`expr \`cut -d. -f3 < ../.version\` + 1` \ > ../.version $(MAKE) clean newminorrelease: since echo `cut -d. -f1 < ../.version`.`expr \`cut -d. -f2 < ../.version\` + 1`.0 \ > ../.version $(MAKE) clean newmajorrelease: since echo `expr \`cut -d. -f1 < ../.version\` + 1`.0.0 > ../.version $(MAKE) clean # Note: "clean" includes autoconf stuff clean: make -C .. clean upload: release scp autofs-$(RELEASE).tar.gz $(REPOSITORY) patch: reldir -rm -rf autofs-$(RELEASE)-pre$(PREREL)* mv autofs-$(RELEASE) autofs-$(RELEASE)-pre$(PREREL) diff -urN autofs-$(LASTREL) autofs-$(RELEASE)-pre$(PREREL) > \ autofs-$(RELEASE)-pre$(PREREL).patch || exit `expr $$? - 1` gzip -9 autofs-$(RELEASE)-pre$(PREREL).patch prerel: patch scp autofs-$(RELEASE)-pre$(PREREL).patch.gz $(REPOSITORY)/testing expr $(PREREL) + 1 > ../.prerel