您的位置:首页 > 产品设计 > UI/UE

MSBuild could not create or connect to a task host with runtime "CLR2" and architecture "x86".

2014-04-15 15:33 651 查看
vs2010 and vs2012 are installed on target machine.

Build c# project using vs2010, following error occurred:

ERROR message :

error MSB4216: Could not run the "GenerateResource" task because MSBuild could not create or connect to a task host with runtime "CLR2" and architecture "x86". Please ensure that (1) the requested runtime and/or architecture are available on the machine, and (2) that the required executable "C:\Program Files\Microsoft SDKs\Windows\v8.0A\bin\NETFX 4.0 Tools\MSBuildTaskHost.exe" exists and can be run.

Solution:

Set environment variables:

DisableOutOfProcTaskHost=true

____________________

Following solution is provided by Forrest Guo.

Following content is only used for knowledge sharing. ^^

This is a known issue which supposed to be fixed in later release. The MSBuildTaskHost.exe is introduced by Visual Studio 2012 but not the Windows SDK. This is a new feature in VS 2012 build system, out of process build.

You can disable this feature if VS 2012 is not used in building. Setting environment variable: DISABLEOUTOFPROCTASKHOST=1

Reference: Build is unable to find MSBuildTaskHost.exe
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