public ViewportInteraction(TargetInfo Target)
        {
            PrivateDependencyModuleNames.AddRange(
                new string[] {
                    "Core",
                    "CoreUObject",
                    "Engine",
                    "InputCore",
                    "UnrealEd",
                    "Slate",
                    "SlateCore",
                    "HeadMountedDisplay"
                }
            );

            PrivateIncludePathModuleNames.AddRange(
                new string[] {
					"LevelEditor"
                }
            );

            DynamicallyLoadedModuleNames.AddRange(
                new string[] {
                }
            );
        }
Ejemplo n.º 2
0
        public bool LoadOpenCV(TargetInfo Target)
        {
            bool isLibrarySupported = false;

            if ((Target.Platform == UnrealTargetPlatform.Win64) || (Target.Platform == UnrealTargetPlatform.Win32))
            {
                isLibrarySupported = true;
                PublicIncludePaths.Add(Path.Combine(ThirdPartyPath, "opencv","include"));
                string PlatformString = (Target.Platform == UnrealTargetPlatform.Win64) ? "x64" : "x86";
                string LibrariesPath = Path.Combine(ThirdPartyPath, "opencv", PlatformString, "vc12", "lib");
                foreach (var file in Directory.EnumerateFiles(LibrariesPath, "*.lib", SearchOption.AllDirectories))
                {
                    PublicAdditionalLibraries.Add(file);
                    Debug.Print("Including Lib : " + file);
                }
            }
            else if(Target.Platform == UnrealTargetPlatform.Mac)
            {
                isLibrarySupported = true;
                PublicIncludePaths.Add("/usr/local/Cellar/opencv/2.4.12/include");
                string LibrariesPath = Path.Combine("/usr/local/Cellar/opencv/2.4.12", "lib");
                foreach (var file in Directory.EnumerateFiles(LibrariesPath, "*.dylib", SearchOption.AllDirectories))
                {
                    PublicAdditionalLibraries.Add(file);
                    Debug.Print("Including Lib : " + file);
                }
            }

            Debug.Print("Included Third Part : " + Path.Combine(ThirdPartyPath, "opencv"));
            return isLibrarySupported;
        }
Ejemplo n.º 3
0
		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 'Game' build
			OutCPPEnvironmentConfiguration.Definitions.Add("UE_GAME=1");

			// no exports, so no need to verify that a .lib and .exp file was emitted by the linker.
			OutLinkEnvironmentConfiguration.bHasExports = false;

			// Disable server code
			UEBuildConfiguration.bWithServerCode = false;
		}
Ejemplo n.º 4
0
        public Unreal_ROS(TargetInfo Target)
        {
            //PrivateIncludePaths.AddRange(
            //	);

            PrivateDependencyModuleNames.AddRange(
                new string[]
                {
                    "Core",
                    "Networking",
                    "Sockets"
                }
                );
            string rapidjson_path = Path.Combine(ThirdPartyPath, "rapidjson", "include");

            System.Diagnostics.Debug.Write(rapidjson_path);
            PublicIncludePaths.AddRange(new string[] { rapidjson_path });
            PrivateIncludePaths.AddRange(new string[] { rapidjson_path });
            //LoadOpenCV(Target);

            if (UEBuildConfiguration.bBuildEditor == true)
            {
                PrivateDependencyModuleNames.Add("UnrealEd");
            }

            PrivateDependencyModuleNames.AddRange(
                    new string[]
                    {
                    "Core",
                    "CoreUObject",
                    "Engine",
                    "InputCore"
                    }
                    );
        }
Ejemplo n.º 5
0
		/// <summary>
		/// Modify the rules for a newly created module, in a target that's being built for this platform.
		/// This is not required - but allows for hiding details of a particular platform.
		/// </summary>
		/// <param name="ModuleName">The name of the module</param>
		/// <param name="Rules">The module rules</param>
		/// <param name="Target">The target being build</param>
		public override void ModifyModuleRulesForActivePlatform(string ModuleName, ModuleRules Rules, TargetInfo Target)
		{
			bool bBuildShaderFormats = UEBuildConfiguration.bForceBuildShaderFormats;

			if (!UEBuildConfiguration.bBuildRequiresCookedData)
			{
				if (ModuleName == "TargetPlatform")
				{
					bBuildShaderFormats = true;
				}
			}

			// allow standalone tools to use target platform modules, without needing Engine
			if (ModuleName == "TargetPlatform")
			{
				if (UEBuildConfiguration.bForceBuildTargetPlatforms)
				{
					Rules.DynamicallyLoadedModuleNames.Add("MacTargetPlatform");
					Rules.DynamicallyLoadedModuleNames.Add("MacNoEditorTargetPlatform");
					Rules.DynamicallyLoadedModuleNames.Add("MacClientTargetPlatform");
					Rules.DynamicallyLoadedModuleNames.Add("MacServerTargetPlatform");
					Rules.DynamicallyLoadedModuleNames.Add("AllDesktopTargetPlatform");
				}

				if (bBuildShaderFormats)
				{
					// Rules.DynamicallyLoadedModuleNames.Add("ShaderFormatD3D");
					Rules.DynamicallyLoadedModuleNames.Add("ShaderFormatOpenGL");
					Rules.DynamicallyLoadedModuleNames.Add("MetalShaderFormat");

					Rules.DynamicallyLoadedModuleNames.Remove("VulkanRHI");
					Rules.DynamicallyLoadedModuleNames.Add("VulkanShaderFormat");
				}
			}
		}
