blob: a32f047f15ed2475b000720143db99e49df83c1f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
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."
|