private void ProcessDependencies(string depsJson, ReadOnlyTargetRules target) { //We need to ensure libraries end with ".lib" under Windows string libSuffix = ((this.IsWindows(target)) ? ".lib" : ""); //Attempt to parse the JSON file JsonObject deps = JsonObject.Read(new FileReference(depsJson)); //Process the list of dependencies foreach (JsonObject dep in deps.GetObjectArrayField("dependencies")) { //Add the header and library paths for the dependency package PublicIncludePaths.AddRange(dep.GetStringArrayField("include_paths")); PublicLibraryPaths.AddRange(dep.GetStringArrayField("lib_paths")); //Add the preprocessor definitions from the dependency package PublicDefinitions.AddRange(dep.GetStringArrayField("defines")); //Link against the libraries from the package string[] libs = dep.GetStringArrayField("libs"); foreach (string lib in libs) { string libFull = lib + ((libSuffix.Length == 0 || lib.EndsWith(libSuffix)) ? "" : libSuffix); PublicAdditionalLibraries.Add(libFull); } } }
public void LoadOpenCVLib(ReadOnlyTargetRules Target) { if (Target.Platform == UnrealTargetPlatform.Win64) { string OpenCVLibPath = Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "opencv", "x64", "vc15"); //Add the import library PublicLibraryPaths.AddRange( new string[] { Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "opencv", "x64", "vc15", "lib") }); PublicAdditionalLibraries.Add("opencv_world341.lib"); PublicIncludePaths.AddRange(new string[] { Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "opencv", "include") }); //Delay - load the DLL, so we can load it from the right place first PublicDelayLoadDLLs.Add("opencv_world341.dll"); // Add a Runtime Dependency so the DLLs will be packaged correctly RuntimeDependencies.Add(Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "opencv", "x64", "vc15", "bin", "opencv_world341.dll")); RuntimeDependencies.Add(Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "opencv", "x64", "vc15", "bin", "opencv_ffmpeg341_64.dll")); } else if (Target.Platform == UnrealTargetPlatform.Mac) { PublicDelayLoadDLLs.Add(Path.Combine(ModuleDirectory, "Mac", "Release", "opencv_world341.dylib")); } }
public discordrpc(ReadOnlyTargetRules Target) : base(Target) { Definitions.Add("DISCORD_DYNAMIC_LIB=1"); PCHUsage = ModuleRules.PCHUsageMode.UseExplicitOrSharedPCHs; PublicIncludePaths.AddRange( new string[] { "discordrpc/Public" // ... add public include paths required here ... } ); PrivateIncludePaths.AddRange( new string[] { "discordrpc/Private", "../../../../../include" // ... add other private include paths required here ... } ); PublicLibraryPaths.AddRange( new string[] { System.IO.Path.Combine(ModuleDirectory, "../../Binaries/ThirdParty/discordrpcLibrary/", Target.Platform.ToString()), } ); PublicDependencyModuleNames.AddRange( new string[] { "CoreUObject", "Engine", "Slate", "SlateCore", "Core", "discordrpcLibrary", "Projects" // ... 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 ... } ); }
public llvm(TargetInfo Target) { Type = ModuleType.External; if (Target.Platform != UnrealTargetPlatform.Win32) { // Currently we support only Win32 llvm builds. return; } var LLVMVersion = @"3.5.0"; var VSVersion = @"vs2013"; var TargetArch = @"x86"; var RootDirectory = Path.Combine(UEBuildConfiguration.UEThirdPartySourceDirectory, @"llvm", LLVMVersion); PublicIncludePaths.AddRange( new string[] { Path.Combine(RootDirectory, "include"), }); PublicLibraryPaths.AddRange( new string[] { Path.Combine(RootDirectory, @"lib", VSVersion, TargetArch, @"release"), }); PublicAdditionalLibraries.AddRange( new string[] { "clangAnalysis.lib", "clangAST.lib", "clangBasic.lib", "clangDriver.lib", "clangEdit.lib", "clangFrontend.lib", "clangLex.lib", "clangParse.lib", "clangSema.lib", "clangSerialization.lib", "clangTooling.lib", "LLVMAnalysis.lib", "LLVMBitReader.lib", "LLVMCodegen.lib", "LLVMCore.lib", "LLVMMC.lib", "LLVMMCDisassembler.lib", "LLVMMCParser.lib", "LLVMObject.lib", "LLVMOption.lib", "LLVMSupport.lib", "LLVMTarget.lib", "LLVMX86AsmParser.lib", "LLVMX86AsmPrinter.lib", "LLVMX86CodeGen.lib", "LLVMX86Desc.lib", "LLVMX86Info.lib", "LLVMX86Utils.lib", }); }
public libdraco_ue4(ReadOnlyTargetRules Target) : base(Target) { Type = ModuleType.External; string DracoPath = System.IO.Path.Combine(ModuleDirectory, "libdraco-1.3.0"); string IncludePath = System.IO.Path.Combine(DracoPath, "include"); List <string> LibPaths = new List <string>(); List <string> LibFilePaths = new List <string>(); if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64)) { string PlatformName = ""; #if UE_4_23_OR_LATER if (Target.Platform == UnrealTargetPlatform.Win32) { PlatformName = "win32"; } else if (Target.Platform == UnrealTargetPlatform.Win64) { PlatformName = "win64"; } #else switch (Target.Platform) { case UnrealTargetPlatform.Win32: PlatformName = "win32"; break; case UnrealTargetPlatform.Win64: PlatformName = "win64"; break; } #endif string LibPath = System.IO.Path.Combine(DracoPath, "lib", PlatformName, "vs2019", "Release"); LibPaths.Add(LibPath); LibFilePaths.Add(System.IO.Path.Combine(LibPath, "dracodec.lib")); LibFilePaths.Add(System.IO.Path.Combine(LibPath, "dracoenc.lib")); } else if (Target.Platform == UnrealTargetPlatform.Mac) { string LibPath = System.IO.Path.Combine(DracoPath, "lib", "macos"); LibPaths.Add(LibPath); LibFilePaths.Add(System.IO.Path.Combine(LibPath, "dracodec.a")); LibFilePaths.Add(System.IO.Path.Combine(LibPath, "dracoenc.a")); } PublicIncludePaths.Add(IncludePath); #if UE_4_24_OR_LATER PublicSystemLibraryPaths.AddRange(LibPaths); #else PublicLibraryPaths.AddRange(LibPaths); #endif PublicAdditionalLibraries.AddRange(LibFilePaths); }
public libgltf_ue4(ReadOnlyTargetRules Target) : base(Target) { Type = ModuleType.External; string glTFPath = System.IO.Path.Combine(ModuleDirectory, "libgltf-0.1.8"); string IncludePath = System.IO.Path.Combine(glTFPath, "include"); List <string> LibPaths = new List <string>(); string LibFilePath = ""; if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64)) { string PlatformName = ""; #if UE_4_23_OR_LATER if (Target.Platform == UnrealTargetPlatform.Win32) { PlatformName = "win32"; } else if (Target.Platform == UnrealTargetPlatform.Win64) { PlatformName = "win64"; } #else switch (Target.Platform) { case UnrealTargetPlatform.Win32: PlatformName = "win32"; break; case UnrealTargetPlatform.Win64: PlatformName = "win64"; break; } #endif string LibPath = System.IO.Path.Combine(glTFPath, "lib", PlatformName, "vs2019", "Release"); LibPaths.Add(LibPath); LibFilePath = System.IO.Path.Combine(LibPath, "libgltf.lib"); } else if (Target.Platform == UnrealTargetPlatform.Mac) { string LibPath = System.IO.Path.Combine(glTFPath, "lib", "macos"); LibPaths.Add(LibPath); LibFilePath = System.IO.Path.Combine(LibPath, "libgltf.a"); } PublicIncludePaths.Add(IncludePath); #if UE_4_24_OR_LATER PublicSystemLibraryPaths.AddRange(LibPaths); #else PublicLibraryPaths.AddRange(LibPaths); #endif PublicAdditionalLibraries.Add(LibFilePath); PublicDefinitions.Add("LIBGLTF_CHARACTOR_ENCODING_IS_UTF8"); }
public void LoadSIMPLELib(ReadOnlyTargetRules Target) { if (Target.Platform == UnrealTargetPlatform.Win64) { string SIMPLELibPath = Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "SIMPLE"); //Add the import library PublicLibraryPaths.AddRange( new string[] { Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "SIMPLE", "lib", "Win64"), Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "zeromq", "lib", "Win64") }); PublicAdditionalLibraries.Add("simple.lib"); PublicAdditionalLibraries.Add("simple_msgs.lib"); PublicAdditionalLibraries.Add("libzmq-mt-4_3_1.lib"); PublicIncludePaths.AddRange(new string[] { Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "SIMPLE", "include"), Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "zeromq", "include"), Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "flatbuffers", "include"), }); // Add a Runtime Dependency so the DLLs will be packaged correctly // Note: SIMPLE cannot be delay-loaded due to the use of static variables, it seems. This means it has to be present // in the Binaries folder at Engine startup RuntimeDependencies.Add(Path.Combine(ModuleDirectory, "..", "..", "Binaries", "Win64", "simple.dll")); RuntimeDependencies.Add(Path.Combine(ModuleDirectory, "..", "..", "Binaries", "Win64", "libzmq-mt-4_3_1.dll")); } else if (Target.Platform == UnrealTargetPlatform.Mac) { string SIMPLELibPath = Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "Mac", "SIMPLE"); //Add the import library PublicLibraryPaths.AddRange( new string[] { Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "SIMPLE", "lib", "Mac"), Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "zeromq", "lib", "Mac") }); PublicAdditionalLibraries.Add(Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "SIMPLE", "lib", "Mac", "libsimple-static.a")); PublicAdditionalLibraries.Add(Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "SIMPLE", "lib", "Mac", "libsimple_msgs.a")); PublicAdditionalLibraries.Add(Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "zeromq", "lib", "Mac", "libzmq.a")); PublicIncludePaths.AddRange(new string[] { Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "SIMPLE", "include"), Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "zeromq", "include"), Path.Combine(ModuleDirectory, "..", "..", "ThirdParty", "flatbuffers", "include"), }); RuntimeDependencies.Add(Path.Combine(ModuleDirectory, "..", "..", "Binaries", "Mac", "libsimple.dylib")); RuntimeDependencies.Add(Path.Combine(ModuleDirectory, "..", "..", "Binaries", "Mac", "libzmq.dylib")); } }
public UtyMapUnreal(TargetInfo Target) { PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "ShaderCore", "RenderCore", "RHI", "RuntimeMeshComponent" }); // Add all subdirecotries of Utymap layer to include path var UnrealLayerPath = Path.Combine(ModuleDirectory, "UnrealLayer"); foreach (var SubFolder in Directory.EnumerateDirectories(UnrealLayerPath, "*", SearchOption.AllDirectories)) { PublicIncludePaths.Add(SubFolder); } // turn on RTTI for packed vertices in RuntimeMeshCompoenent (used for multiple UVs) bUseRTTI = true; // enable exception hanlding for UtyMap library UEBuildConfiguration.bForceEnableExceptions = true; // UtyMap core include dirs var UtyMapPath = "C:/workspace/UnrealProjects/utymap_max/core"; PublicIncludePaths.Add(Path.Combine(UtyMapPath, "lib")); PublicIncludePaths.Add(Path.Combine(UtyMapPath, "shared")); PublicIncludePaths.Add(Path.Combine(UtyMapPath, "src")); // boost for UtyMap var BoostIncludeDir = "C:/workspace/UnrealProjects/libraries/boost_1_62_0"; PublicIncludePaths.Add(BoostIncludeDir); // setup DLL usage Definitions.AddRange( new string[] { "UTYMAP_USING_DLL" } ); PublicLibraryPaths.AddRange( new string[] { "C:/workspace/UnrealProjects/utymap_max/build/shared/Release" } ); PublicAdditionalLibraries.AddRange( new string[] { "UtyMap.Shared.lib" } ); PublicDelayLoadDLLs.Add("UtyMap.Shared.dll"); }
public UnrealXunFeiSpeech(ReadOnlyTargetRules Target) : base(Target) { PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs; PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "Json" }); PrivateDependencyModuleNames.AddRange(new string[] { }); // Uncomment if you are using Slate UI // PrivateDependencyModuleNames.AddRange(new string[] { "Slate", "SlateCore" }); // Uncomment if you are using online features // PrivateDependencyModuleNames.Add("OnlineSubsystem"); // To include OnlineSubsystemSteam, add it to the plugins section in your uproject file with the Enabled attribute set to true PrivateIncludePaths.Add("UnrealXunFeiSpeech/Private"); PublicIncludePaths.Add("UnrealXunFeiSpeech/Public"); PublicLibraryPaths.AddRange(new string[] { "..\\XunFei\\libs" }); PublicAdditionalLibraries.AddRange(new string[] { "msc_x64.lib" }); PublicIncludePaths.AddRange(new string[] { "..\\XunFei\\include" }); }
public llvm(TargetInfo Target) { Type = ModuleType.External; if (Target.Platform != UnrealTargetPlatform.Win32) { // Currently we support only Win32 llvm builds. return; } var LLVMVersion = @"3.5.0"; // VS2015 uses a newer version of the libs if (WindowsPlatform.Compiler == WindowsCompiler.VisualStudio2015) { LLVMVersion = @"3.6.2"; } var VSVersion = @"vs" + WindowsPlatform.GetVisualStudioCompilerVersionName(); var TargetArch = @"x86"; var RootDirectory = Path.Combine(UEBuildConfiguration.UEThirdPartySourceDirectory, @"llvm", LLVMVersion); PublicIncludePaths.AddRange( new string[] { Path.Combine(RootDirectory, "include"), }); PublicLibraryPaths.AddRange( new string[] { Path.Combine(RootDirectory, @"lib", VSVersion, TargetArch, @"release"), }); PublicAdditionalLibraries.AddRange( new string[] { "clangAnalysis.lib", "clangAST.lib", "clangBasic.lib", "clangDriver.lib", "clangEdit.lib", "clangFrontend.lib", "clangLex.lib", "clangParse.lib", "clangSema.lib", "clangSerialization.lib", "clangTooling.lib", "LLVMAnalysis.lib", "LLVMBitReader.lib", "LLVMCodegen.lib", "LLVMCore.lib", "LLVMMC.lib", "LLVMMCDisassembler.lib", "LLVMMCParser.lib", "LLVMObject.lib", "LLVMOption.lib", "LLVMSupport.lib", "LLVMTarget.lib", "LLVMX86AsmParser.lib", "LLVMX86AsmPrinter.lib", "LLVMX86CodeGen.lib", "LLVMX86Desc.lib", "LLVMX86Info.lib", "LLVMX86Utils.lib", }); // The 3.6.2 version we use for VS2015 has moved some functionality around. if (WindowsPlatform.Compiler == WindowsCompiler.VisualStudio2015) { PublicAdditionalLibraries.AddRange( new string[] { "LLVMTransformUtils.lib", }); } }
public libdraco_ue4(ReadOnlyTargetRules Target) : base(Target) { Type = ModuleType.External; string DracoPath = System.IO.Path.Combine(ModuleDirectory, "libdraco-1.3.6"); string IncludePath = System.IO.Path.Combine(DracoPath, "include"); List <string> LibPaths = new List <string>(); List <string> LibFilePaths = new List <string>(); if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64)) { string PlatformName = ""; #if UE_4_23_OR_LATER if (Target.Platform == UnrealTargetPlatform.Win32) { PlatformName = "win32"; } else if (Target.Platform == UnrealTargetPlatform.Win64) { PlatformName = "win64"; } #else switch (Target.Platform) { case UnrealTargetPlatform.Win32: PlatformName = "win32"; break; case UnrealTargetPlatform.Win64: PlatformName = "win64"; break; } #endif string TargetConfiguration = "Release"; if (Target.Configuration == UnrealTargetConfiguration.Debug) { TargetConfiguration = "Debug"; } LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", PlatformName, "vs2019", TargetConfiguration)); LibFilePaths.Add("dracodec.lib"); LibFilePaths.Add("dracoenc.lib"); } else if (Target.Platform == UnrealTargetPlatform.Linux) { LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "linux")); LibFilePaths.Add("libdracodec.a"); LibFilePaths.Add("libdracoenc.a"); } else if (Target.Platform == UnrealTargetPlatform.Mac) { LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "macos")); LibFilePaths.Add("libdracodec.a"); LibFilePaths.Add("libdracoenc.a"); } else if (Target.Platform == UnrealTargetPlatform.Android) { LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "android", "armeabi-v7a")); LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "android", "armeabi-v7a-with-neon")); LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "android", "arm64-v8a")); LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "android", "x86")); LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "android", "x86_64")); LibFilePaths.Add("libdracodec.a"); LibFilePaths.Add("libdracoenc.a"); } else if (Target.Platform == UnrealTargetPlatform.IOS) { LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "ios", "os")); LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "ios", "simulator")); LibPaths.Add(System.IO.Path.Combine(DracoPath, "lib", "ios", "watchos")); LibFilePaths.Add("libdracodec.a"); LibFilePaths.Add("libdracoenc.a"); } PublicIncludePaths.Add(IncludePath); PublicLibraryPaths.AddRange(LibPaths); PublicAdditionalLibraries.AddRange(LibFilePaths); }
public SpatialGDK(ReadOnlyTargetRules Target) : base(Target) { bLegacyPublicIncludePaths = false; PCHUsage = ModuleRules.PCHUsageMode.UseExplicitOrSharedPCHs; #pragma warning disable 0618 bFasterWithoutUnity = true; // Deprecated in 4.24, replace with bUseUnity = false; once we drop support for 4.23 if (Target.Version.MinorVersion == 24) // Due to a bug in 4.24, bFasterWithoutUnity is inversed, fixed in master, so should hopefully roll into the next release, remove this once it does { bFasterWithoutUnity = false; } #pragma warning restore 0618 PrivateIncludePaths.Add("SpatialGDK/Private"); var WorkerSDKPath = Path.GetFullPath(Path.Combine(ModuleDirectory, "Public", "WorkerSDK")); PublicIncludePaths.Add(WorkerSDKPath); // Worker SDK uses a different include format <improbable/x.h> PrivateIncludePaths.Add(WorkerSDKPath); PublicDependencyModuleNames.AddRange( new string[] { "Core", "CoreUObject", "Engine", "EngineSettings", "InputCore", "OnlineSubsystemUtils", "Projects", "ReplicationGraph", "Sockets" }); if (Target.bBuildDeveloperTools || (Target.Configuration != UnrealTargetConfiguration.Shipping && Target.Configuration != UnrealTargetConfiguration.Test)) { PublicDependencyModuleNames.Add("GameplayDebugger"); } if (Target.bBuildEditor) { PublicDependencyModuleNames.Add("UnrealEd"); PublicDependencyModuleNames.Add("SpatialGDKServices"); } if (Target.bWithPerfCounters) { PublicDependencyModuleNames.Add("PerfCounters"); } var WorkerLibraryDir = Path.GetFullPath(Path.Combine(ModuleDirectory, "..", "..", "Binaries", "ThirdParty", "Improbable", Target.Platform.ToString())); var WorkerLibraryPaths = new List <string> { WorkerLibraryDir, }; string LibPrefix = "improbable_"; string ImportLibSuffix = ""; string SharedLibSuffix = ""; bool bAddDelayLoad = false; if (Target.Platform == UnrealTargetPlatform.Win32 || Target.Platform == UnrealTargetPlatform.Win64) { ImportLibSuffix = ".lib"; SharedLibSuffix = ".dll"; bAddDelayLoad = true; } else if (Target.Platform == UnrealTargetPlatform.Mac) { LibPrefix = "libimprobable_"; ImportLibSuffix = SharedLibSuffix = ".dylib"; } else if (Target.Platform == UnrealTargetPlatform.Linux) { LibPrefix = "libimprobable_"; ImportLibSuffix = SharedLibSuffix = ".so"; } else if (Target.Platform == UnrealTargetPlatform.PS4) { LibPrefix = "libimprobable_"; ImportLibSuffix = "_stub.a"; SharedLibSuffix = ".prx"; bAddDelayLoad = true; } else if (Target.Platform == UnrealTargetPlatform.XboxOne) { ImportLibSuffix = ".lib"; SharedLibSuffix = ".dll"; // We don't set bAddDelayLoad = true here, because we get "unresolved external symbol __delayLoadHelper2". // See: https://www.fmod.org/questions/question/deploy-issue-on-xboxone-with-unrealengine-4-14/ } else if (Target.Platform == UnrealTargetPlatform.IOS) { LibPrefix = "libimprobable_"; ImportLibSuffix = SharedLibSuffix = "_static.a"; } else if (Target.Platform == UnrealTargetPlatform.Android) { LibPrefix = "improbable_"; WorkerLibraryPaths.AddRange(new string[] { Path.Combine(WorkerLibraryDir, "arm64-v8a"), Path.Combine(WorkerLibraryDir, "armeabi-v7a"), Path.Combine(WorkerLibraryDir, "x86_64"), }); string PluginPath = Utils.MakePathRelativeTo(ModuleDirectory, Target.RelativeEnginePath); AdditionalPropertiesForReceipt.Add("AndroidPlugin", Path.Combine(PluginPath, "SpatialGDK_APL.xml")); } else { throw new System.Exception(System.String.Format("Unsupported platform {0}", Target.Platform.ToString())); } string WorkerImportLib = System.String.Format("{0}worker{1}", LibPrefix, ImportLibSuffix); string WorkerSharedLib = System.String.Format("{0}worker{1}", LibPrefix, SharedLibSuffix); if (Target.Platform != UnrealTargetPlatform.Android) { RuntimeDependencies.Add(Path.Combine(WorkerLibraryDir, WorkerSharedLib), StagedFileType.NonUFS); if (bAddDelayLoad) { PublicDelayLoadDLLs.Add(WorkerSharedLib); } WorkerImportLib = Path.Combine(WorkerLibraryDir, WorkerImportLib); } PublicAdditionalLibraries.Add(WorkerImportLib); #pragma warning disable 0618 PublicLibraryPaths.AddRange(WorkerLibraryPaths); // Deprecated in 4.24, replace with PublicRuntimeLibraryPaths or move the full path into PublicAdditionalLibraries once we drop support for 4.23 #pragma warning restore 0618 // Detect existence of trace library, if present add preprocessor string TraceStaticLibPath = ""; string TraceDynamicLib = ""; string TraceDynamicLibPath = ""; if (Target.Platform == UnrealTargetPlatform.Win32 || Target.Platform == UnrealTargetPlatform.Win64) { TraceStaticLibPath = Path.Combine(WorkerLibraryDir, "trace_dynamic.lib"); TraceDynamicLib = "trace_dynamic.dll"; TraceDynamicLibPath = Path.Combine(WorkerLibraryDir, TraceDynamicLib); } else if (Target.Platform == UnrealTargetPlatform.Linux) { TraceStaticLibPath = Path.Combine(WorkerLibraryDir, "libtrace_dynamic.so"); TraceDynamicLib = "libtrace_dynamic.so"; TraceDynamicLibPath = Path.Combine(WorkerLibraryDir, TraceDynamicLib); } if (File.Exists(TraceStaticLibPath) && File.Exists(TraceDynamicLibPath)) { Log.TraceInformation("Detection of trace libraries found at {0} and {1}, enabling trace functionality.", TraceStaticLibPath, TraceDynamicLibPath); PublicDefinitions.Add("TRACE_LIB_ACTIVE=1"); PublicAdditionalLibraries.Add(TraceStaticLibPath); RuntimeDependencies.Add(TraceDynamicLibPath, StagedFileType.NonUFS); if (bAddDelayLoad) { PublicDelayLoadDLLs.Add(TraceDynamicLib); } } else { Log.TraceInformation("Didn't find trace libraries at {0} and {1}, disabling trace functionality.", TraceStaticLibPath, TraceDynamicLibPath); PublicDefinitions.Add("TRACE_LIB_ACTIVE=0"); } }
public RequencePlugin(ReadOnlyTargetRules Target) : base(Target) { PCHUsage = ModuleRules.PCHUsageMode.UseExplicitOrSharedPCHs; string sdlDir = Path.GetFullPath(Path.Combine(ModuleDirectory, "../../ThirdParty")); //Set library path PublicLibraryPaths.AddRange( new string[] { Path.Combine(ModuleDirectory, "../../Binaries/ThirdParty", Target.Platform.ToString()), Path.Combine(ModuleDirectory, "../../ThirdParty", Target.Platform.ToString()) } ); //Include SDL headers PublicIncludePaths.AddRange( new string[] { "RequencePlugin/Public", Path.Combine(ModuleDirectory, "../../ThirdParty/include") } ); PublicAdditionalLibraries.Add("SDL2.lib"); PublicDelayLoadDLLs.Add("SDL2.dll"); PrivateIncludePaths.AddRange( new string[] { "RequencePlugin/Private", } ); PublicDependencyModuleNames.AddRange( new string[] { "Core", "CoreUObject", "Engine", "InputCore", "Slate", "SlateCore", "Projects", "Json", "JsonUtilities" // ... add other public dependencies that you statically link with here ... } ); PrivateIncludePathModuleNames.AddRange( new string[] { "InputDevice", }); PrivateDependencyModuleNames.AddRange( new string[] { "InputDevice", "Json", "JsonUtilities" // ... add private dependencies that you statically link with here ... } ); DynamicallyLoadedModuleNames.AddRange( new string[] { // ... add any modules that your module loads dynamically here ... } ); if (Target.Platform == UnrealTargetPlatform.Win64) { string _dllPath = Path.GetFullPath(Path.Combine(ModuleDirectory, "../../Binaries/ThirdParty/Win64")); RuntimeDependencies.Add(new RuntimeDependency(Path.Combine(_dllPath, "SDL2.dll"))); } else if (Target.Platform == UnrealTargetPlatform.Win32) { string _dllPath = Path.GetFullPath(Path.Combine(ModuleDirectory, "../../Binaries/ThirdParty/Win32")); RuntimeDependencies.Add(new RuntimeDependency(Path.Combine(_dllPath, "SDL2.dll"))); } }
public libgltf_ue4(ReadOnlyTargetRules Target) : base(Target) { Type = ModuleType.External; string glTFPath = System.IO.Path.Combine(ModuleDirectory, "libgltf-0.1.6"); string IncludePath = System.IO.Path.Combine(glTFPath, "include"); List <string> LibPaths = new List <string>(); string LibFilePath = ""; if ((Target.Platform == UnrealTargetPlatform.Win32) || (Target.Platform == UnrealTargetPlatform.Win64)) { string PlatformName = ""; switch (Target.Platform) { case UnrealTargetPlatform.Win32: PlatformName = "win32"; break; case UnrealTargetPlatform.Win64: PlatformName = "win64"; break; } string TargetConfiguration = "Release"; string TargetPostfix = ""; if (Target.Configuration == UnrealTargetConfiguration.Debug) { TargetConfiguration = "Debug"; TargetPostfix = "d"; } LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", PlatformName, "vs2019", TargetConfiguration)); LibFilePath = "libgltf" + TargetPostfix + ".lib"; } else if (Target.Platform == UnrealTargetPlatform.Linux) { LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "linux")); LibFilePath = "libgltf.a"; } else if (Target.Platform == UnrealTargetPlatform.Mac) { LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "macos")); LibFilePath = "libgltf.a"; } else if (Target.Platform == UnrealTargetPlatform.Android) { LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "android", "armeabi-v7a")); LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "android", "armeabi-v7a-with-neon")); LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "android", "arm64-v8a")); LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "android", "x86")); LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "android", "x86_64")); LibFilePath = "libgltf.a"; } else if (Target.Platform == UnrealTargetPlatform.IOS) { LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "ios", "os")); LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "ios", "simulator")); LibPaths.Add(System.IO.Path.Combine(glTFPath, "lib", "ios", "watchos")); LibFilePath = "libgltf.a"; } PublicIncludePaths.Add(IncludePath); PublicLibraryPaths.AddRange(LibPaths); PublicAdditionalLibraries.Add(LibFilePath); PublicDefinitions.Add("LIBGLTF_CHARACTOR_ENCODING_IS_UTF8"); }
public AkAudio(ReadOnlyTargetRules Target) : base(Target) { string ThirdPartyFolder = Path.Combine(ModuleDirectory, "../../ThirdParty"); AkUEPlatformInstance = AkUEPlatform.GetAkUEPlatformInstance(Target, ThirdPartyFolder); PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs; PrivateIncludePathModuleNames.AddRange(new string[] { "Settings", "UMG" }); PublicDependencyModuleNames.Add("UMG"); PrivateDependencyModuleNames.AddRange( new string[] { "Core", "CoreUObject", "Engine", "SlateCore", "NetworkReplayStreaming", "MovieScene", "MovieSceneTracks", "Projects", "Json", "Slate", "InputCore", "Projects" }); if (Target.bBuildEditor) { PrivateDependencyModuleNames.AddRange( new string[] { "UnrealEd", "DesktopPlatform" }); foreach (var Platform in GetAvailablePlatforms(ModuleDirectory)) { PublicDefinitions.Add("AK_PLATFORM_" + Platform.ToUpper()); } } PrivateIncludePaths.Add("AkAudio/Private"); PublicIncludePaths.Add(Path.Combine(ThirdPartyFolder, "include")); PublicDefinitions.Add("AK_UNREAL_MAX_CONCURRENT_IO=32"); PublicDefinitions.Add("AK_UNREAL_IO_GRANULARITY=32768"); if (Target.Configuration == UnrealTargetConfiguration.Shipping) { PublicDefinitions.Add("AK_OPTIMIZED"); } if (Target.Configuration != UnrealTargetConfiguration.Shipping && AkUEPlatformInstance.SupportsCommunication) { AddWwiseLib("CommunicationCentral"); PublicDefinitions.Add("AK_ENABLE_COMMUNICATION=1"); } else { PublicDefinitions.Add("AK_ENABLE_COMMUNICATION=0"); } // Platform-specific dependencies PublicLibraryPaths.AddRange(AkUEPlatformInstance.GetPublicLibraryPaths()); PublicAdditionalLibraries.AddRange(AkUEPlatformInstance.GetPublicAdditionalLibraries()); PublicDefinitions.AddRange(AkUEPlatformInstance.GetPublicDefinitions()); var Frameworks = AkUEPlatformInstance.GetPublicAdditionalFrameworks(); foreach (var fw in Frameworks) { #if UE_4_22_OR_LATER PublicAdditionalFrameworks.Add(new ModuleRules.Framework(fw)); #else PublicAdditionalFrameworks.Add(new UEBuildFramework(fw)); #endif } AddWwiseLib("AkSoundEngine"); AddWwiseLib("AkMemoryMgr"); AddWwiseLib("AkStreamMgr"); AddWwiseLib("AkMusicEngine"); AddWwiseLib("AkSpatialAudio"); AddWwiseLib("AkVorbisDecoder"); AddWwiseLib("AkSilenceSource"); AddWwiseLib("AkSineSource"); AddWwiseLib("AkToneSource"); AddWwiseLib("AkPeakLimiterFX"); AddWwiseLib("AkMatrixReverbFX"); AddWwiseLib("AkParametricEQFX"); AddWwiseLib("AkDelayFX"); AddWwiseLib("AkExpanderFX"); AddWwiseLib("AkFlangerFX"); AddWwiseLib("AkCompressorFX"); AddWwiseLib("AkGainFX"); AddWwiseLib("AkHarmonizerFX"); AddWwiseLib("AkTimeStretchFX"); AddWwiseLib("AkPitchShifterFX"); AddWwiseLib("AkStereoDelayFX"); AddWwiseLib("AkMeterFX"); AddWwiseLib("AkGuitarDistortionFX"); AddWwiseLib("AkTremoloFX"); AddWwiseLib("AkRoomVerbFX"); AddWwiseLib("AkAudioInputSource"); AddWwiseLib("AkSynthOneSource"); AddWwiseLib("AkRecorderFX"); AddWwiseLib("AkOpusDecoder"); AddWwisePlugin("AkReflectFX"); AddWwisePlugin("AkConvolutionReverbFX"); AddWwisePlugin("AuroHeadphoneFX"); if (AkUEPlatformInstance.SupportsAkAutobahn) { PublicDefinitions.Add("AK_SUPPORT_WAAPI=1"); AddWwiseLib("AkAutobahn"); } else { PublicDefinitions.Add("AK_SUPPORT_WAAPI=0"); } }
public AkAudio(ReadOnlyTargetRules Target) : base(Target) { string ThirdPartyFolder = Path.Combine(ModuleDirectory, "../../ThirdParty"); AkUEPlatformInstance = AkUEPlatform.GetAkUEPlatformInstance(Target, ThirdPartyFolder); PCHUsage = PCHUsageMode.UseExplicitOrSharedPCHs; PrivateIncludePathModuleNames.AddRange(new[] { "Settings", "UMG", "TargetPlatform" }); PublicDependencyModuleNames.AddRange(new[] { "UMG", "PhysX", "APEX" }); PrivateDependencyModuleNames.AddRange(new[] { "Core", "CoreUObject", "Engine", "SlateCore", "NetworkReplayStreaming", "MovieScene", "MovieSceneTracks", "Projects", "Json", "Slate", "InputCore", "Projects" }); if (Target.bBuildEditor) { PrivateDependencyModuleNames.AddRange( new string[] { "UnrealEd", "DesktopPlatform", "TargetPlatform" }); foreach (var Platform in GetAvailablePlatforms(ModuleDirectory)) { PublicDefinitions.Add("AK_PLATFORM_" + Platform.ToUpper()); } } PrivateIncludePaths.Add("AkAudio/Private"); PublicIncludePaths.Add(Path.Combine(ThirdPartyFolder, "include")); PublicDefinitions.Add("AK_UNREAL_MAX_CONCURRENT_IO=32"); PublicDefinitions.Add("AK_UNREAL_IO_GRANULARITY=32768"); if (Target.Configuration == UnrealTargetConfiguration.Shipping) { PublicDefinitions.Add("AK_OPTIMIZED"); } if (Target.Configuration != UnrealTargetConfiguration.Shipping && AkUEPlatformInstance.SupportsCommunication) { AkLibs.Add("CommunicationCentral"); PublicDefinitions.Add("AK_ENABLE_COMMUNICATION=1"); } else { PublicDefinitions.Add("AK_ENABLE_COMMUNICATION=0"); } if (AkUEPlatformInstance.SupportsAkAutobahn) { AkLibs.Add("AkAutobahn"); PublicDefinitions.Add("AK_SUPPORT_WAAPI=1"); } else { PublicDefinitions.Add("AK_SUPPORT_WAAPI=0"); } if (AkUEPlatformInstance.SupportsOpus) { AkLibs.Add("AkOpusDecoder"); PublicDefinitions.Add("AK_SUPPORT_OPUS=1"); } else { PublicDefinitions.Add("AK_SUPPORT_OPUS=0"); } if (AkUEPlatformInstance.SupportsDeviceMemory) { PublicDefinitions.Add("AK_SUPPORT_DEVICE_MEMORY=1"); } else { PublicDefinitions.Add("AK_SUPPORT_DEVICE_MEMORY=0"); } // Platform-specific dependencies #if UE_4_24_OR_LATER PublicSystemLibraries.AddRange(AkUEPlatformInstance.GetPublicSystemLibraries()); #else PublicLibraryPaths.AddRange(AkUEPlatformInstance.GetPublicLibraryPaths()); PublicAdditionalLibraries.AddRange(AkUEPlatformInstance.GetPublicSystemLibraries()); #endif AkLibs.AddRange(AkUEPlatformInstance.GetAdditionalWwiseLibs()); PublicDefinitions.AddRange(AkUEPlatformInstance.GetPublicDefinitions()); PublicDefinitions.Add(string.Format("AK_CONFIGURATION=\"{0}\"", AkUEPlatformInstance.akConfigurationDir)); var AdditionalProperty = AkUEPlatformInstance.GetAdditionalPropertyForReceipt(ModuleDirectory); if (AdditionalProperty != null) { AdditionalPropertiesForReceipt.Add(AdditionalProperty.Item1, AdditionalProperty.Item2); } var Frameworks = AkUEPlatformInstance.GetPublicAdditionalFrameworks(); foreach (var fw in Frameworks) { #if UE_4_22_OR_LATER PublicAdditionalFrameworks.Add(new ModuleRules.Framework(fw)); #else PublicAdditionalFrameworks.Add(new UEBuildFramework(fw)); #endif } PublicAdditionalLibraries.AddRange(AkUEPlatformInstance.GetSanitizedAkLibList(AkLibs)); }