简体   繁体   English

msbuild.exe突然冻结

[英]msbuild.exe suddenly freezes

I'm having issues when building a C# project with msbuild.exe, it freezes. 使用msbuild.exe构建C#项目时遇到问题,它冻结了。 Looking at the msbuild.exe process in Process Explorer, I get something like this: 在Process Explorer中查看msbuild.exe进程,我得到如下信息:

MSBuild.exe
    |
    +--csc.exe
          |
          +--cvtres.exe

It's very weird as it's not constantly reproducible but when it does, it's always at cvtres.exe. 这很奇怪,因为它不总是可重复生成,但是当它可以复制时,它始终位于cvtres.exe。 If I kill cvtres.exe, it gives me a message saying 如果我杀死cvtres.exe,它会给我一条消息,说

'[PROJECT_PATH]\obj\Release\[TEMP_FILE_NAME].tmp' is not a valid Win32 resource file

Has anyone experienced this issue? 有人遇到过这个问题吗?

I believe cvtres is used to compile your resource files. 我相信cvtres用于编译您的资源文件。 Maybe you have a lot of resources, or the resources being compiled are large or invalid? 也许您有很多资源,或者正在编译的资源很大或无效?

Found this out. 发现了这一点。 It was because I had an old version of Visual Studio (namely 2003) installed. 这是因为我安装了旧版本的Visual Studio(即2003)。 It adds environment variables "LIB" and "INCLUDE" with values for .NET 1.1 (to your System variables not User!!). 它将具有.NET 1.1值的环境变量“ LIB”和“ INCLUDE”添加到系统变量中,而不是User !!。 Removing them resolved the issue. 删除它们解决了该问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM