Skip to content

Conversation

Be-ing
Copy link
Contributor

@Be-ing Be-ing commented Oct 15, 2025

early work-in-progress

This adds a --toolchain CLI option to the script that can be either
  * gnu
  * llvm
  * chromium-llvm

The gnu and llvm options use the system's toolchain. chromium-llvm
uses Chromium's prebuilt LLVM toolchain with its Debian sysroot.

Previously, the script tried to combine the system's gcc with
libstdc++ from Chromium's Debian sysroot, which failed to find
glibc headers:

[1/4184] CXX obj/third_party/abseil-cpp/absl/base/base/cycleclock.o
FAILED: obj/third_party/abseil-cpp/absl/base/base/cycleclock.o
g++ -MMD -MF obj/third_party/abseil-cpp/absl/base/base/cycleclock.o.d -DUSE_UDEV -DUSE_AURA=1 -DUSE_GLIB=1 -DUSE_OZONE=1 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_NONE -D_GLIBCXX_ASSERTIONS=1 -DCR_SYSROOT_KEY=20250129T203412Z-1 -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DABSL_ALLOCATOR_NOTHROW=1 -I.. -Igen -I../third_party/abseil-cpp -fno-strict-overflow -fno-ident -fno-strict-aliasing -fstack-protector -funwind-tables -fPIC -pipe -pthread -m64 -msse3 -Wno-builtin-macro-redefined -D__DATE__= -D__TIME__= -D__TIMESTAMP__= -O2 -fdata-sections -ffunction-sections -fno-math-errno -fno-omit-frame-pointer -g0 -fvisibility=hidden -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations -Wno-comments -Wno-packed-not-aligned -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -std=gnu++2a -Wno-changes-meaning -fno-exceptions --sysroot=../build/linux/debian_bullseye_amd64-sysroot -fvisibility-inlines-hidden -Wno-narrowing -Wno-class-memaccess -Wno-invalid-offsetof  -c ../third_party/abseil-cpp/absl/base/internal/cycleclock.cc -o obj/third_party/abseil-cpp/absl/base/base/cycleclock.o
In file included from /usr/include/c++/15/bits/version.h:51,
                 from /usr/include/c++/15/atomic:50,
                 from ../third_party/abseil-cpp/absl/base/internal/cycleclock.h:45,
                 from ../third_party/abseil-cpp/absl/base/internal/cycleclock.cc:23:
/usr/include/c++/15/x86_64-redhat-linux/bits/c++config.h:3:10: fatal error: bits/wordsize.h: No such file or directory
    3 | #include <bits/wordsize.h>
      |          ^~~~~~~~~~~~~~~~~
@Be-ing Be-ing marked this pull request as draft October 15, 2025 16:52
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