diff options
author | Thaddeus Crews <repiteo@outlook.com> | 2024-09-23 09:13:51 -0500 |
---|---|---|
committer | Thaddeus Crews <repiteo@outlook.com> | 2024-10-10 10:10:55 -0500 |
commit | a44f691fc7174c8aa75bdc3b0c120213a2ce55dc (patch) | |
tree | 9130ac5fb35892f09e6cdd6e2574c9a6f02cdfdd /platform | |
parent | 68f053bf82ff811c7a6f870832eb4bc4d09a62e5 (diff) | |
download | redot-engine-a44f691fc7174c8aa75bdc3b0c120213a2ce55dc.tar.gz |
CI: Add MinGW/GCC build to Windows GHA
Diffstat (limited to 'platform')
-rw-r--r-- | platform/windows/detect.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/platform/windows/detect.py b/platform/windows/detect.py index 4043f3a8c2..0ee52a09a7 100644 --- a/platform/windows/detect.py +++ b/platform/windows/detect.py @@ -662,7 +662,7 @@ def get_ar_version(env): print_warning("Couldn't check version of `ar`.") return ret - match = re.search(r"GNU ar \(GNU Binutils\) (\d+)\.(\d+)(?:\.(\d+))?", output) + match = re.search(r"GNU ar(?: \(GNU Binutils\)| version) (\d+)\.(\d+)(?:\.(\d+))?", output) if match: ret["major"] = int(match[1]) ret["minor"] = int(match[2]) @@ -788,8 +788,9 @@ def configure_mingw(env: "SConsEnvironment"): env["CXX"] = mingw_bin_prefix + "g++" if try_cmd("as --version", env["mingw_prefix"], env["arch"]): env["AS"] = mingw_bin_prefix + "as" - if try_cmd("gcc-ar --version", env["mingw_prefix"], env["arch"]): - env["AR"] = mingw_bin_prefix + "gcc-ar" + ar = "ar" if os.name == "nt" else "gcc-ar" + if try_cmd(f"{ar} --version", env["mingw_prefix"], env["arch"]): + env["AR"] = mingw_bin_prefix + ar if try_cmd("gcc-ranlib --version", env["mingw_prefix"], env["arch"]): env["RANLIB"] = mingw_bin_prefix + "gcc-ranlib" |