You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
UEBuildModule stores its .Module.cs filename. UEBuildTarget stores a map of dictionaries from module names to .Target.cs files. Timestamps of serialized .Target.cs and .Module.cs files compared against makefile and used for invalidation. More sensible Dictionary logic in ConditionallyCompileAndLoadRulesAssembly. InstantiateModule can no longer return a null. UEBuildModule constructors no longer default. #codereview robert.manuszewski [CL 2543446 by Steve Robb in Main branch]
79 lines
2.5 KiB
C#
79 lines
2.5 KiB
C#
// Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
|
|
|
|
using System;
|
|
using System.Collections.Generic;
|
|
using System.IO;
|
|
using System.Text;
|
|
|
|
namespace UnrealBuildTool
|
|
{
|
|
[Serializable]
|
|
public class UEBuildServer : UEBuildTarget
|
|
{
|
|
public UEBuildServer(TargetDescriptor InDesc, TargetRules InRulesObject, string InTargetCsFilename)
|
|
: base(InDesc, InRulesObject, "UE4Server", InTargetCsFilename)
|
|
{
|
|
}
|
|
|
|
//
|
|
// UEBuildTarget interface.
|
|
//
|
|
|
|
/// <summary>
|
|
/// Setup the binaries for this target
|
|
/// </summary>
|
|
protected override void SetupBinaries()
|
|
{
|
|
base.SetupBinaries();
|
|
|
|
{
|
|
// Make the game executable.
|
|
UEBuildBinaryConfiguration Config = new UEBuildBinaryConfiguration( InType: UEBuildBinaryType.Executable,
|
|
InOutputFilePaths: OutputPaths,
|
|
InIntermediateDirectory: EngineIntermediateDirectory,
|
|
bInCreateImportLibrarySeparately: (ShouldCompileMonolithic() ? false : true),
|
|
bInAllowExports:!ShouldCompileMonolithic(),
|
|
InModuleNames: new List<string>() { "Launch" } );
|
|
|
|
AppBinaries.Add( new UEBuildBinaryCPP( this, Config ) );
|
|
}
|
|
|
|
// Add the other modules that we want to compile along with the executable. These aren't necessarily
|
|
// dependencies to any of the other modules we're building, so we need to opt in to compile them.
|
|
{
|
|
// Modules should properly identify the 'extra modules' they need now.
|
|
// There should be nothing here!
|
|
}
|
|
|
|
// Allow the platform to setup binaries
|
|
UEBuildPlatform.GetBuildPlatform(Platform).SetupBinaries(this);
|
|
}
|
|
|
|
public override void SetupDefaultGlobalEnvironment(
|
|
TargetInfo Target,
|
|
ref LinkEnvironmentConfiguration OutLinkEnvironmentConfiguration,
|
|
ref CPPEnvironmentConfiguration OutCPPEnvironmentConfiguration
|
|
)
|
|
{
|
|
UEBuildConfiguration.bCompileLeanAndMeanUE = true;
|
|
|
|
// Do not include the editor
|
|
UEBuildConfiguration.bBuildEditor = false;
|
|
UEBuildConfiguration.bBuildWithEditorOnlyData = false;
|
|
|
|
// Require cooked data
|
|
UEBuildConfiguration.bBuildRequiresCookedData = true;
|
|
|
|
// Compile the engine
|
|
UEBuildConfiguration.bCompileAgainstEngine = true;
|
|
|
|
// Tag it as a 'Server' build
|
|
OutCPPEnvironmentConfiguration.Definitions.Add("UE_SERVER=1");
|
|
OutCPPEnvironmentConfiguration.Definitions.Add("USE_NULL_RHI=1");
|
|
|
|
// no exports, so no need to verify that a .lib and .exp file was emitted by the linker.
|
|
OutLinkEnvironmentConfiguration.bHasExports = false;
|
|
}
|
|
}
|
|
}
|