How to solve error MSB3721 when DeBug in a ARM64X64 way?

68 views Asked by At

My Environment as follow:

  • Host OS : Macbook Air M1;
  • VM OS: Windows-10-21H2, VS2019,in Parallels Desktop 18
  • VS2019

I have got the following errors, when I DeBug my first UMDF windows driver.

1>------ 已启动全部重新生成: 项目: USBUMDF2Driver1, 配置: Debug ARM64 ------ 1>Building 'USBUMDF2Driver1' with toolset 'WindowsUserModeDriver10.0' and the 'Universal' target platform. 1>Stamping ARM64\Debug\USBUMDF2Driver1.inf 1>Stamping [Version] section with DriverVer=11/21/2023,17.17.0.232 1>Device.c 1>Driver.c 1>Queue.c 1> Building Library C:\Users\hewenyong\source\repos\USBUMDF2Driver1\ARM64\Debug\USBUMDF2Driver1.lib 和对象 C:\Users\hewenyong\source\repos\USBUMDF2Driver1\ARM64\Debug\USBUMDF2Driver1.exp 1>正在生成代码 1>已完成代码的生成 1>USBUMDF2Driver1.vcxproj -> C:\Users\hewenyong\source\repos\USBUMDF2Driver1\ARM64\Debug\USBUMDF2Driver1.dll 1>Done Adding Additional Store 1>Successfully signed: C:\Users\hewenyong\source\repos\USBUMDF2Driver1\ARM64\Debug\USBUMDF2Driver1.dll 1> 1>ApiValidation : error : While Checking file C:\Users\hewenyong\source\repos\USBUMDF2Driver1\ARM64\Debug\USBUMDF2Driver1.dll aitstatic is returned exit code 216. 1>C:\Program Files (x86)\Windows Kits\10\build\WindowsDriver.common.targets(1794,5): error MSB3721: 命令“"C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64\ApiValidator.exe" -DriverPackagePath:C:\Users\hewenyong\source\repos\USBUMDF2Driver1\ARM64\Debug\USBUMDF2Driver1.dll -SupportedApiXmlFiles:"C:\Program Files (x86)\Windows Kits\10\build\universalDDIs\arm64\UniversalDDIs.xml" -ModuleWhiteListXmlFiles:"C:\Program Files (x86)\Windows Kits\10\build\universalDDIs\arm64\ModuleWhiteList.xml" -ApiExtractorExePath:"C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x86"”exited,return code -1. 1>已完成生成项目“USBUMDF2Driver1.vcxproj”的操作 - 失败。

The error lists as following:

`

MSB3721 命令“"C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64\ApiValidator.exe" -DriverPackagePath:C:\Users\hewenyong\source\repos\USBUMDF2Driver1\ARM64\Debug\USBUMDF2Driver1.dll -SupportedApiXmlFiles:"C:\Program Files (x86)\Windows Kits\10\build\universalDDIs\arm64\UniversalDDIs.xml" -ModuleWhiteListXmlFiles:"C:\Program Files (x86)\Windows Kits\10\build\universalDDIs\arm64\ModuleWhiteList.xml" -ApiExtractorExePath:"C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x86"” exited,return code -1. USBUMDF2Driver1 C:\Program Files (x86)\Windows Kits\10\build\WindowsDriver.common.targets 1794
`

I have try change to X86, it work,but I need Arm64 and x64.

Can anyone tell me what is this and how can I solve it?

0

There are 0 answers