]> granicus.if.org Git - graphviz/commitdiff
tests: de-dupe some MinGW detection logic
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Fri, 11 Mar 2022 04:48:10 +0000 (20:48 -0800)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 19 Mar 2022 20:29:34 +0000 (13:29 -0700)
rtest/gvtest.py

index 8cfd74b2246443d6a72abc7b3012d8cd7a848329..c725b577b08048e28904d5df3db27a1c73051afb 100644 (file)
@@ -31,7 +31,7 @@ def compile_c(src: Path, cflags: List[str] = None, link: List[str] = None,
   if dst is None:
     _, dst = tempfile.mkstemp(".exe")
 
-  if platform.system() == "Windows" and "mingw" not in sysconfig.get_platform():
+  if platform.system() == "Windows" and not is_mingw():
     # determine which runtime library option we need
     rtflag = "-MDd" if os.environ.get("configuration") == "Debug" else "-MD"