bartjuw is building libantimonyjs #36
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build-libantimoyjs-github-actions | |
run-name: ${{ github.actor }} is building libantimonyjs | |
on: [push] | |
jobs: | |
build-new-version-antimonyjs: | |
runs-on: ubuntu-latest | |
env: | |
EMSDK: emsdk | |
EMSDK_NODE: emsdk/node/16.20.0_64bit/bin/node | |
LIBANTIMONYJS_DIR: libantimonyjs | |
SBML_VERS: "5.20.0" | |
steps: | |
- uses: actions/checkout@v4 | |
- run: ls | |
- name: get emscripten | |
run: git clone https://github.com/emscripten-core/emsdk.git | |
- name: list files | |
run: ls | |
working-directory: emsdk | |
- name: change emsdk script permissions | |
run: chmod +x emsdk | |
working-directory: emsdk | |
- name: install emscripten sdk | |
run: ./emsdk install 3.1.20 | |
working-directory: emsdk | |
- name: activate emscripten | |
run: ./emsdk activate 3.1.20 | |
working-directory: emsdk | |
- run: pwd | |
- run: echo "$GITHUB_WORKSPACE/emsdk/upstream/emscripten" >> $GITHUB_PATH | |
- run: echo "$GITHUB_WORKSPACE/emsdk" >> $GITHUB_PATH | |
- run: echo $GITHUB_PATH | |
- name: confirm emscripten works | |
run: emcc -v | |
- run: echo $PATH | |
- run: echo $EMSDK | |
- run: echo $EMSDK_NODE | |
- run: echo $LIBANTIMONY_JS | |
- run: mkdir install | |
- run: wget https://github.com/libexpat/libexpat/releases/download/R_2_2_10/expat-2.2.10.tar.bz2 | |
- run: tar -xf expat-2.2.10.tar.bz2 | |
- run: mv expat-2.2.10 expat | |
- name: make expat build dir | |
run: mkdir build | |
working-directory: expat | |
- name: build expat lib | |
run: emcmake cmake .. -DCMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/install/expat | |
working-directory: expat/build | |
- name: make expat lib | |
run: emmake make | |
working-directory: expat/build | |
- name: install expat lib | |
run: emmake make install | |
working-directory: expat/build | |
- name: Get libSBML | |
run: wget https://github.com/sbmlteam/libsbml/archive/refs/tags/v$SBML_VERS.zip | |
- run: unzip v$SBML_VERS.zip | |
- run: mv libsbml-$SBML_VERS libsbml | |
- name: make libsbml build dir | |
run: mkdir build | |
working-directory: libsbml | |
- name: build libsbml lib | |
run: emcmake cmake .. -DCMAKE_INSTALL_PREFIX=$GITHUB_WORKSPACE/install/sbml -DCMAKE_BUILD_TYPE=Release -DWITH_CPP_NAMESPACE=ON -DWITH_EXPAT=ON -DWITH_LIBXML=OFF -DLIBSBML_SKIP_SHARED_LIBRARY=ON -DENABLE_ARRAYS=ON -DENABLE_COMP=ON -DENABLE_DISTRIB=ON -DENABLE_FBC=ON -DENABLE_GROUPS=ON -DENABLE_MULTI=ON -DENABLE_QUAL=ON -DWITH_STABLE_PACKAGES=ON -DWITH_SWIG=OFF -DEXPAT_INCLUDE_DIR=$GITHUB_WORKSPACE/install/expat/include -DEXPAT_LIBRARY=$GITHUB_WORKSPACE/install/expat/lib/libexpat.a | |
working-directory: libsbml/build | |
- name: make libsbml lib | |
run: emmake make | |
working-directory: libsbml/build | |
- name: install libsbml | |
run: emmake make install | |
working-directory: libsbml/build | |