jeremyd2019 wrote: I rebased this on top of #138783 and adjusted the title and description. Now it should be in a good state to push cmake changes for other projects. https://github.com/llvm/llvm-project/pull/138587