Troubleshooting tips with Team Build 2010 for the projects migrated from 2005 or 2008

Following comes from Senior Support Engineer Deepak Mittal.

 

These are some troubleshooting tips which you may find useful in some scenarios. We've found them useful during troubleshooting of several cases reported to us. When you migrate your TFS from 2005\2008 to 2010, Team Build 2010 uses upgradetemplate.xaml which basically uses your old TFSBuild.proj and TFSBuild.rsp files.

  • In case you have done customizations in .proj and .rsp files, then the MSBuild properties mentioned in 2010 build definitions gets overridden by the properties defined in the .proj and .rsp files.
  • Build log was huge in size . We found though the verbosity level was defined in the build definition to minimal, however, later we found that it was also defined in the .rsp file as well with /flp:verbosity=diagnostics and this was taking precedence, commenting out this in .rsp file resolved the issue. The .rsp file is an empty file generated by the New Team Build Type Creation Wizard. You can use this file to specify custom logger or override MSBuild properties
    msdn.microsoft.com/en-us/library/ms400710(VS.80).aspx

  • Source directory path was defined based on the variables in TFS 2008 and hence files\dlls were not getting copied to correct build output folder based on Team Build 2010, and therefore while building the projects, dlls references were not found properly. Please review the settings of build output in the .proj file. In team build 2010, the $(SourceDir) refers to the default working directory for the build agent. The default for this path is: $(SystemDrive)\Builds \$(BuildAgentId)\$(BuildDefinitionPath)

  • Several times I noticed that customization of the Microsoft.teamfoundation.build.target is done while working with team build 2005/2008, you may see several issues because of this while building your project with team build 2010.

    We strongly discourage you from modify the targets file. If you want to add additional properties or items or want to introduce custom targets and tasks, please use the corresponding proj file or add the activities in XAML files (make a copy of the XAML file and use that in the build). The targets file defines the generic build process. If you make any change in the targets file, then all the subsequent builds will be affected.

    Default location of Microsoft.teamfoundation.target file is <root>:\Program Files\MSBuild\Microsoft\VisualStudio\TeamBuild on the build agent. Reference: msdn.microsoft.com/en-us/library/aa337604.aspx