From 0d6127499bccff444f746719719bb7a46c3f7e15 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 aa25e076b6..469726c6f9 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-17 Bruno Haible lock: Fix pthread-rwlock crashes with clang (regr. 2024-08-07). diff --git a/lib/stdio.in.h b/lib/stdio.in.h index 0fdf762a19..99c9baf831 100644 --- a/lib/stdio.in.h +++ b/lib/stdio.in.h @@ -603,7 +603,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