Installing MSBuild 4.0 without Visual Studio 2010

.NetVisual Studio-2010MsbuildSdk.Net 4.0

.Net Problem Overview


I installed .NET 4.0 and VS 2010 RC on my laptop and MSBuild was automatically installed. I was hoping to build a continuous integration server by just installing the .NET SDK without VS 2010, so I downloaded the .NET 4.0 Framework from Microsoft at this http://www.microsoft.com/downloads/details.aspx?FamilyID=a9ef9a95-58d2-4e51-a4b7-bea3cc6962cb&displaylang=en">link</a>;. Unfortunately, it doesn't appear to have installed MSBuild with this download (or at least I can't find it).

Is this link the appropriate link for the SDK, or is this just the runtime? If not, where is the link for the SDK?

I kind of doubt it is the entire SDK as it is only 35MB where the .NET 3.5 SP1 download was over 200MB.

.Net Solutions


Solution 1 - .Net

If you're looking for msbuild, you'll find that for 4.0 it's at:

For 32-bit:

> C:\Windows\Microsoft.NET\Framework\v4.0.30319\MSBuild.exe

For 64-bit:

> C:\Windows\Microsoft.NET\Framework64\v4.0.30319\MSBuild.exe

Solution 2 - .Net

Perhaps this is the SDK disguised slightly as a Windows 7 SDK.

Microsoft Windows SDK for Windows 7 and .NET Framework 4

UPDATE: Based off of a blog posts on the Windows SDK Blog the SDK that I linked to above seems to contain msbuild and supports building managed (.NET) applications. I'm assuming this is the SDK we have all been looking for in order to install on our build servers so I'm downloading it now and I'll post any further findings after I check it out.

UPDATE: I can confirm that the link provided above does indeed install MSBuild along with other portions of what would constitute an SDK for .NET 4.0. I'm successfully using this on my build machine now without installing Visual Studio 2010 to build our project.

UPDATE: Please also see FrederikB's answer below as it appears that the whole SDK may not be required to get MSBuild 4.0. This would be especially useful if you need to set up a minimal build server. I haven't confirmed whether this works for me or not but it would be worth a try before installing the SDK.

UPDATE (Feb 2022): Most recently when I needed to work with msbuild for an older .NET Framework project I was able to do so using the Build Tools for Visual Studio. The most recent version at the time of this update can be found at the Download page for Visual Studio itself. Look for Build Tools for Visual Studio 2022 under the section labeled Tools for Visual Studio 2022. Obviously the modern equivalent in the age of .NET 6 is to use the universal .NET SDK which includes the dotnet cli tool as a big improvement over MSBuild and in some cases can still be used to build certain .NET Framework projects.

Solution 3 - .Net

Using the .Net default MsBuild may not be enough. You can download the free MsBuild Tools for Visual studio here, and install all the dependencies used in your project. enter image description here

Solution 4 - .Net

MS-Build shipped along with Visual studio , so I am not sure whether we can install MS- Build alone For eg : MS-Build 16.6.0 comes along with VS 2019

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestiondewaldView Question on Stackoverflow
Solution 1 - .NetFrederikView Answer on Stackoverflow
Solution 2 - .NetjpiersonView Answer on Stackoverflow
Solution 3 - .NetHainan ZhaoView Answer on Stackoverflow
Solution 4 - .NetRajMView Answer on Stackoverflow