Add -dotnet=ver command arg to Flax.Build to specify .NET SDK version to use for build

This commit is contained in:
Wojtek Figat
2023-11-25 12:16:13 +01:00
parent 2cef368282
commit 40d6e18e7e
8 changed files with 91 additions and 20 deletions

View File

@@ -32,7 +32,7 @@ public class nethost : ThirdPartyModule
// Get .NET SDK runtime host
var dotnetSdk = DotNetSdk.Instance;
if (!dotnetSdk.IsValid)
throw new Exception($"Missing NET SDK {DotNetSdk.MinimumVersion}.");
throw new DotNetSdk.MissingException();
if (!dotnetSdk.GetHostRuntime(options.Platform.Target, options.Architecture, out var hostRuntime))
{
if (options.Target.IsPreBuilt)