I don’t know what is going wrong but…
How to fix it
- Open the solution in Visual Studio
- Remove every targets except the target you want to build with ‘msbuild’
- save the solution
- Add all the targets just removed before
- save the solution
This makes the order of projects in the solution. Does msbuild fails due to project order?