I have figured out how it works (without changing sln/csproj properties in VS2013/2015).
- if you want to build .sln file:
/p:ConfigurationPlatforms=Release /p:Platform="Any CPU"
- if you want to build .csproj file:
/p:Configuration=Release /p:Platform=AnyCPU- notice the
"Any CPU"vsAnyCPU
- notice the
- check the code analysis, fxcop, test coverage(NCover) targets, as well as the MSBUILD should be located properly. In my case its:
C:\Windows\Microsoft.NET\Framework64\v4.0.30319
but it can be different as you can see microsoft has given 6 cmd options to build code base::AMD (with cross plt, x86 & x64 options) and Windows(cross, x86, x64) and that also when code development happened with default JIT (it can be PreJIT ngen.exe, econoJIT)
I think more than this troubleshooting can be handle using power shell + msbuild. May be helpful for someone …