2 # This Makefile fragment is shared between fileutils, sh-utils, textutils.
5 if head ChangeLog| grep 'Version $(VERSION)' > /dev/null; then \
8 echo "$(VERSION) not in ChangeLog; not tagging" 1>&2; \
14 # Tag before making distribution. Also, don't make a distribution if
15 # checks fail. Also, make sure the NEWS file is up-to-date.
16 cvs-dist: maintainer-check
17 pkg=`echo "$(PACKAGE)" | tr a-z A-Z`; \
18 ver=`echo "$(VERSION)" | sed 's/\./_/g'`; \
21 if cvs -n log -h README| grep -e $$tag > /dev/null; then \
22 echo "VERSION not new; not tagging" 1>&2; \
33 GZIP=$(GZIP) $(TAR) -C $(t) -zxf $(distdir).tar.gz
35 && ./configure --disable-nls \
40 cd $(t) && mv $(distdir) $(distdir).old \
41 && $(TAR) -zxf ../$(distdir).tar.gz
42 diff -ur $(t)/$(distdir).old $(t)/$(distdir)
44 @echo "========================"; \
45 echo "$(distdir).tar.gz is ready for distribution"; \
46 echo "========================"
48 THIS_VERSION_REGEXP = $(subst .,\.,$(VERSION))
49 # FIXME: this works only for Gnits-style test releases.
50 PREV_VERSION := $(shell echo $(VERSION)|tr a-z Xa-y)
51 PREV_VERSION_REGEXP := $(shell echo $(PREV_VERSION)|sed 's/\./\\./g')
53 url-host-prefix = ftp://alpha.gnu.org
54 url = $(url-host-prefix)/gnu/fetish/$(distdir).tar.gz
55 md5 = $(shell md5sum < $(distdir).tar.gz|sed 's/ -//')
58 tarz=/tmp/rel-check-tarz-$$$$; \
59 md5_tmp=/tmp/rel-check-md5-$$$$; \
61 trap 'status=$$?; rm -f $$tarz $$md5_tmp; exit $$status' 0 1 2 3 15; \
62 wget -q --output-document=$$tarz $(url); \
63 echo "$(md5) -" > $$md5_tmp; \
64 md5sum -c $$md5_tmp < $$tarz
66 announcement: NEWS ChangeLog $(distdir).tar.gz
68 echo Subject: $(distdir) released; \
70 echo FIXME: put comments here; \
74 echo "$(md5) $(distdir).tar.gz"; \
77 sed -n "/$(THIS_VERSION_REGEXP)/,/$(PREV_VERSION_REGEXP)/p" NEWS \
80 echo ChangeLog entries:; \
81 sed -n "1,/$v $(PREV_VERSION_REGEXP)/p" \
87 $(MAKE) -s announcement > /tmp/announcement
88 ln $(distdir).tar.gz ../release
89 chmod a-w $(distdir).tar.gz
90 @echo =====================================
91 @echo 'ncftp -u $(url-host-prefix)/fs/share/ftp/gnu/fetish/'
92 @echo '# put $(distdir).tar.gz'
93 @echo '# send the /tmp/announcement e-mail'
94 @echo 'pot-mail $(distdir).tar.gz | bash'
95 @echo =====================================