🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

35 lines
931 B

  1. Emscripten
  2. ================================================================================
  3. Build:
  4. $ mkdir build
  5. $ cd build
  6. $ emconfigure ../configure --host=asmjs-unknown-emscripten --disable-assembly --disable-threads --disable-cpuinfo CFLAGS="-O2"
  7. $ emmake make
  8. Or with cmake:
  9. $ mkdir build
  10. $ cd build
  11. $ emcmake cmake ..
  12. $ emmake make
  13. To build one of the tests:
  14. $ cd test/
  15. $ emcc -O2 --js-opts 0 -g4 testdraw2.c -I../include ../build/.libs/libSDL2.a ../build/libSDL2_test.a -o a.html
  16. Uses GLES2 renderer or software
  17. Some other SDL2 libraries can be easily built (assuming SDL2 is installed somewhere):
  18. SDL_mixer (http://www.libsdl.org/projects/SDL_mixer/):
  19. $ EMCONFIGURE_JS=1 emconfigure ../configure
  20. build as usual...
  21. SDL_gfx (http://cms.ferzkopp.net/index.php/software/13-sdl-gfx):
  22. $ EMCONFIGURE_JS=1 emconfigure ../configure --disable-mmx
  23. build as usual...