From 7e5f5633028f121523f890476289e2e93ce845ad Mon Sep 17 00:00:00 2001 From: LTLA Date: Wed, 2 Oct 2024 10:10:54 -0700 Subject: [PATCH] Do a few test runs to prebuild system libraries and ports. --- .gitignore | 2 ++ Dockerfile | 9 +++++++++ 2 files changed, 11 insertions(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..af972e0 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +*.swp +test-* diff --git a/Dockerfile b/Dockerfile index 467777f..de6716e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -15,4 +15,13 @@ RUN wget https://github.com/Kitware/CMake/releases/download/v3.30.4/cmake-3.30.4 bash cmake_install.sh --prefix=cmake --skip-license && \ rm cmake_install.sh +# Prebuilding system libraries so that we don't have to do it again in each use case. +RUN mkdir test-bar && \ + touch test-bar/foo.c && \ + cd test-bar && \ + emcc --use-port=zlib -pthread --bind foo.c -o alpha \ + emcc --use-port=zlib -pthread --bind -O3 foo.c -o bravo \ + cd ../ && \ + rm -rf test-bar + ENV PATH="/emsdk:/emsdk/upstream/emscripten:/cmake/bin:${PATH}"