You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
Now we will use the existing LinuxPlatfromSDK or if doesn't exist make a new one and correctly register it #jira UE-193418 #rb Josh.Adams, Zack.Neyland [CL 27323816 by brandon schaefer in ue5-main branch]
34 lines
978 B
C#
34 lines
978 B
C#
// Copyright Epic Games, Inc. All Rights Reserved.
|
|
|
|
using EpicGames.Core;
|
|
using Microsoft.Extensions.Logging;
|
|
|
|
namespace UnrealBuildTool
|
|
{
|
|
/// <summary>
|
|
/// Public Linux functions exposed to UAT
|
|
/// </summary>
|
|
public class LinuxExports
|
|
{
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
/// <param name="SourceFile"></param>
|
|
/// <param name="TargetFile"></param>
|
|
/// <param name="Logger">Logger for output</param>
|
|
public static void StripSymbols(FileReference SourceFile, FileReference TargetFile, ILogger Logger)
|
|
{
|
|
LinuxPlatformSDK? LinuxSDK = UEBuildPlatformSDK.GetSDKForPlatform("Linux") as LinuxPlatformSDK;
|
|
|
|
if (LinuxSDK == null)
|
|
{
|
|
LinuxSDK = new LinuxPlatformSDK(Logger);
|
|
UEBuildPlatformSDK.RegisterSDKForPlatform(LinuxSDK, "Linux", true);
|
|
}
|
|
|
|
LinuxToolChain ToolChain = new LinuxToolChain(LinuxPlatform.DefaultHostArchitecture, LinuxSDK, ClangToolChainOptions.None, Logger);
|
|
ToolChain.StripSymbols(SourceFile, TargetFile, Logger);
|
|
}
|
|
}
|
|
}
|