14

What is needed in the tfs 2010 build agent, to build .net 4.5 projects, in tfs 2008 we had to set the MSBuildPath property, but the configuration seems to be different in 2010.

I get the following error message. (614): The imported project "C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets" was not found. Confirm that the path in the declaration is correct, and that the file exists on disk.

How we handled it in 2008 http://blogs.msdn.com/b/willbar/archive/2009/11/01/building-net-4-0-applications-using-team-build-2008.aspx

abatishchev
  • 531
  • 1
  • 9
  • 31
JustEngland
  • 273
  • 3
  • 8
  • It [seems it may Just Work](http://blog.codeassassin.com/2012/05/10/override-the-tfs-team-build-outdir-property-net-4-5/) -- are you seeing any errors when you attempt to build? – Russ Amos Aug 23 '12 at 12:06
  • 1
    That error message seems related to [this issue around not having VS installed on the build machine](http://stackoverflow.com/questions/3980909/microsoft-webapplication-targets-was-not-found-on-the-build-server-whats-your). Have you tried the suggestions in that question? – Russ Amos Aug 23 '12 at 20:19

2 Answers2

18

It's not necessary to install Visual Studio 2012. Just copy the files in the following folder from a computer with VS2012 installed to your build server and it should work:

C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\

  • 1
    Confirmed this is true when VS 2010 was installed on the Build Machine -- that you can simply copy these v11 files. Not sure if it would still work if VS2010 wasn't previously installed. – kingdango Nov 09 '12 at 03:22
  • 1
    This will work for everything _but_ SQL project support. This requires a whole bunch of hoop jumping (installing the SQL Data Tier Framework etc etc - all in all its a similar sized install). it might be worth considering installing VS 2012 anyway. – Doug Jul 14 '13 at 23:21
  • Would it not work if you were to install the MS Build Tools (listed under Downloads > Additional Software on visualstudio.com, link: http://go.microsoft.com/?linkid=9832060)? – mstaessen Apr 29 '15 at 14:09
3

You just need to install Visual Studio 2012 and you will be good to go.

  • We have never had to do that before, I would prefure not to install visual studio on the build servers. Does it have to be installed on all of the build agents as well. – JustEngland Aug 29 '12 at 00:25
  • what if my server is Server 2008 (NOT R2) and doesn't let me install either the Windows 8 SDK or VS2012 – Simon Sep 07 '12 at 06:03