aorecomp

Anarchy Online classic in the browser

git clone https://aorecomp.ubeagle.com/code/aorecomp.git


tools/client/Dockerfile.wasm (878B)


      1 # Emscripten 6.0.12, including its SDK checkout and Linux amd64 build tools.
      2 FROM docker.io/emscripten/emsdk:6.0.12@sha256:52549e68ad6dd0f3509ff378bc1a5d317d40030c8991919cada0dad95d85e00c
      3 
      4 COPY wasm-requirements.txt /opt/wasm-requirements.txt
      5 RUN python3 -m pip install --require-hashes --only-binary=:all: \
      6     --target=/opt/wasm-python -r /opt/wasm-requirements.txt
      7 ENV PYTHONPATH=/opt/wasm-python
      8 
      9 # Preserve downloaded sources, compiled audio libraries and Emscripten ports.
     10 WORKDIR /build
     11 RUN mkdir -p toolchains && ln -s /emsdk toolchains/emsdk
     12 COPY build_wasm_dependencies.py tools/client/build_wasm_dependencies.py
     13 RUN python3 tools/client/build_wasm_dependencies.py \
     14     && emcc local/wasm/dependency-probe.c -pthread -sUSE_ZLIB=1 \
     15         -o local/wasm/zlib-probe.js
     16 
     17 COPY build_wasm_container.sh /usr/local/bin/build-wasm
     18 CMD ["bash", "/usr/local/bin/build-wasm"]