X86_64-pc-linux-gnu-g++: error: unrecognized command-line option '-Wthread-safety'

I’ve been encountering this build fail and same errors for a couple days now. Build will fail on my Gentoo machine. Logs linked since new users cant upload attachments.

build.log:
https://bugs.llvm.org/attachment.cgi?id=25064

CMakeError.log:
https://bugs.llvm.org/attachment.cgi?id=25065

Third log attached since new users cant have more than two links in a post.

CMakeOutput.log:
https://bugs.llvm.org/attachment.cgi?id=25066

It appears this is fixed. Im not sure if it was patched upstream, or if it was because I just upgraded to GCC 11.2, but llvm 13.0.0.9999 is now building. Thank you guys.