Skip to content

Commit

Permalink
Update Emscripten CI (#416)
Browse files Browse the repository at this point in the history
  • Loading branch information
anutosh491 authored Jan 9, 2025
1 parent d1a9fa4 commit a22275a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
15 changes: 9 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -151,28 +151,31 @@ jobs:
create-args: libuuid

- name: Setup emsdk
run: emsdk install ${{ matrix.emsdk_ver }}
shell: bash -l {0}
run: |
cd $HOME
git clone https://github.com/emscripten-core/emsdk.git
cd emsdk
./emsdk install ${{ matrix.emsdk_ver }}
- name: Build and package xeus
run: |
emsdk activate ${{ matrix.emsdk_ver }}
source $CONDA_EMSDK_DIR/emsdk_env.sh
$HOME/emsdk/emsdk activate ${{matrix.emsdk_ver}}
source $HOME/emsdk/emsdk_env.sh
micromamba create -f environment-wasm-host.yml --platform=emscripten-wasm32
mkdir build
pushd build
export EMPACK_PREFIX=$MAMBA_ROOT_PREFIX/envs/xeus-wasm-build
export PREFIX=$MAMBA_ROOT_PREFIX/envs/xeus-wasm-host
export CMAKE_PREFIX_PATH=$PREFIX
export CMAKE_SYSTEM_PREFIX_PATH=$PREFIX
emcmake cmake \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_FIND_ROOT_PATH_MODE_PACKAGE=ON \
-DCMAKE_FIND_ROOT_PATH=$PREFIX \
-DXEUS_EMSCRIPTEN_WASM_BUILD=ON \
-Dnlohmann_json_DIR=$MAMBA_ROOT_PREFIX/share/cmake/nlohmann_json \
..
make -j${{ steps.cpu-cores.outputs.count }}
2 changes: 0 additions & 2 deletions environment-wasm-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,4 @@ channels:
- conda-forge
dependencies:
- cmake
- emsdk >=3.1.11
- empack >=2.0.1

0 comments on commit a22275a

Please sign in to comment.