Skip to content

Commit

Permalink
try to fetch correct windows wgpu release zip
Browse files Browse the repository at this point in the history
  • Loading branch information
PyryM committed Oct 4, 2024
1 parent c423f7f commit d0971be
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion codegen/fetch_wgpu_bins.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,20 @@ def __init__(self, src: str, dest: Optional[str]=None):
def fix_name(name: str) -> str:
return ALIASES.get(name, name)

def fix_arch(name: str) -> str:
if IS_WINDOWS:
return fix_name(name) + "-msvc"
else:
return fix_name(name)


BASE_URL = "https://github.com/gfx-rs/wgpu-native/releases/download/"
VERSION = "22.1.0.5"

SYSNAME = uname().system.lower()
IS_WINDOWS = SYSNAME == "windows" or ("microsoft" in uname().release.lower())
OS = fix_name("windows" if IS_WINDOWS else SYSNAME)
ARCH = fix_name(uname().machine.lower())
ARCH = fix_arch(uname().machine.lower())


def make_url(osname: str, arch: str) -> str:
Expand Down

0 comments on commit d0971be

Please sign in to comment.