#1133643 tcc: ftbfs with GCC-16

Package:
src:tcc
Source:
src:tcc
Submitter:
Emanuele Rocca
Date:
2026-04-21 17:43:02 UTC
Severity:
normal
Tags:
#1133643#5
Date:
2026-04-13 13:11:37 UTC
From:
To:
Hi,

tcc fails to build in a test rebuild on at least amd64 and arm64 with
gcc-16/g++-16, but builds properly with gcc-15/g++-15. The severity of this
report will be raised before the forky release.

The full build log can be found at:
https://people.debian.org/~ema/gcc-16-rebuilds/output-1/tcc_arm64.build.xz

The last lines of the build log are at the end of this report.

To build with GCC 16, either set CC=gcc-16 CXX=g++-16 explicitly,
or install the gcc, g++, gfortran, ... packages from experimental.

  apt-get -t=experimental install g++

Common build failures include unused (but set) variables, array subscripts
partly outside array bounds, and new/dropped symbols in Debian symbols files.
For other C/C++ related build failures see the porting guide at
http://gcc.gnu.org/gcc-16/porting_to.html

Please only close this issue after double-checking that the package can be
built correctly with GCC 16.

Please do not reassign this bug to another package. If a fix in another package
is required, then file a bug for the other package (or clone), and mark this
bug as blocked by the bug in the other package.

[...]


dh_auto_build
	make -j128
make[2]: Entering directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a'
gcc -o tcc.o -c tcc.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o libtcc.o -c libtcc.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o tccpp.o -c tccpp.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o tccgen.o -c tccgen.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o tccelf.o -c tccelf.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o tccasm.o -c tccasm.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o tccrun.o -c tccrun.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o arm64-gen.o -c arm64-gen.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o arm64-link.o -c arm64-link.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
gcc -o arm-asm.o -c arm-asm.c -DCONFIG_TRIPLET="\"aarch64-linux-gnu\"" -DTCC_TARGET_ARM64       -DONE_SOURCE=0 -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -mbranch-protection=standard -Wdeclaration-after-statement -fno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-format-truncation -I. -Wdate-time -D_FORTIFY_SOURCE=2
perl ./texi2pod.pl tcc-doc.texi tcc-doc.pod
makeinfo --no-split --html --number-sections -o tcc-doc.html tcc-doc.texi
makeinfo tcc-doc.texi || true
pod2man --section=1 --center="Tiny C Compiler" --release="0.9.27" tcc-doc.pod >tcc.1 && rm -f tcc-doc.pod
tcc-doc.texi:25: warning: no htmlxref.cnf entry found for `dir'
ar rcs libtcc.a libtcc.o tccpp.o tccgen.o tccelf.o tccasm.o tccrun.o arm64-gen.o arm64-link.o arm-asm.o
gcc -o tcc tcc.o libtcc.a -lm -lpthread -ldl -Wl,-z,relro -Wl,-z,now -s
make[3]: Entering directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a/lib'
../tcc -c lib-arm64.c -o lib-arm64.o -B.. -I..
../tcc -c fetch_and_add_arm64.S -o fetch_and_add_arm64.o -B.. -I..
../tcc -c dsohandle.c -o dsohandle.o -B.. -I..
../tcc -c bt-exe.c -o ../bt-exe.o -B.. -I..
../tcc -c bt-log.c -o ../bt-log.o -B.. -I..
../tcc -c bcheck.c -o ../bcheck.o -B.. -I.. -g
../tcc -ar rcs ../libtcc1.a lib-arm64.o fetch_and_add_arm64.o dsohandle.o
make[3]: Leaving directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a/lib'
make[2]: Leaving directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a'
make[1]: Leaving directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a'
   debian/rules override_dh_auto_test
make[1]: Entering directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a'
dh_auto_test --no-parallel
	make -j1 test TESTSUITEFLAGS="-j1 --verbose" VERBOSE=1
make[2]: Entering directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a'
make[3]: Entering directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a/tests'
------------ hello-exe ------------
Hello World
------------ hello-run ------------
Hello World
------------ libtest ------------
Hello World!
fib(32) = 2178309
add(32, 64) = 96
------------ libtest_mt ------------
running fib with mixed calls
  1 2 3 5 8 13 21 34 55 89 144 233 377 610 987 1597 2584 4181 6765 10946
 (9 ms)
running fib in threads
  1 2 1597 6765 8 13 21 34 89 144 55 233 377 610 3 4181 2584 10946 987 5
 (18 ms)
running tcc.c in threads to run fib
 1 3 2 5 8 13 21 34 55 89 144 377 610 987 1597 2584 4181 6765 10946 233
 (907 ms)
compiling tcc.c 10 times
 (350 ms)
tcctest.c:1647:1: error: braces around scalar initializer
 1647 | int sinit3[3] = { 1, 2, {{3}}, };
      | ^~~
tcctest.c:1647:1: note: (near initialization for ‘sinit3[2]’)
make[4]: *** [Makefile:121: test.ref] Error 1
make[3]: *** [Makefile:95: all] Error 2
make[3]: Leaving directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a/tests'
make[2]: *** [Makefile:393: test] Error 2
make[2]: Leaving directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a'
dh_auto_test: error: make -j1 test TESTSUITEFLAGS="-j1 --verbose" VERBOSE=1 returned exit code 2
make[1]: *** [debian/rules:38: override_dh_auto_test] Error 25
make[1]: Leaving directory '/build/reproducible-path/tcc-0.9.27+git20200814.62c30a4a'
make: *** [debian/rules:52: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess failed with exit status 2

#1133643#10
Date:
2026-04-21 17:40:42 UTC
From:
To:
tags 1133643 + patch
user debian-release@lists.debian.org
usertags 1133643 + bsp-2026-04-br-campinas
thanks

Hi,

Here's a proposed fix for the FTBFS.  Upstream has already fixed it so
this is just a backport.

Thanks,