Michael Pratt wrote:
> adding the "gl" directory from source to EXTRA_DIST or however 
> you all would do it

I agree with the suggestion: In GNU gettext, I have a couple of
local gnulib modules as well, and since gnulib-tool takes them as
input, I view them as source code. Since the GCS [1] say that the
tarball should contain the source code, I bundle them in the tarball.

Pádraig Brady replied:
> then we'd have two copies of these files in the release tarball.

Yes, but so what?
1. File size is cheap nowadays. Disks are large, and download speeds ≥
   1 MB/sec are very common.
2. With block-based compression, like .bz2 and .xz, the second copy does
   hardly cost any size, since it is identical to the first copy.

Michael Pratt wrote:
> What's needed is just the "modules" files which are missing

No, the gl/lib/ and gl/tests/ subdirectories are input to gnulib-tool as well.
Not only gl/modules/.

And you should list the *files* to add to the tarball, not directories.
See [2] or [3], point 3.

So, what I would propose is the attached patch.

Bruno

[1] https://www.gnu.org/prep/standards/html_node/Managing-Releases.html
[2] 
https://www.gnu.org/software/automake/manual/html_node/Basics-of-Distribution.html
[3] https://lists.gnu.org/archive/html/automake-patches/2024-10/msg00003.html
From: Bruno Haible <br...@clisp.org>

build: Distribute the gl/ directory in the tarballs.

Suggested by Michael Pratt in
<https://mail.gnu.org/archive/html/coreutils/2024-10/msg00010.html>.

* gl/local.mk: New file, based on gettext/gnulib-local/Makefile.am.
* Makefile.am: Include it.

diff --git a/Makefile.am b/Makefile.am
index d17353e1c..a59df7e79 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -208,6 +208,7 @@ MOSTLYCLEANDIRS =
 
 AM_CPPFLAGS = -Ilib -I$(top_srcdir)/lib -Isrc -I$(top_srcdir)/src
 
+include $(top_srcdir)/gl/local.mk
 include $(top_srcdir)/lib/local.mk
 include $(top_srcdir)/src/local.mk
 include $(top_srcdir)/doc/local.mk
diff --git a/gl/local.mk b/gl/local.mk
new file mode 100644
index 000000000..85b8e2b9e
--- /dev/null
+++ b/gl/local.mk
@@ -0,0 +1,80 @@
+# Make coreutils programs.                             -*-Makefile-*-
+# This is included by the top-level Makefile.am.
+
+## Copyright (C) 2006-2024 Free Software Foundation, Inc.
+
+## This program is free software: you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 3 of the License, or
+## (at your option) any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+## GNU General Public License for more details.
+##
+## You should have received a copy of the GNU General Public License
+## along with this program.  If not, see <https://www.gnu.org/licenses/>.
+
+# Generate this list with
+# find gl '(' -name Makefile.am ')' -prune -o -type f '!' '(' -name '*.orig' -or -name '*~' -or -name 'ChangeLog.*' ')' -printf '%p\n' | sort | tr '\012' @ | sed 's/@$/%/;s/@/ \\@/g' | tr @% '\012\012'
+EXTRA_DIST += \
+gl/lib/buffer-lcm.c \
+gl/lib/buffer-lcm.h \
+gl/lib/cl-strtod.c \
+gl/lib/cl-strtod.h \
+gl/lib/cl-strtold.c \
+gl/lib/fadvise.c \
+gl/lib/fadvise.h \
+gl/lib/fd-reopen.c \
+gl/lib/fd-reopen.h \
+gl/lib/heap.c \
+gl/lib/heap.h \
+gl/lib/randint.c \
+gl/lib/randint.h \
+gl/lib/rand-isaac.c \
+gl/lib/rand-isaac.h \
+gl/lib/randperm.c \
+gl/lib/randperm.h \
+gl/lib/randread.c \
+gl/lib/randread.h \
+gl/lib/root-dev-ino.c \
+gl/lib/root-dev-ino.h \
+gl/lib/skipchars.c \
+gl/lib/skipchars.h \
+gl/lib/smack.h \
+gl/lib/strintcmp.c \
+gl/lib/strnumcmp.c \
+gl/lib/strnumcmp.h \
+gl/lib/strnumcmp-in.h \
+gl/lib/targetdir.c \
+gl/lib/targetdir.h \
+gl/lib/xdectoimax.c \
+gl/lib/xdectoint.c \
+gl/lib/xdectoint.h \
+gl/lib/xdectoumax.c \
+gl/lib/xfts.c \
+gl/lib/xfts.h \
+gl/local.mk \
+gl/modules/buffer-lcm \
+gl/modules/cl-strtod \
+gl/modules/cl-strtold \
+gl/modules/fadvise \
+gl/modules/fadvise-tests \
+gl/modules/fd-reopen \
+gl/modules/heap \
+gl/modules/link-tests.diff \
+gl/modules/randint \
+gl/modules/randperm \
+gl/modules/randread \
+gl/modules/randread-tests \
+gl/modules/rename-tests.diff \
+gl/modules/root-dev-ino \
+gl/modules/skipchars \
+gl/modules/smack \
+gl/modules/strnumcmp \
+gl/modules/targetdir \
+gl/modules/xdectoint \
+gl/modules/xfts \
+gl/tests/test-fadvise.c \
+gl/tests/test-rand-isaac.c

Reply via email to