Ejemplo n.º 6
0
        public override void SetupDefaultGlobalEnvironment(
			TargetInfo Target,
			ref LinkEnvironmentConfiguration OutLinkEnvironmentConfiguration,
			ref CPPEnvironmentConfiguration OutCPPEnvironmentConfiguration
			)
        {
            if (Target.Platform == UnrealTargetPlatform.Mac)
            {
                UEBuildConfiguration.bCompileNetworkProfiler = false;
            }
            else
            {
                UEBuildConfiguration.bCompileNetworkProfiler = true;
            }

            UEBuildConfiguration.bCompileLeanAndMeanUE = false;

            // Do not include the editor
            UEBuildConfiguration.bBuildEditor = true;
            UEBuildConfiguration.bBuildWithEditorOnlyData = true;

            // Require cooked data
            UEBuildConfiguration.bBuildRequiresCookedData = false;

            // Compile the engine
            UEBuildConfiguration.bCompileAgainstEngine = true;

            // Tag it as a 'Editor' build
            OutCPPEnvironmentConfiguration.Definitions.Add("UE_EDITOR=1");
        }
        public FLKinectPlugin(TargetInfo Target)
        {
            string KinectPathEnvVar = "%KINECTSDK20_DIR%";
            string ExpandedKinectEnvVar = Environment.ExpandEnvironmentVariables(KinectPathEnvVar);

            //NOTE (OS): Safety check for comptuers that don't have the kinect plugin
            if (KinectPathEnvVar == ExpandedKinectEnvVar)
            {
                var err = "ERROR : Environment variable {0} does not exist in this Windows environment. Check if the Kinect for Windows 2.0 plugin is installed.";
                Console.WriteLine(err, KinectPathEnvVar);
                throw new Exception(err);
            }

            string ThirdPartyKinectIncludePath = Path.Combine(ExpandedKinectEnvVar, "inc");

            string PlatformSpec = (Target.Platform == UnrealTargetPlatform.Win64) ? "x64" : "x86";
            string ThirdPartyKinectLibPath = Path.Combine(ExpandedKinectEnvVar, "Lib", PlatformSpec);

            PublicAdditionalLibraries.Add(Path.Combine(ThirdPartyKinectLibPath, "Kinect20.lib"));

            PublicIncludePaths.AddRange(
                new string[] {
                    // ... add public include paths required here ...
                }
                );

            PrivateIncludePaths.AddRange(
                new string[] {
                    "FLKinectPlugin/Private",
                    "FLKinectPlugin/Classes",
                    ThirdPartyKinectIncludePath
                    // ... add other private include paths required here ...
                }
                );

            PublicDependencyModuleNames.AddRange(
                new string[]
                {
                    "Core",
                    "CoreUObject",
                    // ... add other public dependencies that you statically link with here ...
                }
                );

            PrivateDependencyModuleNames.AddRange(
                new string[]
                {
                    "Engine",
                    // ... add private dependencies that you statically link with here ...
                }
                );

            DynamicallyLoadedModuleNames.AddRange(
                new string[]
                {
                    // ... add any modules that your module loads dynamically here ...
                }
                );
        }
Ejemplo n.º 8
0
		public KlawrRuntimePlugin(TargetInfo Target)
		{
			PublicIncludePaths.AddRange(
				new string[] {
					// ... add other public include paths required here ...
				}
			);

			PrivateIncludePaths.AddRange(
				new string[] {
                    "KlawrRuntimePlugin/Private"
					// ... add other private include paths required here ...
				}
			);

			PublicDependencyModuleNames.AddRange(
				new string[]
				{
					"Core",
					"CoreUObject",
					"Engine",
					"InputCore",
                    // ... add other public dependencies that you statically link with here ...
				}
			);

			if (UEBuildConfiguration.bBuildEditor == true)
			{

				PublicDependencyModuleNames.AddRange(
					new string[] 
					{
						"UnrealEd", 
					}
				);
			}

			PrivateDependencyModuleNames.AddRange(
				new string[]
				{
					// ... add private dependencies that you statically link with here ...
				}
			);

			DynamicallyLoadedModuleNames.AddRange(
				new string[]
				{
					// ... add any modules that your module loads dynamically here ...
				}
			);

			var KlawrPath = Path.Combine(UEBuildConfiguration.UEThirdPartySourceDirectory, "Klawr");
			if (Directory.Exists(KlawrPath))
			{
				Definitions.Add("WITH_KLAWR=1");
				PrivateDependencyModuleNames.Add("KlawrClrHostNative");
			}
		}
        public ScriptGeneratorPlugin(TargetInfo Target)
        {
            PublicIncludePaths.AddRange(
                new string[] {
                    "Programs/UnrealHeaderTool/Public",
                    // ... add other public include paths required here ...
                }
                );

            PrivateIncludePaths.AddRange(
                new string[] {
                    "Developer/ScriptGeneratorPlugin/Private",
                    // ... add other private include paths required here ...
                }
                );

            PublicDependencyModuleNames.AddRange(
                new string[]
                {
                    "Core",
                    "CoreUObject",
                    // ... add other public dependencies that you statically link with here ...
                }
                );

            PrivateDependencyModuleNames.AddRange(
                new string[]
                {
                    // ... add private dependencies that you statically link with here ...
                }
                );

            DynamicallyLoadedModuleNames.AddRange(
                new string[]
                {
                    // ... add any modules that your module loads dynamically here ...
                }
                );

            if (!UnrealBuildTool.BuildingRocket())
            {
                // This checks only for UHT target platform, not the target platform of the game we're building so it's important
                // to make sure Lua is compiled for all supported platforms
                var LuaLibDirectory = Path.Combine("..", "Plugins", "ScriptPlugin", "Source", "Lua", "Lib", Target.Platform.ToString(), "Release");
                var LuaLibPath = Path.Combine(LuaLibDirectory, "Lua.lib");
                if (File.Exists(LuaLibPath))
                {
                    Log.TraceVerbose("ScriptGenerator LUA Integration enabled");
                    Definitions.Add("WITH_LUA=1");
                }
                else
                {
                    Log.TraceVerbose("ScriptGenerator LUA Integration NOT enabled");
                }
            }
        }
