openwrt-pf/tools
Michael Pratt a3830a1589 tools: gnulib: fix build with latest glibc C23 changes
Backport a patch that covers a build problem with latest glibc
being used as the host standard C library during tools build.

The C23 standard changes some functions that used to drop qualifiers
like "const" or "volatile" and are now forced to preserve them
in the return type based on the input type at all times.
Developers of glibc have responded by making these functions
into macros after they are declared with prototypes.
This is not compatible with the way gnulib is written,
so when the functions are redeclared in gnulib,
the preprocessor expands the _function name_ itself
as if it is a macro name, but not fully,
which results in unusual looking build errors,
e.g. the failed processing of keywords that were never written
and have no business being in a prototype, or,
as a keyword that is expected to be there and nearly guarenteed
to work but mysteriously is not working, displayed as:
"error: expected identifier or '(' before _____".

The backport patch introduces and implements a new macro
in order to prevent function names from being interpreted as macros,
by wrapping it in parentheses for C, or simply placing it back for C++
in the first stage of macro expansion which satisfies the goal
of no further expansion taking place during preprocessing.

Add an additional patch for the functions declared
in the fts header, as this bug also applies to them,
however, this was overlooked by upstream gnulib,
likely because the bug is not presenting as an error.

Yet another patch corrects the order between
specifiers and attributes in GCC syntax for header
lib/fts.in.h which can be blamed on an upstream commit.

Specifically, the throw() or noexcept() keywords
must be before attributes at the end of a declaration.
There are two headers, lib/cdefs.h and lib/getopt-ext.h
that already demonstrate the correct order which is very
strictly necessary in the latest version of GCC
when compiling C++ code, and acceptable for C code,
as the "__THROW" macro is simply another attribute in that case.

Added backport patch:
 - 400-c23-qualifier-generic.patch

Added pending patch:
 - 410-unmacro-fts-functions.patch
 - 450-attribute-specifier-order.patch

Ref: 80e5de158316 ("fts: Improve GCC 11 allocation-deallocation checking.") # gnulib.git
Reported-by: Aditya Nugraha <vortexilation@gmail.com>
Signed-off-by: Michael Pratt <mcpratt@pm.me>
Link: https://github.com/openwrt/openwrt/pull/24247
Signed-off-by: Robert Marko <robimarko@gmail.com>
2026-07-30 19:40:44 +02:00
..
7z tools/7z: update to 25.01 2025-08-17 11:09:46 +02:00
autoconf
autoconf-archive autoconf-archive: backport patch for C++23 support 2025-12-03 20:00:21 +01:00
automake tools: automake: do not error on missing conditional 2026-07-30 19:34:40 +02:00
b43-tools b43-tools: introduce support for rev22 in b43-fwsquash.py 2026-05-28 00:47:45 +02:00
bash tools: bash: fix PKG_HASH 2025-08-11 12:16:18 +02:00
bc tools: bc: update to 1.08.2 2026-06-22 13:01:20 +02:00
bison tools: bison: do not install or uninstall macros 2025-07-30 23:06:30 +02:00
bzip2
cbootimage
cbootimage-configs
ccache tools/ccache: update to 4.13.3 2026-04-20 08:51:04 +02:00
cmake tools/cmake: update to 4.3.4 2026-06-25 23:13:25 +02:00
coreutils tools/coreutils: provide the rmdir utility 2025-07-26 14:38:08 +02:00
cpio
dosfstools treewide: use HTTPS for PKG_SOURCE_URL where possible 2026-04-20 11:58:37 +08:00
dwarves tools/dwarves: update to 1.31 2025-11-22 23:09:51 +01:00
e2fsprogs tools: e2fsprogs: update to version 1.47.4 2026-04-07 01:31:04 +02:00
elftosb treewide: use HTTPS for PKG_SOURCE_URL where possible 2026-04-20 11:58:37 +08:00
elfutils tools/elfutils: enable parallel building 2025-07-26 14:38:09 +02:00
erofs-utils tools/erofs-utils: assign PKG_CPE_ID 2026-03-19 18:05:35 +01:00
expat tools/expat: update to 2.8.2 2026-07-02 16:36:16 +02:00
fakeroot tools/fakeroot: update to 2.1.3 2026-07-11 23:44:48 +02:00
findutils
firmware-utils tools: firmware-utils: update to Git HEAD (2026-07-19) 2026-07-19 21:45:08 +00:00
flex
flock
genext2fs
gengetopt
gmp
gnulib tools: gnulib: fix build with latest glibc C23 changes 2026-07-30 19:40:44 +02:00
include
isl
libdeflate tools/libdeflate: update to 1.25 2025-11-22 23:07:46 +01:00
liblzo treewide: use HTTPS for PKG_SOURCE_URL where possible 2026-04-20 11:58:37 +08:00
libressl treewide: use HTTPS for PKG_SOURCE_URL where possible 2026-04-20 11:58:37 +08:00
libtool tools: libtool: always install all auxillary files 2025-08-11 22:28:41 +02:00
llvm-bpf tools/llvm-bpf: update to 22.1.3 2026-04-18 09:19:29 +02:00
lz4 tools: lz4: update to 1.10.0 2025-08-05 07:01:07 +02:00
lzma
lzma-old
lzop treewide: use HTTPS for PKG_SOURCE_URL where possible 2026-04-20 11:58:37 +08:00
m4 tools: m4: update to 1.4.21 2026-02-13 16:56:37 +01:00
make-ext4fs
meson tools/meson: add pending patch to improve binary reproducibility 2025-10-14 17:13:04 +02:00
missing-macros
mkimage tools/mkimage: update to v2026.07 2026-07-09 13:00:18 +02:00
mklibs
mold mold: Update to 2.41.0 2026-04-28 09:35:53 +02:00
mpc
mpfr treewide: use HTTPS for PKG_SOURCE_URL where possible 2026-04-20 11:58:37 +08:00
mtd-utils tools/mtd-utils: update to v2.3.1 2026-04-16 20:45:40 +02:00
mtools tools: mtools: update to 4.0.49 2025-07-28 00:52:47 +02:00
ninja tools/ninja: update to 1.13.2 2025-11-26 09:37:03 +01:00
padjffs2
patch
patch-image
patchelf
pkgconf tools: pkgconf: update to 2.5.1 2025-07-28 00:57:25 +02:00
quilt tools/quilt: update to 0.69 2025-05-22 18:53:24 +02:00
sdimage
sed
sparse
squashfs3-lzma
squashfs4 tools/squashfs4: update to 4.7.5 2026-03-04 00:44:09 +01:00
sstrip
tar
util-linux tools: util-linux: update to 2.42.2 2026-06-24 02:14:33 +02:00
xxhash tools: xxhash: fix PKG_MIRROR_HASH 2025-10-09 13:37:58 +02:00
xz treewide: use HTTPS for PKG_SOURCE_URL where possible 2026-04-20 11:58:37 +08:00
yafut
zip
zlib tools/zlib: update to 1.3.2 2026-03-14 22:24:13 +01:00
zstd
Makefile tools/util-linux: remove automake dep 2025-11-07 21:18:55 +01:00