From: Bruno Haible Date: Fri, 12 Jan 2024 06:44:59 +0000 (+0100) Subject: qsort_r: Fix compilation error in C++ mode on FreeBSD 14.0/powerpc64. X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=5213b4386ea8b48c1f96f1b7e6aa188115031dd5;p=gnulib.git qsort_r: Fix compilation error in C++ mode on FreeBSD 14.0/powerpc64. * lib/stdlib.in.h (qsort_r): Enable the C++ alias warning only on glibc systems. --- diff --git a/ChangeLog b/ChangeLog index e87670e874..60c338356b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2024-01-12 Bruno Haible + + qsort_r: Fix compilation error in C++ mode on FreeBSD 14.0/powerpc64. + * lib/stdlib.in.h (qsort_r): Enable the C++ alias warning only on glibc + systems. + 2024-01-11 Bruno Haible time: Fix test failure on FreeBSD 12.2/sparc64. diff --git a/lib/stdlib.in.h b/lib/stdlib.in.h index b9838c7d5e..272464e0fc 100644 --- a/lib/stdlib.in.h +++ b/lib/stdlib.in.h @@ -1,6 +1,6 @@ /* A GNU-like . - Copyright (C) 1995, 2001-2004, 2006-2023 Free Software Foundation, Inc. + Copyright (C) 1995, 2001-2004, 2006-2024 Free Software Foundation, Inc. This file is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as @@ -1104,7 +1104,9 @@ _GL_CXXALIAS_SYS (qsort_r, void, (void *base, size_t nmemb, size_t size, _gl_qsort_r_compar_fn compare, void *arg)); # endif +# if __GLIBC__ >= 2 _GL_CXXALIASWARN (qsort_r); +# endif #elif defined GNULIB_POSIXCHECK # undef qsort_r # if HAVE_RAW_DECL_QSORT_R