Ejemplo n.º 10
0
		public StructBox(TargetInfo Target)
		{
			PublicDependencyModuleNames.AddRange(
				new string[]
				{
					"Core",
					"CoreUObject",
					"Engine"
				}
			);
		}
    public SkookumScriptRuntime(TargetInfo Target)
    {

      // SkUEBindings.cpp takes a long time to compile due to auto-generated engine bindings
      // Set to true when actively working on this plugin, false otherwise
      bFasterWithoutUnity = false;

      // Add public include paths required here ...
      //PublicIncludePaths.AddRange(
      //  new string[] {          
      //    //"Programs/UnrealHeaderTool/Public",
      //    }
      //  );

      PrivateIncludePaths.Add("SkookumScriptRuntime/Private");

      // Add public dependencies that you statically link with here ...
      PublicDependencyModuleNames.AddRange(
        new string[]
          {
            "Core",
            "CoreUObject",
            "Engine",
            "UMG",
          }
        );

      if (UEBuildConfiguration.bBuildEditor == true)
      {
        PublicDependencyModuleNames.Add("UnrealEd");
      }

      // ... add private dependencies that you statically link with here ...
      PrivateDependencyModuleNames.AddRange(
        new string[]
          {
            "InputCore",
            "Sockets",
            "HTTP",
            "Networking",
            "NetworkReplayStreaming",
            "OnlineSubsystem",
            "MovieScene",
            "SlateCore",
            "Slate",
            "AgogCore",
            "SkookumScript"
          }
        );

      // Add any modules that your module loads dynamically here ...
      //DynamicallyLoadedModuleNames.AddRange(new string[] {});
    }
        public SkookumScriptRuntime(TargetInfo Target)
        {
            // SkUEBindings.cpp takes a long time to compile due to auto-generated engine bindings
              // Set to true when actively working on this plugin, false otherwise
              bFasterWithoutUnity = false;

              // Add public include paths required here ...
              PublicIncludePaths.Add("SkookumScriptRuntime/Public/Bindings");
              //PublicIncludePaths.AddRange(
              //  new string[] {
              //    //"Programs/UnrealHeaderTool/Public",
              //    }
              //  );

              PrivateIncludePaths.Add("SkookumScriptRuntime/Private");

              // Add public dependencies that you statically link with here ...
              PublicDependencyModuleNames.AddRange(
            new string[]
              {
            "Core",
            "CoreUObject",
            "Engine",
              }
            );

              if (UEBuildConfiguration.bBuildEditor == true)
              {
            PublicDependencyModuleNames.Add("UnrealEd");
              }

              // ... add private dependencies that you statically link with here ...
              PrivateDependencyModuleNames.AddRange(
            new string[]
              {
            "Sockets",
            "HTTP",
            "Networking",
            "NetworkReplayStreaming",
            "Projects",
              }
            );

              // Load SkookumScript.ini and add any ScriptSupportedModules specified to the list of PrivateDependencyModuleNames
              PrivateDependencyModuleNames.AddRange(GetSkookumScriptModuleNames(Path.Combine(ModuleDirectory, "../.."), false));

              // Add any modules that your module loads dynamically here ...
              //DynamicallyLoadedModuleNames.AddRange(new string[] {});
        }
Ejemplo n.º 13
0
		/// <summary>
		/// Modify the rules for a newly created module, in a target that's being built for this platform.
		/// This is not required - but allows for hiding details of a particular platform.
		/// </summary>
		/// <param name="ModuleName">The name of the module</param>
		/// <param name="Rules">The module rules</param>
		/// <param name="Target">The target being build</param>
		public override void ModifyModuleRulesForActivePlatform(string ModuleName, ModuleRules Rules, TargetInfo Target)
		{
			if (ModuleName == "Core")
			{
				Rules.PublicIncludePaths.Add("Runtime/Core/Public/HTML5");
				Rules.PublicDependencyModuleNames.Add("zlib");
			}
			else if (ModuleName == "Engine")
			{
				Rules.PrivateDependencyModuleNames.Add("zlib");
				Rules.PrivateDependencyModuleNames.Add("UElibPNG");
				Rules.PublicDependencyModuleNames.Add("UEOgg");
				Rules.PublicDependencyModuleNames.Add("Vorbis");
			}
		}
        public KlawrCodeGeneratorPlugin(TargetInfo Target)
        {
            PublicIncludePaths.AddRange(
                new string[] {
                    // FIXME: This path only works when building the plugin as part of the engine!
                    "Programs/UnrealHeaderTool/Public",
                    // ... add other public include paths required here ...
                }
            );

            PrivateIncludePaths.AddRange(
                new string[] {
                    // ... add other private include paths required here ...
                }
            );

            PublicDependencyModuleNames.AddRange(
                new string[]
                {
                    "Core",
                    "CoreUObject",
                    // ... add other public dependencies that you statically link with here ...
                }
            );

            PrivateDependencyModuleNames.AddRange(
                new string[]
                {
                    // ... add private dependencies that you statically link with here ...
                }
            );

            DynamicallyLoadedModuleNames.AddRange(
                new string[]
                {
                    // ... add any modules that your module loads dynamically here ...
                }
            );

            if (!UnrealBuildTool.BuildingRocket())
            {
                var KlawrPath = Path.Combine(UEBuildConfiguration.UEThirdPartySourceDirectory, "Klawr");
                if (Directory.Exists(KlawrPath))
                {
                    Definitions.Add("WITH_KLAWR=1");
                }
            }
        }
