git-tag: Make gnustep-make git-tag'gable and git-dist'able.

This adds support for git-tag and git-dist into GNUmakefile.in for
gnustep-make itself.
This commit is contained in:
Ivan Vučica 2017-12-07 21:39:12 +00:00
parent 720df0d7cf
commit 50afbfa898
No known key found for this signature in database
GPG key ID: 6E4D7BA2D93CAC9D
2 changed files with 45 additions and 0 deletions

View file

@ -2,6 +2,8 @@
* Master/source-distribution.make: Allow creating a Git tag and
creating a tarball from a git tag.
* GNUmakefile.in: Allow creating a Git tag and creating a tarball
from a Git tag, for releasing gnustep-make itself.
2017-04-14 Richard Frith-Macdonald <rfm@gnu.org>

View file

@ -418,6 +418,49 @@ cvs-snapshot:
tar --gzip -cf gnustep-make-$(GNUSTEP_MAKE_VERSION).tar.gz gnustep-make-$(GNUSTEP_MAKE_VERSION)
rm -rf gnustep-make-$(GNUSTEP_MAKE_VERSION)
ifeq ($(GIT_TAG_SIGN), )
GIT_TAG_ANNOTATION_FLAGS = -a
else
ifeq ($(GIT_TAG_SIGN), yes)
GIT_TAG_ANNOTATION_FLAGS = -s
else
GIT_TAG_ANNOTATION_FLAGS = -u $(GIT_TAG_SIGN)
endif
endif
git-tag-stable:
echo "*Error* tagging stable branch in Git is not supported at this time." && exit 1
ifeq ($(GIT_TAG_ANNOUNCE_FILE),)
git-tag:
git tag \
$(GIT_TAG_ANNOTATION_FLAGS) \
make-$(VERTAG) \
-m "Release $(GNUSTEP_MAKE_VERSION)."
else
ifneq ($(GIT_TAG_ANNOUNCE_OMIT_PREFACE),yes)
.INTERMEDIATE += git-tag-announce-file.tmp
git-tag-announce-file.tmp:
printf "Release $(GNUSTEP_MAKE_VERSION).\n\n" > git-tag-announce-file.tmp
cat $(GIT_TAG_ANNOUNCE_FILE) >> git-tag-announce-file.tmp
git-tag: git-tag-announce-file.tmp
git tag \
$(GIT_TAG_ANNOTATION_FLAGS) \
make-$(VERTAG) \
-F git-tag-announce-file.tmp
else
git-tag:
git tag \
$(GIT_TAG_ANNOTATION_FLAGS) \
make-$(VERTAG) \
-F $(GIT_TAG_ANNOUNCE_FILE)
endif
endif
git-dist:
git archive --format=tar.gz make-$(VERTAG) -o gnustep-make-$(GNUSTEP_MAKE_VERSION).tar.gz --prefix=gnustep-make-$(GNUSTEP_MAKE_VERSION)/
test-RPM_TOPDIR:
@(if [ -z "$(RPM_TOPDIR)" ]; then \
echo "Error - RPM_TOPDIR variable not set."; \