Various improvements to building nethost

This commit is contained in:
Wojtek Figat
2024-01-12 13:44:50 +01:00
parent 5b3e7f0bf8
commit 9a70f698b9
4 changed files with 9 additions and 5 deletions

View File

@@ -229,6 +229,8 @@ bool DeployDataStep::Perform(CookingData& data)
srcDotnetLibs /= TEXT("../lib/net8.0");
}
}
LOG(Info, "Copying .NET files from {} to {}", packFolder, dstDotnet);
LOG(Info, "Copying .NET files from {} to {}", srcDotnetLibs, dstDotnetLibs);
FileSystem::CopyFile(dstDotnet / TEXT("LICENSE.TXT"), packFolder / TEXT("LICENSE.txt"));
FileSystem::CopyFile(dstDotnet / TEXT("LICENSE.TXT"), packFolder / TEXT("LICENSE.TXT"));
FileSystem::CopyFile(dstDotnet / TEXT("THIRD-PARTY-NOTICES.TXT"), packFolder / TEXT("ThirdPartyNotices.txt"));

View File

@@ -309,7 +309,7 @@ namespace Flax.Build
// Peek class library folder
var coreLibPaths = Directory.GetFiles(aotAssembliesPath, "System.Private.CoreLib.dll", SearchOption.AllDirectories);
if (coreLibPaths.Length != 1)
throw new Exception("Invalid C# class library setup in " + aotAssembliesPath);
throw new Exception($"Invalid C# class library setup in '{aotAssembliesPath}' (missing C# dll files)");
var dotnetLibPath = Utilities.NormalizePath(Path.GetDirectoryName(coreLibPaths[0]));
Log.Info("Class library found in: " + dotnetLibPath);

View File

@@ -30,6 +30,7 @@ namespace Flax.Deps.Dependencies
return new[]
{
TargetPlatform.PS4,
TargetPlatform.Switch,
};
case TargetPlatform.Linux:
return new[]
@@ -254,7 +255,8 @@ namespace Flax.Deps.Dependencies
Utilities.Run("cmake", "--version", null, null, Utilities.RunOptions.ThrowExceptionOnError);
// Get the source
CloneGitRepo(root, "https://github.com/FlaxEngine/dotnet-runtime.git", "flax-master", null, true);
CloneGitRepo(root, "https://github.com/FlaxEngine/dotnet-runtime.git", null, null, true);
GitCheckout(root, "flax-master");
SetupDirectory(Path.Combine(root, "src", "external"), false);
/*
@@ -285,6 +287,9 @@ namespace Flax.Deps.Dependencies
case TargetPlatform.Android:
Build(options, platform, TargetArchitecture.ARM64);
break;
case TargetPlatform.Switch:
Build(options, platform, TargetArchitecture.ARM64);
break;
}
}

View File

@@ -140,11 +140,8 @@ namespace Flax.Deps
if (submodules)
Utilities.Run("git", "submodule update --init --recursive", null, null, Utilities.RunOptions.DefaultTool);
}
if (commit != null)
{
Utilities.Run("git", string.Format("reset --hard {0}", commit), null, null, Utilities.RunOptions.DefaultTool);
}
}
/// <summary>