Skip to content

Commit a961595

Browse files
committed
Add build_wasm script for windows
1 parent fa6c571 commit a961595

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

ebiten-game/game/build_wasm.ps1

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# SPDX-FileCopyrightText: 2025 The Pion community <https://pion.ly>
2+
# SPDX-License-Identifier: MIT
3+
4+
$Env:GOOS = 'js'
5+
$Env:GOARCH = 'wasm'
6+
go build -o game.wasm .
7+
Remove-Item Env:GOOS
8+
Remove-Item Env:GOARCH
9+
$goroot = go env GOROOT
10+
11+
# Go 1.24 and newer
12+
cp $goroot\lib\wasm\wasm_exec.js .

0 commit comments

Comments
 (0)