Skip to content

[CANARY — DO NOT MERGE] gcc 15.2.0 → 16.2.0 world build (pm#1182) - #1340

Draft
bryan-minimal wants to merge 3 commits into
mainfrom
canary/gcc-16.2
Draft

bryan-minimal wants to merge 3 commits into
mainfrom
canary/gcc-16.2

Conversation

@bryan-minimal

@bryan-minimal bryan-minimal commented Nov 5, 2026 •

Copy link
Copy Markdown
Member

Caution

CANARY. DO NOT MERGE, DO NOT APPROVE, NEVER ADD TO THE MERGE QUEUE.
This PR exists only so build-bot runs a full world build with gcc 16.2.0 as the default compiler. It is a draft on purpose and will be closed once the FTBFS list is collected. The real flip will be a separate, human-authored PR queued alone.

Purpose

Step 4 of gominimal/pkgmgr-rs#1182: collect the complete list of packages that fail to build (FTBFS) when the default compiler packages/gcc moves from 15.2.0 to 16.2.0. gcc is in every package's reverse import closure (616/616), so this PR rebuilds the whole world.

What changed

Only packages/gcc/:

  • build.ncl
    • version is now 16.2.0.
    • The source URL is https://mirrors.kernel.org/gnu/gcc/gcc-16.2.0/gcc-16.2.0.tar.xz, sha256 e6738e29597f733270731aa90600f37ffdc045079dfc27ec7e8192cc81085c3e.
  • build.sh
    • The gcc-16.2.0 directory names replace the hardcoded gcc-15.2.0.
    • The libgomp -Wno-error=discarded-qualifiers hatch is dropped (the CFLAGS/CXXFLAGS/*_FOR_TARGET exports and their comment). libgomp/affinity-fmt.c:330 is already const char *q in 16.2.0.
  • Unchanged:
    • The replace_on_cycle seeds (gcc-15.2.0) stay as they are. gcc 16 is compiled once by the 15.2 seed, and gcc 16 needs only a C++14 host.
    • Every configure flag the recipe passes still exists in 16.2.0.
    • The lib64 sed targets in t-linux64 / t-aarch64-linux are still present.

Source verification: the tarball's sha256 is identical from ftp.gnu.org and mirrors.kernel.org. Its gcc-16.2.0.tar.xz.sig verifies against GCC release key 13975A70E63C361C73AE69EF6EEB81F8981C74C7 (Richard Biener) from gnu-keyring.gpg.

  • That key has a DSA1024 primary and SHA-1 binding signatures. Current sq therefore only authenticates it with --policy-as-of 2014-01-01.
  • The signature is genuine, but under today's policy the key is weak. That is worth knowing if data/signing_policies.toml ever covers gcc.

⚠ Mirroring needed before any real flip. Every other gcc source lives at gs://minimal-staging-archives/gcc-%{version}.tar.xz. This canary points at upstream because the tarball could not be uploaded from here. The flip PR must mirror it first and restore the gs:// URL.

Deliberately left alone (track for the flip)

  • stacks/make/stack.ncl still applies -Wno-error=discarded-qualifiers fleet-wide. It is documented as durable because it is about glibc 2.43+ headers, not gcc.
  • The per-package copies of the same flag are also untouched: elfutils, libxcrypt, strace, virtio-linux-detonation (HOSTCFLAGS). This canary should show whether any of them are still needed. A copy is not proven removable just because it still builds with it in place.
  • The known breakers are not pre-fixed, so the canary measures them as they are:

Local sanity build: not done

I couldn't run a local min package build gcc first, so gcc 16.2.0 itself is unproven until this run. Activating a pkgbuild session on this worktree means rebuilding base's closure, because gcc changed. That rebuild needs the bedrock prebuilt seeds (gcc (prebuilt), zlib (prebuilt)) from gs://minimal-staging-archives. minvmd 0.7.3-rc1's node-plane egress baseline drops those connections (dropped a node-plane frame ... toward an address no baseline entry pinned), so session spawn failed with cannot connect to endpoint on storage.googleapis.com.

If the bot fails on gcc itself, it fails early and cheaply, and I'll fix it on this branch.

How results will be triaged

  1. Read the per-package failures from the build-bot run for this head sha and bucket them by the classes in pm#1182:
    • the C++ default moving gnu++17 → gnu++20 (char8_t, keywords, removed allocator members, operator!=)
    • missing transitive includes
    • new -Werror warnings
    • the autoconf AC_PROG_CXX downgrade probe
    • linker (-lgcc_s_asneeded)
    • kernel gcc-plugins
    • ICE / other
  2. Separate real gcc-16 failures from flakes and infra errors (artifact_fetch, timeouts, NAT) by re-checking any failure that has no compiler error.
  3. File the list on pm#1182. Each fix lands as its own small PR against main, using a gcc-16-compatible change (a source patch, a version bump, or a narrowly scoped -Wno-error= / -std= pin) that also builds under 15.2.
  4. Close this PR. The flip PR comes after the fixes land and is queued alone.

FTBFS log (running)

The bot stops an arch's whole run at the first failed package (the minimal orchestrator aborts on the first error and has no keep-going mode), so failures surface one per run. Each fix is one commit on this branch, so it can be cherry-picked into its own PR.

package arch error class fix commit
gcc-arm-none-eabi amd64 gnu++20 char8_t: libcody u8"" into std::string (gcc 14.2.0 source) bump to gcc 16.2.0 (same tarball as packages/gcc) + newlib 4.6.0.20260123 696e1a8
cbmc (pre-emptive, pm#1182) both gcc 16 -Wsfinae-incomplete / -Wunused-but-set-variable / -Warray-bounds under -Werror backport diffblue/cbmc#9024 (merged after 6.11.0, which Kani pins) fd8e41e

🤖 Generated with Claude Code

World-build canary to collect the gcc 16 FTBFS list.

- version 16.2.0; source from mirrors.kernel.org (not yet mirrored to
  gs://minimal-staging-archives). sha256 e6738e29... matches the
  ftp.gnu.org tarball whose .sig verifies against Richard Biener's key
  13975A70E63C361C73AE69EF6EEB81F8981C74C7 from the GNU keyring.
- build.sh: gcc-16.2.0 dir names; drop the libgomp
  -Wno-error=discarded-qualifiers hatch (affinity-fmt.c:330 is
  `const char *q` in 16.2.0).
- replace_on_cycle seeds unchanged (gcc 15.2.0 compiles gcc 16 once).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

bryan-minimal and others added 2 commits November 5, 2026 13:57
…6 FTBFS)

gcc 14.2.0's libcody does `words.emplace_back (u8"")`, which no longer
compiles once the host compiler defaults to C++20 (u8"" is
const char8_t[]). gcc 16.2.0's libcody casts it, so move the cross
compiler to the same gcc release as the native one (latest-version
policy) instead of pinning -std=gnu++17.

- gcc 16.2.0: same tarball/sha256 as packages/gcc (e6738e29..., .sig
  verified against 13975A70E63C361C73AE69EF6EEB81F8981C74C7).
- newlib 4.6.0.20260123: sha256 6ff27e3b...; its sha512 matches
  sourceware.org/pub/newlib/sha512.sum (newlib publishes no signature).
- t-rmprofile is unchanged between 14.2.0 and 16.2.0 except the
  copyright year, so the multilib sed still applies; every newlib
  configure option the recipe passes still exists in 4.6.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
gcc 16 adds -Wsfinae-incomplete and new -Wunused-but-set-variable /
-Warray-bounds diagnostics that cbmc 6.11.0's -Werror build promotes to
errors. Upstream fixed them in #9024 (merge 4b26409c, 2026-10-02), after
6.11.0, which is still the latest release and what Kani 0.68.0 pins, so
carry that PR as a patch until the next release. It applies cleanly to
the 6.11.0 tag (git apply --check) and is behaviour-neutral (warning-path
cleanups and a dead counter), so it also builds under gcc 15.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant