From 7cd979fbd80e6c99f8267044903fced42d96adbc Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 26 Dec 2010 03:45:21 +0100 Subject: [PATCH] printf-posix: Fix link error when a non-GCC compiler is used. * lib/stdio.in.h (printf): When not using GCC, override printf correctly. Reported by Joachim Schmitz . --- ChangeLog | 7 +++++++ lib/stdio.in.h | 3 +++ 2 files changed, 10 insertions(+) diff --git a/ChangeLog b/ChangeLog index 763cd2e598..26d64d2630 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2010-12-25 Bruno Haible + + printf-posix: Fix link error when a non-GCC compiler is used. + * lib/stdio.in.h (printf): When not using GCC, override printf + correctly. + Reported by Joachim Schmitz . + 2010-12-25 Bruno Haible strerror_r-posix: Update doc. diff --git a/lib/stdio.in.h b/lib/stdio.in.h index 2b84cfe96e..13479b8ce5 100644 --- a/lib/stdio.in.h +++ b/lib/stdio.in.h @@ -676,6 +676,9 @@ _GL_FUNCDECL_RPL_1 (__printf__, int, _GL_ARG_NONNULL ((1))); _GL_CXXALIAS_RPL_1 (printf, __printf__, int, (const char *format, ...)); # else +# if !(defined __cplusplus && defined GNULIB_NAMESPACE) +# define printf rpl_printf +# endif _GL_FUNCDECL_RPL (printf, int, (const char *format, ...) __attribute__ ((__format__ (__printf__, 1, 2))) -- 2.30.2