Jelajahi Sumber

[Windows, MSVC] Correctly set source file encoding.

bruvzg 4 tahun lalu
induk
melakukan
56f3aba7b2
2 mengubah file dengan 2 tambahan dan 2 penghapusan
  1. 1 1
      platform/uwp/detect.py
  2. 1 1
      platform/windows/detect.py

+ 1 - 1
platform/uwp/detect.py

@@ -81,7 +81,7 @@ def configure(env):
     vc_base_path = os.environ["VCTOOLSINSTALLDIR"] if "VCTOOLSINSTALLDIR" in os.environ else os.environ["VCINSTALLDIR"]
 
     # Force to use Unicode encoding
-    env.Append(MSVC_FLAGS=["/utf-8"])
+    env.AppendUnique(CCFLAGS=["/utf-8"])
 
     # ANGLE
     angle_root = os.getenv("ANGLE_SRC_PATH")

+ 1 - 1
platform/windows/detect.py

@@ -223,7 +223,7 @@ def configure_msvc(env, manual_msvc_config):
 
     env.AppendUnique(CCFLAGS=["/MT", "/Gd", "/GR", "/nologo"])
     # Force to use Unicode encoding
-    env.Append(MSVC_FLAGS=["/utf-8"])
+    env.AppendUnique(CCFLAGS=["/utf-8"])
     env.AppendUnique(CXXFLAGS=["/TP"])  # assume all sources are C++
     if manual_msvc_config:  # should be automatic if SCons found it
         if os.getenv("WindowsSdkDir") is not None: