This matches the behavior of cl.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
This matches the behavior of cl.
Are you sure? In a bare environment, cl.exe doesn't include any system paths, not even to the standard library. It actually uses the INCLUDE environment variable for those paths. Granted, VCVARSALL sets that (and other environment variables), but it's not innate behavior of cl.exe.
Right, sorry. I guess what I mean is that this matches the behavior of running from a cl command prompt, which is what we do elsewhere. This is already in the codepath that is trying to build up a consistent WindowsSdk + CRT environment, we were just missing the atlmfc part.
lgtm
I think the old VS Express editions used to exclude atlmfc, so there's the possibility that we'll be searching non-existent directories, but I think that's OK. Whoever wrote this code was probably basing it on what VS express did. That edition is long gone, and we're better off with this new logic.