Update README
This commit is contained in:
parent
2f591a4858
commit
4dc748d273
1 changed files with 23 additions and 3 deletions
26
README.md
26
README.md
|
@ -2,10 +2,30 @@
|
||||||
|
|
||||||
## Setup
|
## Setup
|
||||||
|
|
||||||
Install Emscripten
|
- Install Emscripten
|
||||||
https://puddleofcode.com/story/definitive-guide-to-rust-sdl2-and-emscriptem
|
```
|
||||||
|
# Get the emsdk repo
|
||||||
|
git clone https://github.com/emscripten-core/emsdk.git
|
||||||
|
|
||||||
|
# Enter that directory
|
||||||
|
cd emsdk
|
||||||
|
|
||||||
|
# Download and install the latest SDK tools.
|
||||||
|
./emsdk install latest
|
||||||
|
|
||||||
|
# Make the "latest" SDK "active" for the current user. (writes .emscripten file)
|
||||||
|
./emsdk activate latest
|
||||||
|
|
||||||
|
# Activate PATH and other environment variables in the current terminal
|
||||||
|
source ./emsdk_env.sh
|
||||||
|
```
|
||||||
|
https://emscripten.org/docs/getting_started/downloads.html
|
||||||
|
|
||||||
|
- Compile SDL2:
|
||||||
```
|
```
|
||||||
$ embuilder.py build sdl2
|
$ embuilder.py build sdl2
|
||||||
$ export EMMAKEN_CFLAGS="-s USE_SDL=2"
|
|
||||||
```
|
```
|
||||||
|
|
||||||
|
References:
|
||||||
|
- https://puddleofcode.com/story/definitive-guide-to-rust-sdl2-and-emscriptem
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue