Need help with Tfs.DevEnv task

Feb 23, 2011 at 6:34 PM

I am trying to get Team Build to build my web setup project. On my build server I have installed the extensionpack version 4.0. I have added the following to my project file:

		<ExtensionTasksPath>$(MSBuildExtensionsPath)\ExtensionPack\4.0\</ExtensionTasksPath>
	<Import Project="$(ExtensionTasksPath)MSBuild.ExtensionPack.tasks" Condition=" '$(BuildingInsideVisualStudio)' != 'true' " />
	<Target Name="AfterCompile" Condition=" '$(BuildingInsideVisualStudio)' != 'true' ">
<MSBuild.ExtensionPack.Tfs.DevEnv TeamFoundationServerUrl="$(TeamFoundationServerUrl)" BuildUri="$(BuildUri)" Solution="$(Solution)" SolutionConfiguration="$(Configuration)" SolutionPlatform="$(Platform)" Target="Build" Version="9" />
<ItemGroup>
<SolutionOutputs Condition=" '%(CompilationOutputs.Solution)' == '$(Solution)' " Include="%(RootDir)%(Directory)**\*.*" />
<SolutionOutputs Include="$(SolutionRoot)\*_setup\$(Configuration)\**\*.*" />
</ItemGroup>
<Copy SourceFiles="@(SolutionOutputs)" DestinationFolder="$(TeamBuildOutDir)" />
</Target>
The build fails with this:
: error MSB4018: The "MSBuild.ExtensionPack.Tfs.DevEnv" task failed unexpectedly.
error MSB4018: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.TeamFoundation.Build.Client, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.
error MSB4018: File name: 'Microsoft.TeamFoundation.Build.Client, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
error MSB4018:    at MSBuild.ExtensionPack.Tfs.DevEnv.Execute()
error MSB4018:    at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
error MSB4018:    at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask, Boolean& taskResult)
The Microsoft.TeamFoundation.Build.Client exists on the build server in the Gac, but it is version 10.0.0.0 instead of version 9.0.0.0 that is being asked for.
How/Where can I tell the DevEnv task to use version 10?
Thanks,
Tony
Feb 23, 2011 at 8:35 PM

Sorry I got this in the wrong place. I will post again in the extension pack project. Please close.