Ejemplo n.º 15
0
 public UTDomGameMode(TargetInfo Target)
 {
     PrivateIncludePaths.Add("UTDomGameMode/Private");
     PublicDependencyModuleNames.AddRange(
         new string[]
         {
             "Core",
             "CoreUObject",
             "Engine",
             "Navmesh",
             "UnrealTournament",
             "InputCore",
             "Slate",
             "SlateCore"
         }
         );
 }
Ejemplo n.º 16
0
		public override void AddExtraModules(TargetInfo Target, List<string> PlatformExtraModules)
		{
			bool bVulkanExists = IsVulkanSDKAvailable();
			if (bVulkanExists)
			{
				bool bSupportsVulkan = IsVulkanSupportEnabled();
				
				if (bSupportsVulkan)
				{
					PlatformExtraModules.Add("VulkanRHI");
				}
				else
				{
					Log.TraceInformationOnce("Vulkan SDK is installed, but the project disabled Vulkan (bSupportsVulkan setting in Engine). Disabling Vulkan RHI for Android");
				}
			}
		}
        public SkookumScriptGenerator(TargetInfo Target)
        {
            // We need ICU for regex use!
              UEBuildConfiguration.bCompileICU = true;

              PublicIncludePaths.AddRange(
            new string[] {
              "Programs/UnrealHeaderTool/Public",
              // ... add other public include paths required here ...
            }
            );

              PrivateIncludePaths.AddRange(
            new string[] {
              // "Developer/SkookumScriptGenerator/Private",
              // ... add other private include paths required here ...
            }
            );

              PublicDependencyModuleNames.AddRange(
            new string[]
            {
              "Core",
              "CoreUObject",
              // ... add other public dependencies that you statically link with here ...
            }
            );

              PrivateDependencyModuleNames.AddRange(
            new string[]
            {
              // ... add private dependencies that you statically link with here ...
            }
            );

              DynamicallyLoadedModuleNames.AddRange(
            new string[]
            {
              // ... add any modules that your module loads dynamically here ...
            }
            );
        }
Ejemplo n.º 18
0
        public override void SetupDefaultGlobalEnvironment(
			TargetInfo Target,
			ref LinkEnvironmentConfiguration OutLinkEnvironmentConfiguration,
			ref CPPEnvironmentConfiguration OutCPPEnvironmentConfiguration
			)
        {
            if (Target.Platform == UnrealTargetPlatform.Mac)
            {
                UEBuildConfiguration.bCompileNetworkProfiler = false;
            }
            else
            {
                UEBuildConfiguration.bCompileNetworkProfiler = true;
            }

            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 'Game' build
            OutCPPEnvironmentConfiguration.Definitions.Add("UE_GAME=1");

            // no exports, so no need to verify that a .lib and .exp file was emitted by the linker.
            OutLinkEnvironmentConfiguration.bHasExports = false;

            // Mark it as a Rocket build
            if (UnrealBuildTool.BuildingRocket() || UnrealBuildTool.RunningRocket())
            {
                OutCPPEnvironmentConfiguration.Definitions.Add("UE_ROCKET=1");
            }
        }
        public UDKImportPlugin(TargetInfo Target)
        {
            PublicDependencyModuleNames.AddRange(
                new string[] {
                    "Core",
                    "Engine",
                    "UnrealEd",
                    "CoreUObject",		// @todo Mac: for some reason CoreUObject and Engine are needed to link in debug on Mac
                    "InputCore",
                    "SlateCore",
                    "Slate"
                }
            );

            PrivateDependencyModuleNames.AddRange(
                new string[] {
                    "EditorStyle",
                    "Projects",
                    "LevelEditor",
                    "AssetTools",
                }
            );
        }
Ejemplo n.º 20
0
		public OpenGEXParser(TargetInfo Target)
		{
			Type = ModuleType.External;

			var bPlatformAllowed = (Target.Platform == UnrealTargetPlatform.Win64);

			if (bPlatformAllowed)
			{
				string OpenGEXParserPath = ModulePath + "/opengex-parser/";
				PublicIncludePaths.Add(OpenGEXParserPath + "include");
				
				string ThirdPartyBinariesPath = ModulePath + "/bin/";

				if (Target.Platform == UnrealTargetPlatform.Win64)
				{
					if (WindowsPlatform.Compiler == WindowsCompiler.VisualStudio2015)
					{
						if (Target.Configuration == UnrealTargetConfiguration.Debug)
						{
                            PublicLibraryPaths.Add(OpenGEXParserPath + "lib/x64/VS2015/Debug/");

                            PublicAdditionalLibraries.Add("opengex-parser_Debug.lib");

                            PublicDelayLoadDLLs.Add("opengex-parser_Debug.dll");
                        }
						else
						{
                            PublicLibraryPaths.Add(OpenGEXParserPath + "lib/x64/VS2015/Release/");

                            PublicAdditionalLibraries.Add("opengex-parser_Release.lib");

                            PublicDelayLoadDLLs.Add("opengex-parser_Release.dll");
                        }
					}
				}
			}
		}
