Просмотр исходного кода

Fix macOS build with ANGLE enabled and Vulkan disabled.

Pāvels Nadtočajevs 5 месяцев назад
Родитель
Сommit
e096e2fa8a
1 измененных файлов с 3 добавлено и 2 удалено
  1. 3 2
      platform/macos/detect.py

+ 3 - 2
platform/macos/detect.py

@@ -235,6 +235,8 @@ def configure(env: "SConsEnvironment"):
     )
     env.Append(LIBS=["pthread", "z"])
 
+    extra_frameworks = set()
+
     if env["opengl3"]:
         env.Append(CPPDEFINES=["GLES3_ENABLED"])
         if env["angle_libs"] != "":
@@ -243,6 +245,7 @@ def configure(env: "SConsEnvironment"):
             env.Append(LINKFLAGS=["-lANGLE.macos." + env["arch"]])
             env.Append(LINKFLAGS=["-lEGL.macos." + env["arch"]])
             env.Append(LINKFLAGS=["-lGLES.macos." + env["arch"]])
+            extra_frameworks.add("IOSurface")
         env.Prepend(CPPEXTPATH=["#thirdparty/angle/include"])
 
     env.Append(LINKFLAGS=["-rpath", "@executable_path/../Frameworks", "-rpath", "@executable_path"])
@@ -251,8 +254,6 @@ def configure(env: "SConsEnvironment"):
         print_warning("Target architecture '{}' does not support the Metal rendering driver".format(env["arch"]))
         env["metal"] = False
 
-    extra_frameworks = set()
-
     if env["metal"]:
         env.AppendUnique(CPPDEFINES=["METAL_ENABLED", "RD_ENABLED"])
         extra_frameworks.add("Metal")