Skip to content

Commit

Permalink
fixed the workflow to pick the correct os
Browse files Browse the repository at this point in the history
  • Loading branch information
DiamonDinoia committed Jul 29, 2024
1 parent 5ea371d commit 607cdb8
Showing 1 changed file with 15 additions and 14 deletions.
29 changes: 15 additions & 14 deletions .github/workflows/generate_cmake_matrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,24 @@

build_type = ["Release", "Debug"]
static_linking = ["On", "Off"]
combinations = {
"ubuntu-22.04": {
combinations = [
("ubuntu-22.04", {
"toolchain": ["llvm", "gcc"],
"arch_flags": ["-march=native", "-march=x86-64", "native"]
},
"windows-2022-msvc": {
}),
("windows-2022",{
"toolchain": ["msvc"],
"arch_flags": ["/arch:AVX2", "/arch:SSE2", "native"]
},
"windows-2022-llvm": {
"toolchain": ["msvc"],
}),
("windows-2022", {
"toolchain": ["llvm"],
"arch_flags": ["-march=native", "-march=x86-64", "native"]
},
"macos-13": {
}),
("macos-13", {
"toolchain": ["llvm", "gcc-14"],
"arch_flags": ["-march=native", "-march=x86-64", "native"]
}
}
})
]


def get_c_compiler(toolchain):
Expand All @@ -46,9 +46,10 @@ def get_cxx_compiler(toolchain):
else:
raise ValueError(f"Unknown toolchain: {toolchain}")

for platform in combinations.keys():
for toolchain in combinations[platform]["toolchain"]:
for arch_flag in combinations[platform]["arch_flags"]:

for platform, value in combinations:
for toolchain in value["toolchain"]:
for arch_flag in value["arch_flags"]:
for linking in static_linking:
for build in build_type:
matrix["include"].append({
Expand Down

0 comments on commit 607cdb8

Please sign in to comment.