Ejemplo n.º 21
0
		public override void SetupDefaultGlobalEnvironment(
			TargetInfo Target,
			ref LinkEnvironmentConfiguration OutLinkEnvironmentConfiguration,
			ref CPPEnvironmentConfiguration OutCPPEnvironmentConfiguration
			)
		{
			UEBuildConfiguration.bCompileLeanAndMeanUE = false;

			// Do not include the editor
			UEBuildConfiguration.bBuildEditor = true;
			UEBuildConfiguration.bBuildWithEditorOnlyData = true;

			// Require cooked data
			UEBuildConfiguration.bBuildRequiresCookedData = false;

			// Compile the engine
			UEBuildConfiguration.bCompileAgainstEngine = true;

            //enable PerfCounters
            UEBuildConfiguration.bWithPerfCounters = true;

            // Tag it as a 'Editor' build
            OutCPPEnvironmentConfiguration.Definitions.Add("UE_EDITOR=1");
		}
        public SanwuBPFunctionLibraryPlugin(TargetInfo Target)
        {
            PrivateIncludePaths.AddRange(
                new string[] {
                    "SanwuBPFunctionLibraryPlugin/Private"
                });
            PublicIncludePaths.AddRange(
                new string[] {
                    "SanwuBPFunctionLibraryPlugin/Public"
                });

            PublicDependencyModuleNames.AddRange(
                new string[]
                {
                    "Core",
                    "CoreUObject",
                    "Engine",
                    "InputCore",
                    "RHI",
                    "Sockets",
                    "Networking",
                    "HTTP"
                });
        }
Ejemplo n.º 23
0
        public override void SetupDefaultGlobalEnvironment(
			TargetInfo Target,
			ref LinkEnvironmentConfiguration OutLinkEnvironmentConfiguration,
			ref CPPEnvironmentConfiguration OutCPPEnvironmentConfiguration
			)
        {
            // Dedicated server
            UEBuildConfiguration.bBuildDedicatedServer = true;
            if (Target.Platform == UnrealTargetPlatform.Mac)
            {
                UEBuildConfiguration.bCompileNetworkProfiler = false;
            }
            else
            {
                UEBuildConfiguration.bCompileNetworkProfiler = true;
            }

            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;
        }
Ejemplo n.º 24
0
 /**
  *	Get a list of extra modules the platform requires.
  *	This is to allow undisclosed platforms to add modules they need without exposing information about the platfomr.
  *
  *	@param	Target						The target being build
  *	@param	BuildTarget					The UEBuildTarget getting build
  *	@param	PlatformExtraModules		OUTPUT the list of extra modules the platform needs to add to the target
  */
 public override void GetExtraModules(TargetInfo Target, UEBuildTarget BuildTarget, ref List<string> PlatformExtraModules)
 {
     if (Target.Platform == UnrealTargetPlatform.WinRT)
     {
         PlatformExtraModules.Add("XAudio2");
     }
 }
Ejemplo n.º 25
0
		/// <summary>
		/// Allows the target to specify modules which can be precompiled with the -Precompile/-UsePrecompiled arguments to UBT. 
		/// All dependencies of the specified modules will be included.
		/// </summary>
		/// <param name="Target">The target information, such as platform and configuration</param>
		/// <param name="ModuleNames">List which receives module names to precompile</param>
		public virtual void GetModulesToPrecompile(TargetInfo Target, List<string> ModuleNames)
		{
		}
Ejemplo n.º 26
0
		/// <summary>
		/// Allows a target to choose whether to use the shared build environment for a given configuration. Using
		/// the shared build environment allows binaries to be reused between targets, but prevents customizing the
		/// compile environment through SetupGlobalEnvironment().
		/// </summary>
		/// <param name="Target">Information about the target</param>
		/// <returns>True if the target should use the shared build environment</returns>
		public virtual bool ShouldUseSharedBuildEnvironment(TargetInfo Target)
		{
			return UnrealBuildTool.RunningRocket() || (Target.Type != TargetType.Program && !Target.IsMonolithic);
		}
Ejemplo n.º 27
0
		/// <summary>
		/// Setup the global environment for building this target
		/// IMPORTANT: Game targets will *not* have this function called if they use the shared build environment.
		/// See ShouldUseSharedBuildEnvironment().
		/// </summary>
		/// <param name="Target">The target information - such as platform and configuration</param>
		/// <param name="OutLinkEnvironmentConfiguration">Output link environment settings</param>
		/// <param name="OutCPPEnvironmentConfiguration">Output compile environment settings</param>
		public virtual void SetupGlobalEnvironment(
			TargetInfo Target,
			ref LinkEnvironmentConfiguration OutLinkEnvironmentConfiguration,
			ref CPPEnvironmentConfiguration OutCPPEnvironmentConfiguration
			)
		{
		}
