vs2012: build.cmd / Build.proj

Topics: General
Oct 15, 2012 at 10:03 PM

Are the integrated build scripts supposed to work on systems that have Visual Studio 2012 installed? origin/2.1 builds for me on a machine that doesn't have it, but it fails on my workstation after having installed it.

Additionally the build scripts in Build\NuGet.Settings.targets seem to set the TargetFrameworkVersion property dynamically, meaning you'll get different results on a machine that has VS2012 and one that doesn't. Shouldn't both produce builds that can be installed in VS2010?

Is there a plan or timeline to end support of VS2010?

Thanks,

Chris

Developer
Oct 15, 2012 at 10:28 PM
Edited Oct 15, 2012 at 10:29 PM

For 2.1, you'd need to switch to the Debug11 configuration to make it work.

msbuild .\Build\Build.proj /p:Configuration=Debug11 /m

Similarly, you'd have to switch to the Debug11 configuration if you're running with VS 2012. We fixed this in the master branch so you no longer have to do this (running build.cmd \ using Debug should work).

The VS component of NuGet references VS types and the VS 2012 versions of these assemblies are compiled against 4.5. Most of the devs on the NuGet team switched to exclusively using VS 2012. Consequently, the only way we could NuGet to build was by switching target frameworks if we detected VS 2012 was installed. My guess is we should have a flag in our target files there that lets us build a Vsix that works with VS2010 if you have both versions of VS installed. Feel free to create a work item for this.

Oct 16, 2012 at 1:03 AM

Thanks for the prompt reply.

On 2.1 with Configuration=Debug11, I get: The OutputPath property is not set for project 'CommandLine.csproj'.

Using more conventional Debug the build stops after the Build target with a Build FAILED message but no actual msbuild errors logged. Just some warnings in yellow:

warning MSB3270: There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "D:\workspace\nuget.git\src\CommandLine\bin\Debug\NuGet.exe", "x86".

It seems the VsExtension project is failing silently on DeployVsixExtensionFiles target. I guess I'll try to set up a VM that has only VS2012 on it and see how that goes.