Problems with new build server

dexter picture dexter · Jan 21, 2013 · Viewed 8.6k times · Source

After moving my build server I get the following error:

C:\Windows\Microsoft.NET\Framework64\v3.5\Microsoft.Common.targets (1682): Could not run the "GenerateResource" task because MSBuild could not create or connect to a task host with runtime "CLR2" and architecture "x64". Please ensure that (1) the requested runtime and/or architecture are available on the machine, and (2) that the required executable "MSBuildTaskHost.exe" exists and can be run.

My configuration says this:

<ConfigurationToBuild Include="Release|Any CPU">
    <FlavorToBuild>Release</FlavorToBuild>
    <PlatformToBuild>Any CPU</PlatformToBuild>
 </ConfigurationToBuild>

What am I missing?

Answer

Rahul Nikate picture Rahul Nikate · Mar 30, 2015

To resolve this, Go to your .csproj file and open with notepad.

Add the following line under the default property group:

<PropertyGroup>
      <DisableOutOfProcTaskHost>true</DisableOutOfProcTaskHost>
</PropertyGroup>

Project should compile now.