bug-gnulib@gnu.org mirror (unofficial)
 help / color / mirror / Atom feed
* "rpl_fprintf" not found if compiled with options "-ggdb -Og"
@ 2021-07-28 20:42 Bjarni Ingi Gislason
  2021-07-28 21:37 ` Paul Eggert
  0 siblings, 1 reply; 6+ messages in thread
From: Bjarni Ingi Gislason @ 2021-07-28 20:42 UTC (permalink / raw)
  To: bug-gnulib

Software: groff
  and
gcc (Debian 10.2.1-6) 10.2.1 20210110
Copyright (C) 2020 Free Software Foundation, Inc.


Error:

  CCLD     gxditview
/usr/bin/ld: src/devices/xditview/gxditview-device.o: in function `open_device_file':
/home/bg/git/groff/build/../src/devices/xditview/device.c:535: undefined reference to `rpl_fprintf'
/usr/bin/ld: src/devices/xditview/gxditview-device.o: in function `error':
/home/bg/git/groff/build/../src/devices/xditview/device.c:546: undefined reference to `rpl_fprintf'
/usr/bin/ld: /home/bg/git/groff/build/../src/devices/xditview/device.c:548: undefined reference to `rpl_fprintf'
collect2: error: ld returned 1 exit status
make[1]: *** [Makefile:6472: gxditview] Error 1


Code in groff:

535       fprintf(stderr, "can't find device file '%s'\n", file_name);

546		fprintf(stderr, "%s:", current_filename);

Defined GNULIB* containing "FPRINTF" in Makefile:

GL_GNULIB_FPRINTF = 1
GL_GNULIB_FPRINTF_POSIX = 1
GL_GNULIB_VFPRINTF = 1
GL_GNULIB_VFPRINTF_POSIX = 0
REPLACE_FPRINTF = 1
REPLACE_VFPRINTF = 0

Code in gnulib/lib/stdio.in.h (groff/gnulib/stdio.in.h):

#if @GNULIB_FPRINTF_POSIX@ || @GNULIB_FPRINTF@
# if (@GNULIB_FPRINTF_POSIX@ && @REPLACE_FPRINTF@) \
     || (@GNULIB_FPRINTF@ && @REPLACE_STDIO_WRITE_FUNCS@ && (@GNULIB_STDIO_H_NONBLOCKING@ || @GNULIB_STDIO_H_SIGPIPE@))
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
#   define fprintf rpl_fprintf
#  endif
#  define GNULIB_overrides_fprintf 1
#  if @GNULIB_FPRINTF_POSIX@ || @GNULIB_VFPRINTF_POSIX@
_GL_FUNCDECL_RPL (fprintf, int,
                  (FILE *restrict fp, const char *restrict format, ...)
                  _GL_ATTRIBUTE_FORMAT_PRINTF_STANDARD (2, 3)
                  _GL_ARG_NONNULL ((1, 2)));
#  else
_GL_FUNCDECL_RPL (fprintf, int,
                  (FILE *restrict fp, const char *restrict format, ...)
                  _GL_ATTRIBUTE_FORMAT_PRINTF_SYSTEM (2, 3)
                  _GL_ARG_NONNULL ((1, 2)));
#  endif
_GL_CXXALIAS_RPL (fprintf, int,
                  (FILE *restrict fp, const char *restrict format, ...));
# else
_GL_CXXALIAS_SYS (fprintf, int,
                  (FILE *restrict fp, const char *restrict format, ...));
# endif


-- 
Bjarni I. Gislason


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-08-01  2:11 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
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
2021-08-01  2:11         ` Paul Eggert

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).