msbuildvisual-studio-2015azure-devopsplatform-specificazure-pipelines-build-task

Build proccess in VS team services incorrectly maps Win32 to x64


I've set up a build process in Visual Studio Team Services for a UWP solution using an agent on my box. My solution contains a mix of C++ and managed projects (2 projects are C++, other are C#). My problem is that x86 build fails, while for x64 and ARM platforms the build completes successfully.

From what I'm seeing from the build log, it is incorrectly treating Win32 platform as x64, and putting the resulting *.lib file into bin\Release\x64 folder instead of bin\Release\Win32, where the next project is supposed to pick it up from:

C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\x86_amd64\Lib.exe /OUT:"C:\Agent\_work\1\s\MyProj\MyProject1\bin\Release\x64\MyProject1.lib" /NOLOGO /LTCG C:\Agent\_work\1\s\MyProj\MyProject1\obj\Release\x64\test.obj

Any suggestions on how to fix that are greatly appreciated.


Solution

  • The issue was happening because I didn't have multi-configuration set up. To be able to build the solution for multiple platforms/configruations, this is a mandatory setting. When I got that set, the build started to succeed.