Skip to content

Commit 3a3d716

Browse files
author
Roberto De Ioris
committed
another improvement in build procedure
1 parent 78ccd7a commit 3a3d716

1 file changed

Lines changed: 16 additions & 5 deletions

File tree

‎Source/UnrealEnginePython/UnrealEnginePython.Build.cs‎

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,26 @@
11
// Copyright 1998-2016 Epic Games, Inc. All Rights Reserved.
22

33
using UnrealBuildTool;
4+
using System.IO;
45

56
public class UnrealEnginePython : ModuleRules
67
{
78

8-
private const string pythonHome = "C:/Users/Roberto/Documents/Unreal Projects/PyTest30/Plugins/UnrealEnginePython/python-3.5.2-embed-amd64";
9+
private const string pythonHome = "python-3.5.2-embed-amd64";
10+
11+
protected string PythonHome
12+
{
13+
get
14+
{
15+
return Path.GetFullPath(Path.Combine(ModuleDirectory, "..", "..", pythonHome));
16+
}
17+
}
918

1019
public UnrealEnginePython(TargetInfo Target)
1120
{
1221

22+
System.Console.WriteLine("Using Python at: " + PythonHome);
23+
1324
PublicIncludePaths.AddRange(
1425
new string[] {
1526
"UnrealEnginePython/Public",
@@ -58,12 +69,12 @@ public UnrealEnginePython(TargetInfo Target)
5869

5970

6071

61-
PublicIncludePaths.Add(pythonHome);
62-
PublicLibraryPaths.Add(pythonHome + "/libs");
72+
PublicIncludePaths.Add(PythonHome);
73+
PublicLibraryPaths.Add(PythonHome + "/libs/");
6374
PublicAdditionalLibraries.Add("python35.lib");
6475

65-
RuntimeDependencies.Add(new RuntimeDependency(pythonHome + "/python35.dll"));
66-
RuntimeDependencies.Add(new RuntimeDependency(pythonHome + "/python35.zip"));
76+
RuntimeDependencies.Add(new RuntimeDependency(PythonHome + "/python35.dll"));
77+
RuntimeDependencies.Add(new RuntimeDependency(PythonHome + "/python35.zip"));
6778

6879
}
6980
}

0 commit comments

Comments
 (0)