gnulib-tool.py: Follow gnulib-tool changes, part 45, 46.

2024-03-06 Thread Collin Funk
Hi, here is two patches. The first implements the '--tests-makefile-name' options. Are there any packages that use this option? I couldn't seem to find anything from Debian and GitHub code search outside of Gnulib itself or mirrors. I ended up figuring it out from the manual description

Re: Does gnulib getcwd always allocate if buf is NULL?

2024-03-06 Thread Reuben Thomas
On Wed, 6 Mar 2024 at 21:45, Bruno Haible wrote: > > There's no need to change this comment, because the primary places to look > for a function's behaviour are: > 1. the documentation and standard documents, > 2. the .h file (in this case: unistd.in.h line 1121). > Fair enough that there

Re: Does gnulib getcwd always allocate if buf is NULL?

2024-03-06 Thread Bruno Haible
Reuben Thomas wrote: > > > > In GNU, if BUF is NULL, an array is allocated with 'malloc'; the array > > > > is > > > > SIZE bytes long, unless SIZE == 0, in which case it is as big as > > > > necessary. > ... > Would this comment be better if "In GNU," was deleted? The comment implies > that the

Re: Does gnulib getcwd always allocate if buf is NULL?

2024-03-06 Thread Reuben Thomas
On Wed, 6 Mar 2024 at 20:12, Bruno Haible wrote: > Reuben Thomas wrote: > > In getcwd.c I find the following comment: > > The Gnulib documentation > https://www.gnu.org/software/gnulib/manual/html_node/getcwd.html > points to the specification. That's usually a more solid reference than > a

Re: Does gnulib getcwd always allocate if buf is NULL?

2024-03-06 Thread Reuben Thomas
On Wed, 6 Mar 2024 at 20:09, Paul Smith wrote: > On Wed, 2024-03-06 at 19:55 +0100, Reuben Thomas wrote: > > In getcwd.c I find the following comment: > > > > > In GNU, if BUF is NULL, an array is allocated with 'malloc'; the > > > array is SIZE bytes long, unless SIZE == 0, in which case it is

Re: Does gnulib getcwd always allocate if buf is NULL?

2024-03-06 Thread Bruno Haible
Reuben Thomas wrote: > In getcwd.c I find the following comment: The Gnulib documentation https://www.gnu.org/software/gnulib/manual/html_node/getcwd.html points to the specification. That's usually a more solid reference than a comment in the code. > In GNU, if BUF is NULL, an array is

Re: Does gnulib getcwd always allocate if buf is NULL?

2024-03-06 Thread Paul Smith
On Wed, 2024-03-06 at 19:55 +0100, Reuben Thomas wrote: > In getcwd.c I find the following comment: > > > In GNU, if BUF is NULL, an array is allocated with 'malloc'; the > > array is SIZE bytes long, unless SIZE == 0, in which case it is as > > big as necessary. > > However, as far as I can see

Does gnulib getcwd always allocate if buf is NULL?

2024-03-06 Thread Reuben Thomas
In getcwd.c I find the following comment: In GNU, if BUF is NULL, an array is allocated with 'malloc'; the array is > SIZE bytes long, unless SIZE == 0, in which case it is as big as necessary. > However, as far as I can see from the code, it always allocates if BUF is NULL. I assume this is

Re: Could `gnulib-tool` check for gjoin?

2024-03-06 Thread Reuben Thomas
On Wed, 6 Mar 2024 at 17:07, Bruno Haible wrote: > Reuben Thomas wrote: > > > Such info could be added to the Gnulib manual. > > > > I doubt that would help many users (why should they read the gnulib > manual > > just to build software?) > > OK. In the name of having gnulib-tool run

Re: Could `gnulib-tool` check for gjoin?

2024-03-06 Thread Bruno Haible
Reuben Thomas wrote: > > Such info could be added to the Gnulib manual. > > I doubt that would help many users (why should they read the gnulib manual > just to build software?) OK. In the name of having gnulib-tool run out-of-the-box for such users, I'm applying this change: 2024-03-06 Bruno

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Collin Funk
Hi Bruno, On 3/6/24 3:22 AM, Bruno Haible wrote: > Thanks, applied. (With an extra newline, just to make it clear that the > %s/%s/%s.%s arguments are the same in all three cases. Could be simplified > in the future, but that's not a priority now.) I assumed the intent of the original code was

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Bruno Haible
Hi Collin, > While running that I noticed this in gltests/Makefile.am: > > -LDADD = ../gllib/libgnu.a libtests.a ../gllib/libgnu.a > +LDADD = ../gllib/libgnu.a > > I've copied the logic for this from gnulib-tool and the attached patch > fixes this. Thanks, applied. (With an extra newline, just

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Bruno Haible
Collin Funk wrote: > These two patches add the notice banners when running 'make all' and > 'make check'. Thanks! Applied. Bruno

Re: gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Collin Funk
On 3/6/24 12:26 AM, Collin Funk wrote: > gnulib-tool.py --create-testdir --dir test-python readme-release > gnulib-tool --create-testdir --dir test-shell readme-release > git diff --no-index test-python/gltests/Makefile.am > test-shell/gltests/Makefile.am While running that I noticed this in

Re: gnulib-tool.py: Follow gnulib-tool changes, part 42.

2024-03-06 Thread Bruno Haible
Collin Funk wrote: > Here is two patches. The first fixes on item in gnulib-tool.py.TODO. Thanks. Applied. Since I misunderstood the 'gentests' description when I read it, I'm clarifying it. > I thought I remembered seeing a good test case for this on the mailing > list but the archives seem to

gnulib-tool.py: Follow gnulib-tool changes, part 43, 44.

2024-03-06 Thread Collin Funk
These two patches add the notice banners when running 'make all' and 'make check'. I'm hoping to get around to implementing the substitutions needed for header files soon. Until then this can be used to build a package that will configure for testing: gnulib-tool.py --create-testdir --dir