cc-rs icon indicating copy to clipboard operation
cc-rs copied to clipboard

Add support for ARM64EC when building with MSVC

Open dpaoliello opened this issue 1 year ago • 0 comments

  • Building for ARM64EC requires passing the -arm64EC flag to cl.exe and /machine:arm64ec to lib.exe: https://learn.microsoft.com/en-us/windows/arm/arm64ec-build#developer-command-prompt
  • Updated tool discovery to handle arm64ec as a target arch by using the aarch64 paths.
  • When targeting arm64ec the lib path must ALSO include the arm64ec VC libs BEFORE the aarch64 libs.
  • Added a new TargetArch wrapper type to avoid splitting the target string multiple times or calling contains when we could be using string comparison.

dpaoliello avatar Dec 06 '23 19:12 dpaoliello