Ejemplo n.º 28
0
		/// <summary>
		/// Setup the binaries associated with this target.
		/// </summary>
		/// <param name="Target">The target information - such as platform and configuration</param>
		/// <param name="OutBuildBinaryConfigurations">Output list of binaries to generated</param>
		/// <param name="OutExtraModuleNames">Output list of extra modules that this target could utilize</param>
		public virtual void SetupBinaries(
			TargetInfo Target,
			ref List<UEBuildBinaryConfiguration> OutBuildBinaryConfigurations,
			ref List<string> OutExtraModuleNames
			)
		{
		}
        /// <summary>
        /// Modify the rules for a newly created module, where the target is a different host platform.
        /// This is not required - but allows for hiding details of a particular platform.
        /// </summary>
        /// <param name="ModuleName">The name of the module</param>
        /// <param name="Rules">The module rules</param>
        /// <param name="Target">The target being build</param>
        public override void ModifyModuleRulesForOtherPlatform(string ModuleName, ModuleRules Rules, TargetInfo Target)
        {
            if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64))
            {
                if (!UEBuildConfiguration.bBuildRequiresCookedData)
                {
                    if (ModuleName == "Engine")
                    {
                        if (UEBuildConfiguration.bBuildDeveloperTools)
                        {
                            Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxTargetPlatform");
                            Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxNoEditorTargetPlatform");
                            Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxClientTargetPlatform");
                            Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxServerTargetPlatform");
                        }
                    }
                }

                // allow standalone tools to use targetplatform modules, without needing Engine
                if (UEBuildConfiguration.bForceBuildTargetPlatforms && ModuleName == "TargetPlatform")
                {
                    Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxTargetPlatform");
                    Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxNoEditorTargetPlatform");
                    Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxClientTargetPlatform");
                    Rules.PlatformSpecificDynamicallyLoadedModuleNames.Add("LinuxServerTargetPlatform");
                }
            }
        }
