3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-05 17:14:07 +00:00

Use emscripten to create a wasm build (#5634)

This commit is contained in:
Leonardo 2021-10-29 16:01:06 +02:00 committed by GitHub
parent d1fbf013eb
commit e7a54db8b0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -16,15 +16,19 @@ jobs:
uses: actions/checkout@v2
- name: Configure CMake and build
uses: mymindstorm/setup-emsdk@v9
run: |
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }} -DCMAKE_SYSTEM_NAME=WASM -DCMAKE_SYSTEM_VERSION=21
make -j $(nproc)
tar -cvf z3-build-wasm.tar *.jar *.so
- name: Archive production artifacts
uses: actions/upload-artifact@v2
with:
name: build-wasm
path: build/z3-build-wasm.tar
emcmake cmake \
-DCMAKE_BUILD_TYPE=MinSizeRel \
-DCMAKE_INSTALL_PREFIX=/emsdk/upstream/emscripten/system \
-DZ3_BUILD_LIBZ3_SHARED=OFF \
-DZ3_ENABLE_EXAMPLE_TARGETS=OFF \
-DZ3_BUILD_TEST_EXECUTABLES=OFF \
-DZ3_BUILD_EXECUTABLE=OFF \
-DZ3_SINGLE_THREADED=ON \
-DCMAKE_CXX_FLAGS="-s DISABLE_EXCEPTION_CATCHING=0" \
..; \
make ; make install; \