No. There's existing tooling to get reproducible builds with those compilers, and it's fairly easy to produce output that doesn't include full file paths. Passing relative paths to the compiler is one of the more common ways to use them, and this only leaks relative pathnames which don't reveal information about the system they were compiled on. You can also redact information like __DATE__ quite easily, just by adding e.g. -D__DATE__=\"redacted\" to your command-line. Bazel does this by default because using __DATE__ interferes with reproducible builds. Other projects like Debian have also made efforts to make their builds reproducible. Not 100% of Debian packages are reproducible, but a significant percentage of them are, and using GCC or Clang is not a barrier.
gcc and clang have options to strip paths to support reproducible builds
I just checked my project (multiplatform C++ server for Windows and Linux). Neither has any identifiable info in release build (Linux one is compiled by clang though)
Are you sure?
I can confirm MSVC. Not sure about clang. Although you can disable this. The default release builds, with optimization, leaks: paths, names and symbol names.
"you can disable this" is the critical difference.
I guess, but i would rather it be the case that not only the default but the _only_ config not leak this stuff.