From ad6daeb303591ceb66cfc91a9800bf21a6bd3932 Mon Sep 17 00:00:00 2001 From: kdx Date: Wed, 3 Jan 2024 03:02:44 +0100 Subject: web build --- emcc.sh | 11 +++++++++++ src/index.html | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ vendors/TZR.c | 3 +-- vendors/TZR.h | 2 +- 4 files changed, 62 insertions(+), 3 deletions(-) create mode 100755 emcc.sh create mode 100644 src/index.html diff --git a/emcc.sh b/emcc.sh new file mode 100755 index 0000000..5b8d13b --- /dev/null +++ b/emcc.sh @@ -0,0 +1,11 @@ +#!/bin/sh +tup || exit 1 +rm -f build/index.* +cp src/index.html build || exit 1 +cd build || exit 1 +cp -r ../res . || exit 1 +emcc -sUSE_SDL=2 -sUSE_SDL_MIXER=2 -sALLOW_MEMORY_GROWTH \ + -O3 -s -std=c2x -Wno-initializer-overrides \ + ../src/*.c ../vendors/*.c \ + -I../inc -I../vendors -include../vendors/_.h \ + -o index.js --preload-file res diff --git a/src/index.html b/src/index.html new file mode 100644 index 0000000..e48f3af --- /dev/null +++ b/src/index.html @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + diff --git a/vendors/TZR.c b/vendors/TZR.c index e28348f..ac34f5a 100644 --- a/vendors/TZR.c +++ b/vendors/TZR.c @@ -23,7 +23,6 @@ #include #include #include -#include #include #include #include @@ -1416,4 +1415,4 @@ TZR_ToggleFullscreen(void) ** FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS ** IN THE SOFTWARE. */ -/* commit hash: 221a7d0618b4f8b6af19b089f49818806fe1e1b3 */ +/* commit hash: 3855a2ebd550fb89c8c70caa3776bef532ec87e7 */ diff --git a/vendors/TZR.h b/vendors/TZR.h index a06ea3b..47169a8 100644 --- a/vendors/TZR.h +++ b/vendors/TZR.h @@ -499,4 +499,4 @@ int TZR_SetViewportSize(int width, int height); ** FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS ** IN THE SOFTWARE. */ -/* commit hash: 221a7d0618b4f8b6af19b089f49818806fe1e1b3 */ +/* commit hash: 3855a2ebd550fb89c8c70caa3776bef532ec87e7 */ -- cgit v1.2.3