views:

66

answers:

1

Hi,

When building a CLR Storedprocedure Project using MSBuild on our build server (Team City) we're getting the following error:

error MSB4019: The imported project "C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\SqlServer.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk

I've checked to see if the file exists on disk and sure enough it doesn't. I've checked on my own machine and it does exist.

I don't really want to start copying over files manually to the build server.

Here's the line from the csproj file which is being imported to the proj file:

  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  <Import Project="$(MSBuildToolsPath)\SqlServer.targets" />

Here's the line from the proj file which is begin run by our Team City Server:

<Import Project="..\$(ProjectName).csproj"/>

My question is really:

Where does this file comes from? Is it part of the Visual Studio install for example.. Or is there some re-distribution package somewhere to allow me to compile this project on our build server?

Thanks

BTW.. if i just copy the file onto the Build server it does actually work.

Dave

A: 

Looks like it's part of the v2.0 framework install that gets moved into the v3.5 directory after that's added. You can either reinstall v2.0 of the framework or manually copy the file out of the v3.5 folder.

jkhines