Repository navigation
Expand file tree
/
Copy pathPythonConsole.Build.cs
More file actions
56 lines (49 loc) · 1.63 KB
/
Copy pathPythonConsole.Build.cs
File metadata and controls
56 lines (49 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
// Copyright 1998-2016 Epic Games, Inc. All Rights Reserved.
using UnrealBuildTool;
using System.IO;
public class PythonConsole : ModuleRules
{
private const string pythonHome = "python35";
protected string PythonHome
{
get
{
return Path.GetFullPath(Path.Combine(ModuleDirectory, "..", "..", pythonHome));
}
}
public PythonConsole(TargetInfo Target)
{
PrivateIncludePaths.AddRange(
new string[] {
"PythonConsole/Private",
// ... add other private include paths required here ...
}
);
PrivateDependencyModuleNames.AddRange(
new string[] {
"Core",
"CoreUObject", // @todo Mac: for some reason it's needed to link in debug on Mac
"Engine",
"InputCore",
"UnrealEd",
"Slate",
"SlateCore",
"EditorStyle",
"TargetPlatform",
"UnrealEnginePython"
}
);
if ((Target.Platform == UnrealTargetPlatform.Win64) || (Target.Platform == UnrealTargetPlatform.Win32))
{
PublicIncludePaths.Add(PythonHome);
PublicAdditionalLibraries.Add(Path.Combine(PythonHome, "libs", "python35.lib"));
}
else if (Target.Platform == UnrealTargetPlatform.Mac)
{
string mac_python = "/Library/Frameworks/Python.framework/Versions/3.5/";
PublicIncludePaths.Add(Path.Combine(mac_python, "include"));
PublicAdditionalLibraries.Add(Path.Combine(mac_python, "lib", "libpython3.5m.dylib"));
Definitions.Add(string.Format("UNREAL_ENGINE_PYTHON_ON_MAC=1"));
}
}
}