GNU bug report logs - #51457
grep - fails to compile after following steps in README-hacking

Previous Next

Package: grep;

Reported by: Duncan Roe <duncan_roe <at> optusnet.com.au>

Date: Thu, 28 Oct 2021 08:20:02 UTC

Severity: normal

Done: Paul Eggert <eggert <at> cs.ucla.edu>

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: Paul Eggert <eggert <at> cs.ucla.edu>
Cc: tracker <at> debbugs.gnu.org
Subject: bug#51457: closed (grep - fails to compile after following steps
 in README-hacking)
Date: Wed, 24 Nov 2021 02:42:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Tue, 23 Nov 2021 18:41:12 -0800
with message-id <26006e0c-f969-accd-cbe1-7881f95b46b7 <at> cs.ucla.edu>
and subject line Re: bug#51457: grep - fails to compile after following steps in README-hacking
has caused the debbugs.gnu.org bug report #51457,
regarding grep - fails to compile after following steps in README-hacking
to be marked as done.

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


-- 
51457: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=51457
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Duncan Roe <duncan_roe <at> optusnet.com.au>
To: bug-grep <at> gnu.org
Cc: Duncan Roe <duncan_roe <at> optusnet.com.au>
Subject: grep - fails to compile after following steps in README-hacking
Date: Thu, 28 Oct 2021 18:14:44 +1100
Hi,

I downloaded grep commit f0d97db2. Bypassed export GNULIB_SRCDIR. Did
./bootstrap, git submodule..., git commit...., ./configure and make -j17.

Got this error:
>   CC       dirname-lgpl.o
> In file included from basename-lgpl.c:25:
> ./string.h:624:5: error: token "@" is not valid in preprocessor expressions
>   624 | #if @GNULIB_FREE_POSIX@
Also:
> make[3]: *** Waiting for unfinished jobs....
> In file included from ./localeinfo.h:24,
>                  from localeinfo.c:24:
> ./wchar.h:687:5: error: token "@" is not valid in preprocessor expressions
>   687 | #if @GNULIB_FREE_POSIX@

s/@GNULIB_FREE_POSIX@/1/ in string.h and wchar.h. Now:
>   CC       malloc/dynarray_at_failure.o
> In file included from basename-lgpl.c:25:
> ./string.h:625:7: error: token "@" is not valid in preprocessor expressions
>   625 | # if (@REPLACE_FREE@ && !defined free \
Also:
> In file included from ./localeinfo.h:24,
>                  from localeinfo.c:24:
> ./wchar.h:688:7: error: token "@" is not valid in preprocessor expressions
>   688 | # if (@REPLACE_FREE@ && !defined free \

s/@REPLACE_FREE@/0/ in string.h and wchar.h. Now grep builds.

I went back to the clone and tried ./bootstrap &c. but without updating gnulib.
That builds.

Ran `git bisect` in gnulib. The problem starts with commit a4a2d039:
> Author: Paul Eggert <eggert <at> cs.ucla.edu>
> Date:   Tue Sep 7 17:51:39 2021 -0700
>
>     string, wchar: avoid some namespace pollution
>
>     * lib/string.in.h, lib/wchar.in.h:
>     (free): Declare by hand instead of including stdlib.h.
>     This avoids some namespace pollution.  It should also avoid some
>     nested-include problems described by Lucy Phipps in:
>     https://lists.gnu.org/r/bug-gnulib/2021-09/msg00018.html
>     * modules/string, modules/wchar:
>     (Depends-on): Add stdlib, so that REPLACE_FREE has the right value.
>     (Makefile.am): Replace @REPLACE_FREE@ when creating the include file.

Diffed with previous version but my grasp of autotools is inadequate to figure
out what needs to be done.

Over to you,

Cheers ... Duncan.


[Message part 3 (message/rfc822, inline)]
From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Duncan Roe <duncan_roe <at> optusnet.com.au>
Cc: 51457-done <at> debbugs.gnu.org
Subject: Re: bug#51457: grep - fails to compile after following steps in
 README-hacking
Date: Tue, 23 Nov 2021 18:41:12 -0800
The original bug reported in 51457 seems to have been fixed, so I'm 
closing the bug report.


This bug report was last modified 3 years and 243 days ago.

Previous Next


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