... | ... |
@@ -23,6 +23,18 @@ mk |
23 | 23 |
|
24 | 24 |
If the build fails on 9front because of missing headers or functions, try again after `rm -r /sys/include/npe`. |
25 | 25 |
|
26 |
+### Windows |
|
27 |
+ |
|
28 |
+Uxn can be built on Windows with [MSYS2](https://www.msys2.org/). Install by downloading from their website or with Chocolatey with `choco install msys2`. In the MSYS shell, type: |
|
29 |
+ |
|
30 |
+```sh |
|
31 |
+pacman -S git mingw-w64-x86_64-gcc mingw64/mingw-w64-x86_64-SDL2 |
|
32 |
+export PATH="${PATH}:/mingw64/bin" |
|
33 |
+git clone https://git.sr.ht/~rabbits/uxn |
|
34 |
+cd uxn |
|
35 |
+./build.sh |
|
36 |
+``` |
|
37 |
+ |
|
26 | 38 |
## Getting Started |
27 | 39 |
|
28 | 40 |
Begin by building the assembler and emulator by running the build script. The assembler(`uxnasm`) and emulator(`uxnemu`) are created in the `/bin` folder. |
... | ... |
@@ -24,7 +24,11 @@ fi |
24 | 24 |
|
25 | 25 |
mkdir -p bin |
26 | 26 |
CFLAGS="-std=c89 -Wall -Wno-unknown-pragmas" |
27 |
-UXNEMU_LDFLAGS="-L/usr/local/lib $(sdl2-config --cflags --libs)" |
|
27 |
+if [ -n "${MSYSTEM}" ]; then |
|
28 |
+ UXNEMU_LDFLAGS="-static $(sdl2-config --cflags --static-libs)" |
|
29 |
+else |
|
30 |
+ UXNEMU_LDFLAGS="-L/usr/local/lib $(sdl2-config --cflags --libs)" |
|
31 |
+fi |
|
28 | 32 |
|
29 | 33 |
if [ "${1}" = '--debug' ]; |
30 | 34 |
then |