Ejemplo n.º 30
0
        /**
         *	Modify the newly created module passed in for this platform.
         *	This is not required - but allows for hiding details of a
         *	particular platform.
         *
         *	@param	InModule		The newly loaded module
         *	@param	Target			The target being build
         */
        public override void ModifyNewlyLoadedModule(UEBuildModule InModule, TargetInfo Target)
        {
            if ((Target.Platform == UnrealTargetPlatform.WinRT) ||
                (Target.Platform == UnrealTargetPlatform.WinRT_ARM))
            {
                if (InModule.ToString() == "Core")
                {
                    InModule.AddPublicIncludePath("Runtime/Core/Public/WinRT");
                    InModule.AddPublicDependencyModule("zlib");
                }
                else if (InModule.ToString() == "Engine")
                {
                    InModule.AddPrivateDependencyModule("zlib");
                    InModule.AddPrivateDependencyModule("UElibPNG");
                    InModule.AddPublicDependencyModule("UEOgg");
                    InModule.AddPublicDependencyModule("Vorbis");
                }
                else if (InModule.ToString() == "Launch")
                {
                }
                else if (InModule.ToString() == "D3D11RHI")
                {
                    InModule.AddPublicDefinition("D3D11_CUSTOM_VIEWPORT_CONSTRUCTOR=1");
                    // To enable platform specific D3D11 RHI Types
                    InModule.AddPrivateIncludePath("Runtime/Windows/D3D11RHI/Private/WinRT");
                    // Hack to enable AllowWindowsPlatformTypes.h/HideWindowsPlatformTypes.h
                    InModule.AddPublicIncludePath("Runtime/Core/Public/Windows");
                }
                else if (InModule.ToString() == "Sockets")
                {
                    // Hack to enable AllowWindowsPlatformTypes.h/HideWindowsPlatformTypes.h
                    InModule.AddPublicIncludePath("Runtime/Core/Public/Windows");
                }
                else if (InModule.ToString() == "PhysX")
                {
                    string PhysXDir = UEBuildConfiguration.UEThirdPartySourceDirectory + "PhysX/PhysX-3.3/";

                    InModule.AddPublicIncludePath("include/foundation/WinRT");
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(PhysXDir + "Lib/WinRT");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(PhysXDir + "Lib/WinRT/ARM");
                    }

                    if (Target.Configuration == UnrealTargetConfiguration.Debug)
                    {
                        InModule.AddPublicAdditionalLibrary("PhysX3DEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3ExtensionsDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3CookingDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3CommonDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3VehicleDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("PxTaskDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("PhysXVisualDebuggerSDKDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("PhysXProfileSDKDEBUG.lib");
                    }
                    else if (Target.Configuration == UnrealTargetConfiguration.Development)
                    {
                        InModule.AddPublicAdditionalLibrary("PhysX3PROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3ExtensionsPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3CookingPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3CommonPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3VehiclePROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("PxTaskPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("PhysXVisualDebuggerSDKPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("PhysXProfileSDKPROFILE.lib");
                    }
                    else // Test or Shipping
                    {
                        InModule.AddPublicAdditionalLibrary("PhysX3.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3Extensions.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3Cooking.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3Common.lib");
                        InModule.AddPublicAdditionalLibrary("PhysX3Vehicle.lib");
                        InModule.AddPublicAdditionalLibrary("PxTask.lib");
                        InModule.AddPublicAdditionalLibrary("PhysXVisualDebuggerSDK.lib");
                        InModule.AddPublicAdditionalLibrary("PhysXProfileSDK.lib");
                    }
                }
                else if (InModule.ToString() == "APEX")
                {
                    InModule.RemovePublicDefinition("APEX_STATICALLY_LINKED=0");
                    InModule.AddPublicDefinition("APEX_STATICALLY_LINKED=1");

                    string APEXDir = UEBuildConfiguration.UEThirdPartySourceDirectory + "PhysX/APEX-1.3/";
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(APEXDir + "lib/WinRT");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(APEXDir + "lib/WinRT/ARM");
                    }

                    if (Target.Configuration == UnrealTargetConfiguration.Debug)
                    {
                        InModule.AddPublicAdditionalLibrary("ApexCommonDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("ApexFrameworkDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("ApexSharedDEBUG.lib");
                        InModule.AddPublicAdditionalLibrary("APEX_DestructibleDEBUG.lib");

                    }
                    else if (Target.Configuration == UnrealTargetConfiguration.Development)
                    {
                        InModule.AddPublicAdditionalLibrary("ApexCommonPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("ApexFrameworkPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("ApexSharedPROFILE.lib");
                        InModule.AddPublicAdditionalLibrary("APEX_DestructiblePROFILE.lib");
                    }
                    else // Test or Shipping
                    {
                        InModule.AddPublicAdditionalLibrary("ApexCommon.lib");
                        InModule.AddPublicAdditionalLibrary("ApexFramework.lib");
                        InModule.AddPublicAdditionalLibrary("ApexShared.lib");
                        InModule.AddPublicAdditionalLibrary("APEX_Destructible.lib");
                    }
                }
                else if (InModule.ToString() == "FreeType2")
                {
                    string FreeType2Path = UEBuildConfiguration.UEThirdPartySourceDirectory + "FreeType2/FreeType2-2.4.12/";
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(FreeType2Path + "Lib/WinRT/Win64");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(FreeType2Path + "Lib/WinRT/ARM");
                    }
                    InModule.AddPublicAdditionalLibrary("freetype2412MT.lib");
                }
                else if (InModule.ToString() == "UElibPNG")
                {
                    string libPNGPath = UEBuildConfiguration.UEThirdPartySourceDirectory + "libPNG/libPNG-1.5.2";
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(libPNGPath + "/lib/WinRT/Win64");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(libPNGPath + "/lib/WinRT/ARM");
                    }
                    InModule.AddPublicAdditionalLibrary("libpng125.lib");
                }
                else if (InModule.ToString() == "DX11")
                {
                    // Clear out all the Windows include paths and libraries...
                    // The WinRTSDK module handles proper paths and libs for WinRT.
                    // However, the D3D11RHI module will include the DX11 module.
                    InModule.ClearPublicIncludePaths();
                    InModule.ClearPublicLibraryPaths();
                    InModule.ClearPublicAdditionalLibraries();
                    InModule.RemovePublicDefinition("WITH_D3DX_LIBS=1");
                    InModule.AddPublicDefinition("D3D11_WITH_DWMAPI=0");
                    InModule.AddPublicDefinition("WITH_D3DX_LIBS=0");
                    InModule.AddPublicDefinition("WITH_DX_PERF=0");
                    InModule.RemovePublicAdditionalLibrary("X3DAudio.lib");
                    InModule.RemovePublicAdditionalLibrary("XAPOFX.lib");
                }
                else if (InModule.ToString() == "XInput")
                {
                    InModule.AddPublicAdditionalLibrary("XInput.lib");
                }
                else if (InModule.ToString() == "XAudio2")
                {
                    InModule.AddPublicDefinition("XAUDIO_SUPPORTS_XMA2WAVEFORMATEX=0");
                    InModule.AddPublicDefinition("XAUDIO_SUPPORTS_DEVICE_DETAILS=0");
                    InModule.AddPublicDefinition("XAUDIO2_SUPPORTS_MUSIC=0");
                    InModule.AddPublicDefinition("XAUDIO2_SUPPORTS_SENDLIST=0");
                    InModule.AddPublicAdditionalLibrary("XAudio2.lib");
                    // Hack to enable AllowWindowsPlatformTypes.h/HideWindowsPlatformTypes.h
                    InModule.AddPublicIncludePath("Runtime/Core/Public/Windows");
                }
                else if (InModule.ToString() == "UEOgg")
                {
                    string OggPath = UEBuildConfiguration.UEThirdPartySourceDirectory + "Ogg/libogg-1.2.2/";
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(OggPath + "WinRT/VS2012/WinRT/x64/Release");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(OggPath + "WinRT/VS2012/WinRT/ARM/Release");
                    }
                    InModule.AddPublicAdditionalLibrary("libogg_static.lib");
                }
                else if (InModule.ToString() == "Vorbis")
                {
                    string VorbisPath = UEBuildConfiguration.UEThirdPartySourceDirectory + "Vorbis/libvorbis-1.3.2/";
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(VorbisPath + "WinRT/VS2012/WinRT/x64/Release");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(VorbisPath + "WinRT/VS2012/WinRT/ARM/Release");
                    }
                    InModule.AddPublicAdditionalLibrary("libvorbis_static.lib");
                }
                else if (InModule.ToString() == "VorbisFile")
                {
                    string VorbisPath = UEBuildConfiguration.UEThirdPartySourceDirectory + "Vorbis/libvorbis-1.3.2/";
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(VorbisPath + "WinRT/VS2012/WinRT/x64/Release");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(VorbisPath + "WinRT/VS2012/WinRT/ARM/Release");
                    }
                    InModule.AddPublicAdditionalLibrary("libvorbisfile_static.lib");
                }
                else if (InModule.ToString() == "DX11Audio")
                {
                    InModule.RemovePublicAdditionalLibrary("X3DAudio.lib");
                    InModule.RemovePublicAdditionalLibrary("XAPOFX.lib");
                }
                else if (InModule.ToString() == "zlib")
                {
                    if (Target.Platform == UnrealTargetPlatform.WinRT)
                    {
                        InModule.AddPublicLibraryPath(UEBuildConfiguration.UEThirdPartySourceDirectory + "zlib/zlib-1.2.5/Lib/WinRT/Win64");
                    }
                    else
                    {
                        InModule.AddPublicLibraryPath(UEBuildConfiguration.UEThirdPartySourceDirectory + "zlib/zlib-1.2.5/Lib/WinRT/ARM");
                    }
                    InModule.AddPublicAdditionalLibrary("zlib125.lib");
                }
            }
            else if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64))
            {
            //              bool bBuildShaderFormats = UEBuildConfiguration.bForceBuildShaderFormats;
            // 				if (!UEBuildConfiguration.bBuildRequiresCookedData)
            // 				{
            // 					if (InModule.ToString() == "Engine")
            // 					{
            // 						if (UEBuildConfiguration.bBuildDeveloperTools)
            // 						{
                // 							InModule.AddPlatformSpecificDynamicallyLoadedModule("WinRTTargetPlatform");
            // 						}
            // 					}
            // 					else if (InModule.ToString() == "TargetPlatform")
            // 					{
            // 		                bBuildShaderFormats = true;
            // 					}
            // 				}

            // 				// allow standalone tools to use targetplatform modules, without needing Engine
            // 				if (UEBuildConfiguration.bForceBuildTargetPlatforms)
            // 				{
                // 					InModule.AddPlatformSpecificDynamicallyLoadedModule("WinRTTargetPlatform");
            // 				}

            //              if (bBuildShaderFormats)
            //              {
                //                  InModule.AddPlatformSpecificDynamicallyLoadedModule("ShaderFormatWinRT");
            //              }
            }
        }
        /// <summary>
        /// Modify the rules for a newly created module, in a target that's being built for this platform.
        /// This is not required - but allows for hiding details of a particular platform.
        /// </summary>
        /// <param name="ModuleName">The name of the module</param>
        /// <param name="Rules">The module rules</param>
        /// <param name="Target">The target being build</param>
        public override void ModifyModuleRulesForActivePlatform(string ModuleName, ModuleRules Rules, TargetInfo Target)
        {
            bool bBuildShaderFormats = UEBuildConfiguration.bForceBuildShaderFormats;

            if (!UEBuildConfiguration.bBuildRequiresCookedData)
            {
                if (ModuleName == "TargetPlatform")
                {
                    bBuildShaderFormats = true;
                }
            }

            // allow standalone tools to use target platform modules, without needing Engine
            if (ModuleName == "TargetPlatform")
            {
                if (UEBuildConfiguration.bForceBuildTargetPlatforms)
                {
                    Rules.DynamicallyLoadedModuleNames.Add("LinuxTargetPlatform");
                    Rules.DynamicallyLoadedModuleNames.Add("LinuxNoEditorTargetPlatform");
                    Rules.DynamicallyLoadedModuleNames.Add("LinuxClientTargetPlatform");
                    Rules.DynamicallyLoadedModuleNames.Add("LinuxServerTargetPlatform");
                    Rules.DynamicallyLoadedModuleNames.Add("AllDesktopTargetPlatform");
                }

                if (bBuildShaderFormats)
                {
                    // Rules.DynamicallyLoadedModuleNames.Add("ShaderFormatD3D");
                    Rules.DynamicallyLoadedModuleNames.Add("ShaderFormatOpenGL");
                }
            }
            else if (ModuleName == "Launch")
            {
                // this is a hack to influence symbol resolution on Linux that results in global delete being called from within CEF
                if (!Target.IsMonolithic && UEBuildConfiguration.bCompileCEF3)
                {
                    Rules.AddEngineThirdPartyPrivateStaticDependencies(Target, "CEF3");
                }
            }
        }
