From: Simon Josefsson Date: Thu, 2 Jan 2025 08:28:48 +0000 (+0100) Subject: maintainer-makefile: Improve gnulib-version handling. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=e7d6a9e033ff82d5bd7f001d6d1a17bd6cc9607c;p=gnulib.git maintainer-makefile: Improve gnulib-version handling. * top/maint.mk (gnulib-version): Prefix commit id with human readable leading ChangeLog date, suggested by Bruno Haible. (announcement): Handle multi-word gnulib-version. --- diff --git a/ChangeLog b/ChangeLog index f3e3f1e784..70bf7a7bb0 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2025-01-02 Simon Josefsson + + maintainer-makefile: Improve gnulib-version handling. + * top/maint.mk (gnulib-version): Prefix commit id with human + readable leading ChangeLog date, suggested by Bruno Haible. + (announcement): Handle multi-word gnulib-version. + 2025-01-01 Bruno Haible doc: Update regarding stable branches. diff --git a/top/maint.mk b/top/maint.mk index af98762e49..78c757d8f1 100644 --- a/top/maint.mk +++ b/top/maint.mk @@ -1516,13 +1516,12 @@ vc-diff-check: rel-files = $(DIST_ARCHIVES) gnulib-version ?= \ - $$(if test -e $(gnulib_dir)/.git; then \ + $$(head -c11 $(gnulib_dir)/ChangeLog; \ + if test -e $(gnulib_dir)/.git; then \ git -C $(gnulib_dir) rev-parse HEAD; \ elif test -f $(srcdir)/bootstrap.conf; then \ perl -lne '/^\s*GNULIB_REVISION=(\S+)/ and $$d=$$1;' \ -e 'END{defined $$d and print $$d}' $(srcdir)/bootstrap.conf; \ - else \ - head -1 $(gnulib_dir)/ChangeLog | sed -e 's/ .*//;q '; \ fi) bootstrap-tools ?= autoconf,automake,gnulib @@ -1578,8 +1577,8 @@ announcement: NEWS ChangeLog $(rel-files) --srcdir=$(srcdir) \ --news=$(srcdir)/NEWS \ --bootstrap-tools=$(bootstrap-tools) \ - $$(case ,$(bootstrap-tools), in (*,gnulib,*) \ - echo --gnulib-version=$(gnulib-version);; esac) \ + "$$(case ,$(bootstrap-tools), in (*,gnulib,*) \ + echo --gnulib-version=$(gnulib-version);; esac)" \ $(addprefix --url-dir=, $(url_dir_list)) \ $(announce_gen_args)