Update SuiteSparse to v7.12.2 (submodule + upstream CMake)#218
Draft
SVAGEN26 wants to merge 3 commits into
Draft
Update SuiteSparse to v7.12.2 (submodule + upstream CMake)#218SVAGEN26 wants to merge 3 commits into
SVAGEN26 wants to merge 3 commits into
Conversation
This was referenced Jun 21, 2026
Remove the hand-written 268-line wrapper CMakeLists.txt and the entire in-tree SuiteSparse-5.8.1 copy. Add DrTimothyAldenDavis/SuiteSparse as a git submodule pinned to release tag v7.12.2. All special handling (target aliasing, KLU_LIBRARY, SUITESPARSECONFIG_LIBRARY, include directories) will move to OMCompiler/3rdParty/CMakeLists.txt in the main repository as part of the matching PR. Refs OpenModelica/OpenModelica#15595 Co-Authored-By: JKRT_CLAUDE <247156613+SVAGEN26@users.noreply.github.com>
Delegate the SuiteSparse build to the upstream top-level CMakeLists by setting SUITESPARSE_ENABLE_PROJECTS to the subset OMC actually consumes (suitesparse_config, amd, colamd, btf, klu, umfpack) and disabling optional features (OpenMP, CUDA, Fortran, demos, CHOLMOD in KLU and UMFPACK). Static targets exported by v7 are SuiteSparseConfig_static, AMD_static, COLAMD_static, BTF_static, KLU_static and UMFPACK_static. Alias them to the existing omc::3rd::suitesparse::* names and set KLU_LIBRARY etc. to the static target names so Sundials 5.4 picks them up. Linux build of the full omc plus the SimulationRuntime ctest unit tests both green. Refs OpenModelica/OpenModelica#15595 Co-Authored-By: JKRT_CLAUDE <247156613+SVAGEN26@users.noreply.github.com>
535f583 to
cc1873e
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Replaces the vendored
SuiteSparse-5.8.1/directory and its hand-written 268-line wrapperCMakeLists.txtwith a git submodule pinned toDrTimothyAldenDavis/SuiteSparserelease tagv7.12.2. All special handling moves to the parentOMCompiler/3rdParty/CMakeLists.txtand delegates to upstream SuiteSparse CMake viaSUITESPARSE_ENABLE_PROJECTS.Root cause / motivation
Refs OpenModelica/OpenModelica#15595. SuiteSparse 5.8.1 (2020) is well behind upstream; v6+ moved to per-subpackage CMake and v7 changed several APIs and headers. The existing wrapper does not survive the version bump.
Change details
SuiteSparsepinned tov7.12.2.suitesparse_config;amd;colamd;btf;klu;umfpack.BUILD_STATIC_LIBS=ON,BUILD_SHARED_LIBS=OFF.KLU_USE_CHOLMOD=OFF,UMFPACK_USE_CHOLMOD=OFF(OMC does not use CHOLMOD).omc::3rd::suitesparse::*namespace.KLU_LIBRARY,AMD_LIBRARY, etc.) repointed at the static targets so Sundials 5.4 picks them up.Tested
omcon Linux passes.Scope
Per AnHeuermann's direction on #15595, Linux CI is the bar; Windows regressions and Makefile prettiness are explicitly deferred. The OMC runtime header fix (drop obsolete
umfpack_get_numeric.hinclude) lives in the matching OpenModelica/OpenModelica PR.Companion PR on the main repository will be linked here.