1
votes

I just built a Windows 2012R server as our build server.

The following are installed:

  • VS2012 with latest update
  • VS2013 with latest update
  • VS2015 with latest update
  • TFS 2013 with no update and configured the Build Service

We are using GIT in TFS 2013 so the Build Process Template is GitTemplate12.xml.

The following attempts have been made to change the controller to use MSBuild14.0 instead of MSBuild12.0 during build, with no success

  • add /tv:14.0 /p:VisualStudioVersion=14.0 to the MSBuild Parameters in build process definition
  • Use VS2013 designer to change the ToolVersion of RunMSBuild activity to "14.0" in GitTemplate12.xml and change the build process to use it

Any ideas what might be the issues? Seen other people make it work with TFS template. Feel I am running out of possible solutions.

The diagnostics step log for Run MS Build at beginning shows

Inputs  ProjectsToBuild: String[] Array  MSBuildMultiProc: True  Verbosity: Normal  ToolPlatform: Auto  Targets:   RunCodeAnalysis: AsConfigured  CommandLineArguments: /p:SkipInvalidConfigurations=true /tv:14.0 /p:VisualStudioVersion=14.0 ,

but the following logs for the build still shows 12.0

C:\Program Files\Microsoft Team Foundation Server 12.0\Tools\nuget.exe restore "D:\Builds\11\abc.sln" -NonInteractive

All packages listed in packages.config are already installed.

C:\Program Files (x86)\MSBuild\12.0\bin\amd64\MSBuild.exe /nologo /noconsolelogger "D:\Builds\11\abc.sln"

1

1 Answers

0
votes

I have tested on TFS 2013.5 with default GitTemplate12.xml build template, and just add /tv:14.0 to the msbuild arguments in build template, then the build use MSBuild 14.0 as expected.

enter image description here

In order to figurate out why it didn't work on your side. Try the items below:

  1. Create a light project and use the default GitTemplate12.xml build template to have a test.

  2. Clean the Cache folder on client computer. The folder path is: C:\Users\username\AppData\Local\Microsoft\Team Foundation\5.0\Cache.

  3. Clean the Cache folder on Server machine. The folder path is: C:\Program Files\Microsoft Team Foundation Server 12.0\Application Tier\Web Services\_tfs_data.