Ejemplo n.º 32
-1
        public override void ModifyNewlyLoadedModule(UEBuildModule InModule, TargetInfo Target)
        {
            if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64))
            {
                bool bBuildShaderFormats = UEBuildConfiguration.bForceBuildShaderFormats;

                if (!UEBuildConfiguration.bBuildRequiresCookedData)
                {
                    if (InModule.ToString() == "TargetPlatform")
                    {
                        bBuildShaderFormats = true;
                    }
                }

                // allow standalone tools to use target platform modules, without needing Engine
                if (UEBuildConfiguration.bForceBuildTargetPlatforms)
                {
                    InModule.AddDynamicallyLoadedModule("WindowsTargetPlatform");
                    InModule.AddDynamicallyLoadedModule("WindowsNoEditorTargetPlatform");
                    InModule.AddDynamicallyLoadedModule("WindowsServerTargetPlatform");
                    InModule.AddDynamicallyLoadedModule("WindowsClientTargetPlatform");
					InModule.AddDynamicallyLoadedModule("AllDesktopTargetPlatform");
                }

                if (bBuildShaderFormats)
                {
                    InModule.AddDynamicallyLoadedModule("ShaderFormatD3D");
                    InModule.AddDynamicallyLoadedModule("ShaderFormatOpenGL");

//#todo-rco: Remove when public
					{
						string VulkanSDKPath = Environment.GetEnvironmentVariable("VulkanSDK");
						if (!String.IsNullOrEmpty(VulkanSDKPath))
						{
							InModule.AddDynamicallyLoadedModule("VulkanShaderFormat");
						}
					}
				}

                if (InModule.ToString() == "D3D11RHI")
                {
                    // To enable platform specific D3D11 RHI Types
                    InModule.AddPrivateIncludePath("Runtime/Windows/D3D11RHI/Private/Windows");
                }

				if (InModule.ToString() == "D3D12RHI")
				{
					// To enable platform specific D3D12 RHI Types
					InModule.AddPrivateIncludePath("Runtime/Windows/D3D12RHI/Private/Windows");
				}
			}
        }