From: Bjarni Ingi Gislason <bjarniig@rhi.hi.is>
To: Paul Eggert <eggert@cs.ucla.edu>
Cc: bug-gnulib@gnu.org
Subject: Re: "rpl_fprintf" not found if compiled with options "-ggdb -Og"
Date: Sun, 1 Aug 2021 01:33:00 +0000 [thread overview]
Message-ID: <20210801013300.GA619758@rhi.hi.is> (raw)
In-Reply-To: <cafbd7a8-e5eb-f3e5-8b69-c0604de4ca22@cs.ucla.edu>
On Sat, Jul 31, 2021 at 01:31:55AM -0700, Paul Eggert wrote:
> On 7/30/21 6:43 PM, Bjarni Ingi Gislason wrote:
> > Actually I am using the current repository of both "groff" and
> > "gnulib".
>
> I can't reproduce the problem that way, either. I'm using Ubuntu 21.04. I
> clone Savannah's latest groff (7ae6d67b7c310c54bb7176c761b1f9719e64201a),
> run this:
>
> ./bootstrap --gnulib-srcdir=$HOME/src/gnu/gnulib-savannah
> ./configure
> make CFLAGS='-ggdb -Og'
>
> and it builds (there are quite a few warnings, which should get fixed, but
> nothing fatal to the build). $HOME/src/gnu/gnulib-savannah contains a copy
> of Savannah's latest Gnulib (commit
> 804ac808a9b17d7ee7cf49f7c713c4a4e4d6423f).
>
> The symptoms you're reporting are that of a partial build that isn't being
> resumed correctly somehow.
>
> By the way, I've not had much luck with -Og. I have better luck with -O0
> when debugging. But then, I mostly debug C code, not C++.
Thanks for testing.
I compile in the directory "groff/build".
I have two branches, my own and master.
The error is in my branch.
It is caused by having simultaneously
CFLAGS='-O...'
and
CPPFLAGS=-D_FORTIFY_SOURCE=2
Changing the value from 2 to 0 or 1, eliminates the error.
My version of glibc is 2.31-13 (Debian, testing).
As Debian uses both '-O2' and "-D_FORTIFY_SOURCE=2" for its
compilation,
a fix seems to be necessary.
###
In the master branch I get, with the default output from "configure",
this
CC src/devices/xditview/gxditview-page.o
In file included from /usr/include/X11/Xos.h:89,
from ../src/devices/xditview/page.c:7:
./lib/unistd.h:663:3: error: #error "Please include config.h first."
663 | #error "Please include config.h first."
| ^~~~~
./lib/unistd.h:665:24: error: expected ';' before 'extern'
665 | _GL_INLINE_HEADER_BEGIN
| ^
| ;
./lib/unistd.h:2815:22: error: expected ';' before 'struct'
2815 | _GL_INLINE_HEADER_END
| ^
| ;
make[1]: *** [Makefile:7219: src/devices/xditview/gxditview-page.o]
Error 1
make[1]: Leaving directory '/home/bg/git/groff/build'
In my branch I have added the missing '#include "config.h"' in
../src/devices/xditview/page.c
and other missing "config.h" lines in other source files.
--
Bjarni I. Gislason
next prev parent reply other threads:[~2021-08-01 1:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-28 20:42 "rpl_fprintf" not found if compiled with options "-ggdb -Og" Bjarni Ingi Gislason
2021-07-28 21:37 ` Paul Eggert
2021-07-31 1:43 ` Bjarni Ingi Gislason
2021-07-31 8:31 ` Paul Eggert
2021-08-01 1:33 ` Bjarni Ingi Gislason [this message]
2021-08-01 2:11 ` Paul Eggert
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://lists.gnu.org/mailman/listinfo/bug-gnulib
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20210801013300.GA619758@rhi.hi.is \
--to=bjarniig@rhi.hi.is \
--cc=bug-gnulib@gnu.org \
--cc=eggert@cs.ucla.edu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).