https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107134
--- Comment #1 from Jonathan Wakely <redi at gcc dot gnu.org> --- With current trunk, you need to use -ffreestanding if you are compiling for freestanding. --without-headers --disable-hosted-libstdcxx says to build a freestanding library, that doesn't tell the compiler anything when you invoke it.