From 63c3b9bda3fe7eb8750f084ff070f40b967f9532 Mon Sep 17 00:00:00 2001 From: Mitya Selivanov Date: Fri, 1 Nov 2024 05:04:25 +0100 Subject: Build wasm without Emscripten --- Dockerfile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Dockerfile') diff --git a/Dockerfile b/Dockerfile index 4b0f30f..1967156 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,6 +1,7 @@ -FROM emscripten/emsdk as build +FROM alpine as build +RUN apk add clang lld COPY reduced_system_layer.c /usr/reduced_system_layer.c -RUN emcc -D REDUCED_SYSTEM_LAYER_EXAMPLE -s ERROR_ON_UNDEFINED_SYMBOLS=0 -s EXPORTED_FUNCTIONS=_js_main,_js_init,_js_pixels,_js_frame -o /usr/index.wasm /usr/reduced_system_layer.c +RUN clang -D REDUCED_SYSTEM_LAYER_EXAMPLE --target=wasm32 -nostdlib -Wl,--no-entry,--allow-undefined -o /usr/index.wasm /usr/reduced_system_layer.c FROM nginx:alpine EXPOSE 80 -- cgit v1.2.3