dotnet / msbuild

The Microsoft Build Engine (MSBuild) is the build platform for .NET and Visual Studio.
https://docs.microsoft.com/visualstudio/msbuild/msbuild
MIT License
5.17k stars 1.34k forks source link

Microsoft.Build.Runtime still requires MSBuild Tools #4913

Open SuperRajar opened 4 years ago

SuperRajar commented 4 years ago

I have an application using the Microsoft.Build nuget packages to compile some C# code. With MSBuild 2015 installed on the machine everything works fine. However I want to get rid of the MS Build Tools prerequisite and as I understand it Microsoft.Build.Runtime is supposed to solve that issue. In the description is says "This package delivers a complete executable copy of MSBuild. Reference this package only if your application needs to load projects or execute in-process builds without requiring installation of MSBuild.".

But if I run the code on machine without MSBuild Tools installed I get the same error message (Could not load file or assembly 'System.Threading.Tasks.Dataflow) even though I have included the Microsoft.Build.Runtime package. Have I misunderstood something or do I just need to Initialize the the Build.Runtime somehow?

livarcocc commented 4 years ago

You will still need the MSBuild tools installed.

This package will only carry the engine and some basic props/targets. You will still be missing a lot of things to be able to handle a variety of projects.