Skip to content

Commit 64c32b9

Browse files
authored
project.py: Add flexible executable name for mw_version check (#656)
1 parent 69059ab commit 64c32b9

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

tools/project.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1063,7 +1063,13 @@ def add_unit(build_obj: BuildConfigUnit, link_step: LinkStep):
10631063

10641064
# Check if all compiler versions exist
10651065
for mw_version in used_compiler_versions:
1066-
mw_path = compilers / mw_version / "mwcceppc.exe"
1066+
compiler_version_info = mw_version.split("/")
1067+
executable_name = {
1068+
"GC": "mwcceppc.exe",
1069+
"ProDG": "ngccc.exe",
1070+
}.get(compiler_version_info[0] if compiler_version_info else "GC")
1071+
1072+
mw_path = compilers / mw_version / executable_name
10671073
if config.compilers_path and not os.path.exists(mw_path):
10681074
sys.exit(f"Compiler {mw_path} does not exist")
10691075

0 commit comments

Comments
 (0)