-
Notifications
You must be signed in to change notification settings - Fork 37
Description
Problem
MonoDevelop's Build System is not future save.
it contains a lot of workarounds of old .net-versions, and code from that time when MSBuild was closed source
at least it's broken already if .net5 is installed.
current implementation uses some hacky tricks to work around, see:
dotdevelop/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.MSBuild/RemoteBuildEngineManager.cs
Line 463 in 9b1b738
| static string GetLocalMSBuildExeLocation (TargetRuntime runtime) |
affected projects:
https://github.com/dotdevelop/dotdevelop/tree/master/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.MSBuild
https://github.com/dotdevelop/dotdevelop/tree/master/main/src/core/MonoDevelop.Projects.Formats.MSBuild
and for NuGet:
https://github.com/dotdevelop/dotdevelop/tree/master/main/src/addins/MonoDevelop.PackageManagement
possible solution
there is a lot of similar code around, actively supported
but most of it not public accesible (internal, private etc.)
clone this repos, branch it & make usable code accessible (eg. internal visible to, wrapper project) or adopt it
MSBuild:
https://github.com/dotdevelop/msbuild (partly cloned in https://github.com/dotdevelop/dotdevelop/tree/master/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.MSBuild)
Mono-MsBuild
https://github.com/mono/msbuild/commits/mono-2019-12
and also similar problems are solved in OmniSharp:
https://github.com/dotdevelop/omnisharp-roslyn/tree/master/src/OmniSharp.MSBuild
see also: https://github.com/OmniSharp/csharp-language-server-protocol
NuGet:
https://github.com/NuGet/NuGet.Client
https://github.com/NuGet/NuGet.Client/tree/dev/src/NuGet.Clients/NuGet.PackageManagement.UI (partly cloned in https://github.com/dotdevelop/dotdevelop/tree/master/main/src/addins/MonoDevelop.PackageManagement)
etc. see NuGet.VisualStudio ff
deliver own versions
there should be local, proved working fallback versions packaged with MonoDevelop to avoid problems with wild MS updates, as shown in the past.
minimum 2 msbuild fallback versions:
one for dotnetcore (building 2.1,3.1,5 ff)
one for .net framework, a mono framework version at least is in https://github.com/dotnet/msbuild/blob/vs16.9 if FullFrameworkTFM or MonoBuild is set.
Package a recent nuget.exe used by monodevelop.
there is no reason why there should be a lot of workarounds for old versions to avoid some mb of extra data.