GNU bug report logs - #73769
[PATCH] automake: distribute local gnulib directory modules

Previous Next

Package: automake-patches;

Reported by: Michael Pratt <mcpratt <at> pm.me>

Date: Sat, 12 Oct 2024 11:35:02 UTC

Severity: normal

Tags: patch

Done: Karl Berry <karl <at> freefriends.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: Karl Berry <karl <at> freefriends.org>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#73769: closed ([PATCH] automake: distribute local gnulib
 directory modules)
Date: Sun, 23 Feb 2025 21:36:03 +0000
[Message part 1 (text/plain, inline)]
Your message dated Sun, 23 Feb 2025 14:34:44 -0700
with message-id <202502232134.51NLYiRx1009244 <at> freefriends.org>
and subject line Re: [bug#73769] [PATCH] automake: distribute local gnulib directory modules
has caused the debbugs.gnu.org bug report #73769,
regarding [PATCH] automake: distribute local gnulib directory modules
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
73769: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=73769
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Michael Pratt <mcpratt <at> pm.me>
To: automake-patches <at> gnu.org
Cc: Michael Pratt <mcpratt <at> pm.me>
Subject: [PATCH] automake: distribute local gnulib directory modules
Date: Sat, 12 Oct 2024 10:29:25 +0000
When gnulib-tool or a bootstrap script uses the option --local-dir,
include the "modules" files in a release with DIST_COMMON. Otherwise,
these source files are present in checkouts but not in distribution.

The resulting gnulib.mk from gnulib-tool has comments
with the options used to generate it:

  # Generated by gnulib-tool.
  # Reproduce by:
  # gnulib-tool --import --local-dir=gl \
  # ...

Regex match and parse this information to get any local directories.

For example, coreutils uses a local gnulib directory "gl"
so am__DIST_COMMON will include "$(top_srcdir)/gl/modules".

* bin/automake.in (read_am_file): push "modules" subdirectory of
  local gnulib directories to dist_common if it exists.

Signed-off-by: Michael Pratt <mcpratt <at> pm.me>
---
 bin/automake.in | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/bin/automake.in b/bin/automake.in
index a17f45236..b757a78e4 100644
--- a/bin/automake.in
+++ b/bin/automake.in
@@ -6520,6 +6520,16 @@ sub read_am_file
 	}
 	elsif (/$COMMENT_PATTERN/o)
 	{
+	    # Distribute local gnulib modules.
+	    if ($amfile =~ /\/gnulib\.mk/o)
+	    {
+		if ($_ =~ /--local-dir=([^\\\s]*)/o)
+		{
+		    push_dist_common ("\$\(top_srcdir\)/$1/modules")
+		      if -d "$1/modules";
+		}
+	    }
+
 	    # Stick comments before the incoming macro or rule.  Make
 	    # sure a blank line precedes the first block of comments.
 	    $spacing = "\n" unless $blank;
-- 
2.30.2




[Message part 3 (message/rfc822, inline)]
From: Karl Berry <karl <at> freefriends.org>
To: mcpratt <at> pm.me
Cc: 73769 <at> debbugs.gnu.org
Subject: Re: [bug#73769] [PATCH] automake: distribute local gnulib directory
 modules
Date: Sun, 23 Feb 2025 14:34:44 -0700
I think there is nothing to do here at this time, so closing.
Feel free to reopen (or open a new issue) if the idea progresses.
Thanks,
karl


This bug report was last modified 180 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.