Skip to content

Commit 3462fab

Browse files
authored
Merge pull request 20tab#631 from dfb/pr_python_home_env
look for python in alternate custom location
2 parents d97cf72 + bfe470b commit 3462fab

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Source/UnrealEnginePython/UnrealEnginePython.Build.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -292,6 +292,11 @@ private string DiscoverPythonPath(string[] knownPaths, string binaryPath)
292292
if (!string.IsNullOrEmpty(environmentPath))
293293
paths.Insert(0, environmentPath);
294294

295+
// look in an alternate custom location
296+
environmentPath = System.Environment.GetEnvironmentVariable("UNREALENGINEPYTHONHOME");
297+
if (!string.IsNullOrEmpty(environmentPath))
298+
paths.Insert(0, environmentPath);
299+
295300
foreach (string path in paths)
296301
{
297302
string actualPath = path;

0 commit comments

Comments
 (0)