I have build that uses a tfsbuild.proj file and an Upgrade template.
My build is set to build in Release|Any CPU mode.
<ItemGroup Condition="'$(DebugOnly)' != 'True'">
<ConfigurationToBuild Include="Release|Any CPU">
<FlavorToBuild>Release</FlavorToBuild>
<PlatformToBuild>Any CPU</PlatformToBuild>
</ConfigurationToBuild>
</ItemGroup>
This definition builds multiple solutions. I have recently discovered that 2 solutions build some of the same files, so in my log file it builds some projects and then later rebuilds those projects over again. (This is frustrating but the slns are not mine so I will have to work on getting these changed.)
Here is what my problem is:
The build is building one file in Release then the second file in debug.
CopyFilesToOutputDirectory:
abc.Core -> E:\ActiveBldTypes\APM V3\V3.6.0.6.0\bin\Release\abc.Core.dll
...
Done Building Project "E:\ActiveBldTypes\APM V3\V3.6.0.6.0\src\abc\Core\abc.Core.csproj" (default targets).
Project "E:\ActiveBldTypes\APM V3\V3.6.0.6.0\src\abc\Mobile\WebAPI\abc.WebAPI\abc.WebAPI.csproj" (186) is building "E:\ActiveBldTypes\APM V3\V3.6.0.6.0\src\abc\Registry\abc.Registry.csproj" (14:112) on node 1 (default targets).
Project "E:\ActiveBldTypes\APM V3\V3.6.0.6.0\src\abc\Registry\abc.Registry.csproj" (14:112) is building "E:\ActiveBldTypes\APM V3\V3.6.0.6.0\src\abc\Excel\abc.Excel.csproj" (12:20) on node 1 (default targets).
PrepareForBuild:
Creating directory "obj\Debug\".
I have checked the abc.Excel.csproj properties and for Release Any CPU the output path is bin\Release\.
Earlier in the log file, remember I said it is building it 2 times, I see:
Project "E:\ActiveBldTypes\APM V3\V3.6.0.6.0\src\abc\Admin\abc.Admin.csproj" (9) is building "E:\ActiveBldTypes\APM V3\V3.6.0.6.0\src\abc\Excel\abc.Excel.csproj" (12) on node 1 (default targets).
PrepareForBuild:
Creating directory "obj\Release\".
So here is what I do not understand:
The build project is set to build Release|Any CPU
When I open each sln, and look in Configuration Manager, Active config is Release: Active platform is Any CPU
Then look at abc.Excel project, both are set to Configuration = Release, platform = Any CPU.
The project is the exact same project, I don't have 2 in source control so the build process is reading the same abc.Excel.csproj file.
Why is the output Release in one sln and debug in the other. especially in the first case when the first project(abc.Core.csproj) outputs to Release but the second project(abc.Excel.csproj) outputs to debug. It is like the build process changes to Debug mid solution??????
Any ideas would be greatly appreciated.
BTW
Using VS2013, TFS2013, build machine 2008/r2