From d86d45276ba75eadfab538d40ca10cc1cfa47d2e Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Wed, 21 Aug 2024 23:22:26 +0200 Subject: [PATCH] stdio: Fix compilation error in C++ mode on Linux/riscv64 with musl. * lib/stdio.in.h (fpurge): Disable _GL_CXXALIASWARN invocation on non-glibc systems. --- ChangeLog | 6 ++++++ lib/stdio.in.h | 2 ++ 2 files changed, 8 insertions(+) diff --git a/ChangeLog b/ChangeLog index 5b3996e920..5fdae94326 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2024-08-21 Bruno Haible + + stdio: Fix compilation error in C++ mode on Linux/riscv64 with musl. + * lib/stdio.in.h (fpurge): Disable _GL_CXXALIASWARN invocation on + non-glibc systems. + 2024-08-19 Bruno Haible hasmntopt: Add tests. diff --git a/lib/stdio.in.h b/lib/stdio.in.h index e693fd7d06..67277d5ffe 100644 --- a/lib/stdio.in.h +++ b/lib/stdio.in.h @@ -646,7 +646,9 @@ _GL_FUNCDECL_SYS (fpurge, int, (FILE *gl_stream), _GL_ARG_NONNULL ((1))); # endif _GL_CXXALIAS_SYS (fpurge, int, (FILE *gl_stream)); # endif +# if __GLIBC__ >= 2 _GL_CXXALIASWARN (fpurge); +# endif #elif defined GNULIB_POSIXCHECK # undef fpurge # if HAVE_RAW_DECL_FPURGE -- 2.39.5