From 9908278ba859794ab47739ff04b433ff9de8f19d Mon Sep 17 00:00:00 2001 From: Lucian Smith Date: Fri, 28 Aug 2026 14:25:28 -0700 Subject: [PATCH 1/5] Make ZLib optional. It was only needed for libsbml, and libsbml can be compiled without it. This was blocking building the WASM, since we don't have ZLIB there. --- CMakeLists.txt | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 59bcd72..2d682e4 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -47,13 +47,17 @@ else () endif () ## Find ZLIB -find_package(ZLIB CONFIG REQUIRED) -set(LIBZ_LIBRARY ZLIB::ZLIBSTATIC) -get_target_property(LIBZ_LIBRARY_LOCATION ZLIB::ZLIBSTATIC LOCATION) -message(STATUS "ZLIB Library: ${LIBZ_LIBRARY_LOCATION}") -set(ZLIB_LIBRARY "${LIBZ_LIBRARY_LOCATION}" CACHE FILEPATH "Path to zlib library" FORCE) -set(ZLIB_INCLUDE_DIR "${DEPENDENCIES_INSTALL_PREFIX}/include" CACHE PATH "Path to zlib include directory" FORCE) -set(ZLIB_FOUND TRUE CACHE BOOL "ZLIB found" FORCE) +option(WITH_ZLIB "Link libsbmlnetwork against zlib." ON) +set(LIBZ_LIBRARY "") +if (WITH_ZLIB) + find_package(ZLIB CONFIG REQUIRED) + set(LIBZ_LIBRARY ZLIB::ZLIBSTATIC) + get_target_property(LIBZ_LIBRARY_LOCATION ZLIB::ZLIBSTATIC LOCATION) + message(STATUS "ZLIB Library: ${LIBZ_LIBRARY_LOCATION}") + set(ZLIB_LIBRARY "${LIBZ_LIBRARY_LOCATION}" CACHE FILEPATH "Path to zlib library" FORCE) + set(ZLIB_INCLUDE_DIR "${DEPENDENCIES_INSTALL_PREFIX}/include" CACHE PATH "Path to zlib include directory" FORCE) + set(ZLIB_FOUND TRUE CACHE BOOL "ZLIB found" FORCE) +endif () ## Find expat find_package(expat CONFIG REQUIRED) From 25d8cca825738fc076c2003214cecbff4e522a8e Mon Sep 17 00:00:00 2001 From: Lucian Smith Date: Fri, 28 Aug 2026 14:33:12 -0700 Subject: [PATCH 2/5] Update dependencies. --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c0a2e11..5ab1cdc 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -70,8 +70,8 @@ jobs: libroadrunner_deps_owner: [ "sys-bio" ] libroadrunner_deps_repo: [ "libroadrunner-deps" ] libroadrunner_deps_name: [ "libroadrunner-deps" ] - libroadrunner_deps_release_version: [ "v2.2.22" ] - python_version: [ "3.11" ] + libroadrunner_deps_release_version: [ "v2.3.5" ] + python_version: [ "3.14" ] runs-on: ${{ matrix.platform.os_name }} container: image: ${{ matrix.platform.container_image || '' }} From 9c04874b9170b6a03d10f64a47cc6c4009d0446f Mon Sep 17 00:00:00 2001 From: Lucian Smith Date: Fri, 28 Aug 2026 15:00:26 -0700 Subject: [PATCH 3/5] More fixes to build in emscripten, and hopefully work on manylinux. --- .github/workflows/build.yml | 3 ++- CMakeLists.txt | 29 +++++++++++++++++++---------- 2 files changed, 21 insertions(+), 11 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5ab1cdc..6fa975b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -179,7 +179,8 @@ jobs: wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh bash Miniconda3-latest-Linux-x86_64.sh -b -p /Miniconda3 /Miniconda3/bin/conda create -y --name python${{ matrix.python_version }} python=${{ matrix.python_version }} - /Miniconda3/bin/conda init && bash ~/.bashrc && . ~/.bashrc cd ${RUNNER_WORKSPACE} + /Miniconda3/bin/conda init && bash ~/.bashrc && . ~/.bashrc + cd ${RUNNER_WORKSPACE} echo "export PATH=/Miniconda3/envs/python${{ matrix.python_version }}/bin:$PATH" >> "${GITHUB_ENV}" - name: Download Dependencies binaries diff --git a/CMakeLists.txt b/CMakeLists.txt index 2d682e4..d5c53d6 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -60,20 +60,29 @@ if (WITH_ZLIB) endif () ## Find expat -find_package(expat CONFIG REQUIRED) -set(EXPAT_LIBRARY expat::expat) -get_target_property(EXPAT_LIBRARY_LOCATION expat::expat LOCATION) -get_target_property(EXPAT_INCLUDE_DIR expat::expat INTERFACE_INCLUDE_DIRECTORIES) -message(STATUS "Expat Library: ${EXPAT_LIBRARY_LOCATION}") -message(STATUS "Expat Include: ${EXPAT_INCLUDE_DIR}") +if (DEFINED EXPAT_LIBRARY AND DEFINED EXPAT_INCLUDE_DIR) + message(STATUS "Expat Library: ${EXPAT_LIBRARY}") + message(STATUS "Expat Include: ${EXPAT_INCLUDE_DIR}") +else () + find_package(expat CONFIG REQUIRED) + set(EXPAT_LIBRARY expat::expat) + get_target_property(EXPAT_LIBRARY_LOCATION expat::expat LOCATION) + get_target_property(EXPAT_INCLUDE_DIR expat::expat INTERFACE_INCLUDE_DIRECTORIES) + message(STATUS "Expat Library: ${EXPAT_LIBRARY_LOCATION}") + message(STATUS "Expat Include: ${EXPAT_INCLUDE_DIR}") +endif () ## Find libSBML -find_package(${SBML_TARGET_NAME} CONFIG REQUIRED) -set(LIBSBML_LIBRARY ${SBML_TARGET_NAME}) -message(STATUS "libSBML Target: ${LIBSBML_LIBRARY}") +if (DEFINED LIBSBML_LIBRARY) + message(STATUS "libSBML Library: ${LIBSBML_LIBRARY}") +else () + find_package(${SBML_TARGET_NAME} CONFIG REQUIRED) + set(LIBSBML_LIBRARY ${SBML_TARGET_NAME}) + message(STATUS "libSBML Target: ${LIBSBML_LIBRARY}") +endif () ## Set dependencies include directory -set(DEPENDENCIES_INCLUDE_DIR "${DEPENDENCIES_INSTALL_PREFIX}/include") +set(DEPENDENCIES_INCLUDE_DIR "${DEPENDENCIES_INSTALL_PREFIX}/include" "${LIBSBML_INSTALL_PREFIX}/include" "${EXPAT_INCLUDE_DIR}") ## whether to build the dynamic version of the library set(BUILD_SHARED_LIBS ON CACHE BOOL "Build the dynamic version of the library") From 3b53ee232f70faa525c02c40b99f6d6d7e0739c6 Mon Sep 17 00:00:00 2001 From: Lucian Smith Date: Fri, 28 Aug 2026 15:12:43 -0700 Subject: [PATCH 4/5] Use GITHUB_PATH for manylinux build/tests. --- .github/workflows/build.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 6fa975b..a11eebd 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -179,9 +179,8 @@ jobs: wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh bash Miniconda3-latest-Linux-x86_64.sh -b -p /Miniconda3 /Miniconda3/bin/conda create -y --name python${{ matrix.python_version }} python=${{ matrix.python_version }} - /Miniconda3/bin/conda init && bash ~/.bashrc && . ~/.bashrc cd ${RUNNER_WORKSPACE} - echo "export PATH=/Miniconda3/envs/python${{ matrix.python_version }}/bin:$PATH" >> "${GITHUB_ENV}" + echo "/Miniconda3/envs/python${{ matrix.python_version }}/bin" >> "${GITHUB_PATH}" - name: Download Dependencies binaries shell: bash From a7b2f5428be776cefcb96dd64b123ad79633c231 Mon Sep 17 00:00:00 2001 From: Lucian Smith Date: Fri, 28 Aug 2026 15:30:46 -0700 Subject: [PATCH 5/5] Add python to the LD_LIBRARY_PATH. --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a11eebd..65f8e95 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -181,6 +181,7 @@ jobs: /Miniconda3/bin/conda create -y --name python${{ matrix.python_version }} python=${{ matrix.python_version }} cd ${RUNNER_WORKSPACE} echo "/Miniconda3/envs/python${{ matrix.python_version }}/bin" >> "${GITHUB_PATH}" + echo "LD_LIBRARY_PATH=/Miniconda3/envs/python${{ matrix.python_version }}/lib:$LD_LIBRARY_PATH" >> "${GITHUB_ENV}" - name: Download Dependencies binaries shell: bash