Open yahorsi opened 6 years ago
Please have a look at https://www.nuget.org/packages/Microsoft.Build.Runtime/ -- is not this package what you want?
I've been working on creating simple xcopy MSBuild bits based off the available NuGet packages. The project is over here:
https://github.com/jaredpar/xcopy-msbuild
The output is a NuGet package which is essentially a runnable MSBuild instance. It's sufficiently complete to compile projects like dotnet/roslyn.
@kkm000 It seems it is what I'm looking for. Just interesting, if there is already Microsoft.Build.Runtime package why @jaredpar have created it's own? How is it different with Microsoft.Build.Runtime?
PS: How is that possible to tell msbuld (and ideally VS as well) to use compilers sfrom come custom folder? Where we could have e.g. Microsoft.Net.Compilers extracted
@kkm000 Can't even run it - calling C:\PROJECTS\Microsoft.Build.Runtime\contentFiles\any\net46\MSBuild.exe returns:
Unhandled Exception: System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Build.Framework, Version=15.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified. at Microsoft.Build.CommandLine.MSBuildApp.Execute(String commandLine) at Microsoft.Build.CommandLine.MSBuildApp.Main()
In order to make builds reproducible it would be good to store all tools used during build in the source control system. E.g. MSBuild. That will make builds independent from what is installed on the build agents. That will simplify upgrading msbuild as well. Just install new package and commit - you're done for all agents. Ideally compiler should also be distributed as stand alone nuget packages.