rust-lang/cc-rs

Regression in 1.1.32 in `cc::windows_registry::find_tool`

Closed this issue · 2 comments

Way to reproduce

  1. Windows
  2. Installed Visual Studio 2022 with C++ workload
  3. Attempt to find path to compiler executable using let tool = cc::windows_registry::find_tool("x86_64-msvc", "cl.exe").unwrap();

cc-1.1.31 and older work.
cc-1.1.32 and newer panic because find_tool returns None.

Can both repro on my own machine and on GitHub Actions.

Maybe I am using find_tool the wrong way and need to pass different arguments?

x86_64-msvc is not a valid rust target.

I'd recommend changing it to x86_64-pc-windows-msvc

Thanks, using x86_64-pc-windows-msvc fixed things for me