diff options
| author | skal <pascal.massimino@gmail.com> | 2026-01-31 13:57:51 +0100 |
|---|---|---|
| committer | skal <pascal.massimino@gmail.com> | 2026-01-31 13:57:51 +0100 |
| commit | e3daca37aa134a6885c8ae5c508c3d7f7bfc600a (patch) | |
| tree | 69578c5e3376603219bc341e8975e289cede9bdd /scripts/fetch_win_deps.sh | |
| parent | 3af9f70bec1f50c980288e2213035693f4b737ce (diff) | |
Add Windows cross-compilation support (MinGW) and emulation (Wine)
Diffstat (limited to 'scripts/fetch_win_deps.sh')
| -rwxr-xr-x | scripts/fetch_win_deps.sh | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/scripts/fetch_win_deps.sh b/scripts/fetch_win_deps.sh new file mode 100755 index 0000000..a32f047 --- /dev/null +++ b/scripts/fetch_win_deps.sh @@ -0,0 +1,29 @@ +#!/bin/bash +set -e +set -x + +# Create directories +mkdir -p third_party/windows/lib +mkdir -p third_party/windows/include/GLFW + +echo "Fetching GLFW 3.4..." +curl -L -o glfw.zip https://github.com/glfw/glfw/releases/download/3.4/glfw-3.4.bin.WIN64.zip +unzip -q glfw.zip +cp glfw-3.4.bin.WIN64/lib-mingw-w64/libglfw3.a third_party/windows/lib/ +cp glfw-3.4.bin.WIN64/include/GLFW/* third_party/windows/include/GLFW/ +rm -rf glfw.zip glfw-3.4.bin.WIN64 + +echo "Fetching wgpu-native v0.19.4.1..." +curl -L -o wgpu.zip https://github.com/gfx-rs/wgpu-native/releases/download/v0.19.4.1/wgpu-windows-x86_64-release.zip +unzip -q wgpu.zip -d wgpu_temp +# Copy import library (renaming for MinGW convention, though it can usually read .lib) +cp wgpu_temp/wgpu_native.dll.lib third_party/windows/lib/libwgpu_native.dll.a +# Copy runtime DLL (will be needed next to executable) +cp wgpu_temp/wgpu_native.dll third_party/windows/lib/wgpu_native.dll +# Copy headers +mkdir -p third_party/windows/include/webgpu +cp wgpu_temp/webgpu.h third_party/windows/include/webgpu/ +cp wgpu_temp/wgpu.h third_party/windows/include/webgpu/ +rm -rf wgpu.zip wgpu_temp + +echo "Windows dependencies fetched." |
