Prechádzať zdrojové kódy

Alias the "linuxbsd" platform to "x11" for forward compatibility

This makes it possible to follow documentation designed for the
`master` branch while building the `3.2` branch.
Hugo Locurcio 5 rokov pred
rodič
commit
9790168b48
1 zmenil súbory, kde vykonal 8 pridanie a 0 odobranie
  1. 8 0
      SConstruct

+ 8 - 0
SConstruct

@@ -284,6 +284,14 @@ else:
         print("Automatically detected platform: " + selected_platform)
         print("Automatically detected platform: " + selected_platform)
         env_base["platform"] = selected_platform
         env_base["platform"] = selected_platform
 
 
+if selected_platform in ["linux", "bsd", "linuxbsd"]:
+    if selected_platform == "linuxbsd":
+        # Alias for forward compatibility.
+        print('Platform "linuxbsd" is still called "x11" in Godot 3.2.x. Building for platform "x11".')
+    # Alias for convenience.
+    selected_platform = "x11"
+    env_base["platform"] = selected_platform
+
 if selected_platform in platform_list:
 if selected_platform in platform_list:
     tmppath = "./platform/" + selected_platform
     tmppath = "./platform/" + selected_platform
     sys.path.insert(0, tmppath)
     sys.path.insert(0, tmppath)