2019-12-26 23:01:54 -05:00
|
|
|
// Copyright Epic Games, Inc. All Rights Reserved.
|
2019-10-04 13:11:45 -04:00
|
|
|
|
|
|
|
|
using UnrealBuildTool;
|
|
|
|
|
|
2020-09-01 14:07:48 -04:00
|
|
|
[SupportedPlatforms("Win64")]
|
2019-10-04 13:11:45 -04:00
|
|
|
public abstract class DatasmithMaxBaseTarget : TargetRules
|
|
|
|
|
{
|
|
|
|
|
public DatasmithMaxBaseTarget(TargetInfo Target)
|
|
|
|
|
: base(Target)
|
|
|
|
|
{
|
|
|
|
|
Type = TargetType.Program;
|
2022-03-30 10:12:09 -04:00
|
|
|
IncludeOrderVersion = EngineIncludeOrderVersion.Latest;
|
2019-11-14 17:19:25 -05:00
|
|
|
SolutionDirectory = "Programs/Datasmith";
|
2019-12-19 12:34:35 -05:00
|
|
|
bBuildInSolutionByDefault = false;
|
2019-10-04 13:11:45 -04:00
|
|
|
bLegalToDistributeBinary = true;
|
|
|
|
|
|
|
|
|
|
bShouldCompileAsDLL = true;
|
|
|
|
|
LinkType = TargetLinkType.Monolithic;
|
|
|
|
|
|
2021-11-18 14:37:34 -05:00
|
|
|
WindowsPlatform.ModuleDefinitionFile = "Programs/Enterprise/Datasmith/DatasmithMaxExporter/DatasmithMaxExporterWithDirectLink.def";
|
2021-09-22 10:22:19 -04:00
|
|
|
|
2020-09-03 09:21:40 -04:00
|
|
|
WindowsPlatform.bStrictConformanceMode = false;
|
2019-10-04 13:11:45 -04:00
|
|
|
|
|
|
|
|
bBuildDeveloperTools = false;
|
|
|
|
|
bUseMallocProfiler = false;
|
|
|
|
|
bBuildWithEditorOnlyData = true;
|
|
|
|
|
bCompileAgainstEngine = false;
|
|
|
|
|
bCompileAgainstCoreUObject = true;
|
|
|
|
|
bCompileICU = false;
|
|
|
|
|
bUsesSlate = false;
|
|
|
|
|
|
|
|
|
|
bHasExports = true;
|
|
|
|
|
bForceEnableExceptions = true;
|
2021-09-22 10:22:19 -04:00
|
|
|
|
2021-11-18 14:37:34 -05:00
|
|
|
GlobalDefinitions.Add("UE_EXTERNAL_PROFILING_ENABLED=0"); // For DirectLinkUI (see FDatasmithExporterManager::FInitOptions)
|
2021-09-22 10:22:19 -04:00
|
|
|
|
|
|
|
|
// todo: remove?
|
|
|
|
|
// bSupportEditAndContinue = true;
|
2019-10-04 13:11:45 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void AddCopyPostBuildStep(TargetInfo Target)
|
|
|
|
|
{
|
|
|
|
|
// Add a post-build step that copies the output to a file with the .dle extension
|
|
|
|
|
string OutputName = "$(TargetName)";
|
|
|
|
|
if (Target.Configuration != UnrealTargetConfiguration.Development)
|
|
|
|
|
{
|
|
|
|
|
OutputName = string.Format("{0}-{1}-{2}", OutputName, Target.Platform, Target.Configuration);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
string SrcOutputFileName = string.Format(@"$(EngineDir)\Binaries\Win64\{0}\{1}.dll", ExeBinariesSubFolder, OutputName);
|
2021-09-22 10:22:19 -04:00
|
|
|
|
|
|
|
|
string DstOutputFileName;
|
|
|
|
|
|
2021-11-18 14:37:34 -05:00
|
|
|
DstOutputFileName = string.Format(@"$(EngineDir)\Binaries\Win64\{0}\{1}.gup", ExeBinariesSubFolder, OutputName);
|
|
|
|
|
|
2019-10-04 13:11:45 -04:00
|
|
|
PostBuildSteps.Add(string.Format("echo Copying {0} to {1}...", SrcOutputFileName, DstOutputFileName));
|
|
|
|
|
PostBuildSteps.Add(string.Format("copy /Y \"{0}\" \"{1}\" 1>nul", SrcOutputFileName, DstOutputFileName));
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public class DatasmithMax2017Target : DatasmithMaxBaseTarget
|
|
|
|
|
{
|
|
|
|
|
public DatasmithMax2017Target(TargetInfo Target)
|
|
|
|
|
: base(Target)
|
|
|
|
|
{
|
|
|
|
|
LaunchModuleName = "DatasmithMax2017";
|
|
|
|
|
ExeBinariesSubFolder = @"3DSMax\2017";
|
|
|
|
|
|
|
|
|
|
AddCopyPostBuildStep(Target);
|
|
|
|
|
}
|
|
|
|
|
}
|