Skip to content

Commit

Permalink
SuiteSparse: update to v7.5.1-1 (#737)
Browse files Browse the repository at this point in the history
Update the SuiteSparse version to `v7.5.1-1`. This fixes a segementation
fault when using ceres-solver solver type `NESDIS`.
See: jlblancoc/suitesparse-metis-for-windows#123

Use METIS_IDXTYPEWIDTH=64, as with v7.5.1 SuiteSparse upstream has
incorporated Metis sources into the Cholmod module and made it a private
dependency with the 64bit width requirement.
  • Loading branch information
NeroBurner committed Jan 26, 2024
1 parent 77f696e commit 210f2c7
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion cmake/configs/default.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ hunter_default_version(SimpleSignal VERSION 0.0.0-79c3f68-p1)
hunter_default_version(Snappy VERSION 1.1.7)
hunter_default_version(Sober VERSION 0.1.3)
hunter_default_version(Sqlpp11 VERSION 0.57-p0)
hunter_default_version(SuiteSparse VERSION 5.4.0-2)
hunter_default_version(SuiteSparse VERSION 7.5.1-1)
hunter_default_version(TCLAP VERSION 1.2.2-p1)
hunter_default_version(TIFF VERSION 4.0.2-p5)
hunter_default_version(Tesseract VERSION 3.05.01-hunter-3)
Expand Down
20 changes: 19 additions & 1 deletion cmake/projects/SuiteSparse/hunter.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,17 @@ hunter_add_version(
c85cc6149dc44e7d351b5549c6e23a53ff94bc23
)

hunter_add_version(
PACKAGE_NAME
SuiteSparse
VERSION
"7.5.1-1"
URL
"https://github.com/jlblancoc/suitesparse-metis-for-windows/archive/refs/tags/v7.5.1-1.tar.gz"
SHA1
82d7c5f577694472a6ba1d7967625c043d4ab816
)

if(HUNTER_SuiteSparse_VERSION VERSION_LESS 5.4.0)
set(_SuiteSparse_BUILD_METIS NO)
set(_SuiteSparse_WITH_OPENBLAS NO)
Expand All @@ -95,13 +106,20 @@ else()
# f2c-converted LAPACK v3.9.0 implementation, making the build C++ only
set(_SuiteSparse_WITH_OPENBLAS YES)
endif()
if(HUNTER_SuiteSparse_VERSION VERSION_LESS 7.5.1)
# since 5.4.0-2, needed for compatibility with ceres-solver 2.2.0
set(_SuiteSparse_METIS_IDXTYPEWIDTH 32)
else()
# since SuiteSparse 7.5.1-1 metis is internal only and requires 64 bit
set(_SuiteSparse_METIS_IDXTYPEWIDTH 64)
endif()

hunter_cmake_args(
SuiteSparse
CMAKE_ARGS
BUILD_METIS=${_SuiteSparse_BUILD_METIS}
WITH_OPENBLAS=${_SuiteSparse_WITH_OPENBLAS}
METIS_IDXTYPEWIDTH=32 # since 5.4.0-2, needed for compatibility with ceres-solver 2.2.0
METIS_IDXTYPEWIDTH=${_SuiteSparse_METIS_IDXTYPEWIDTH}
HUNTER_INSTALL_LICENSE_FILES=LICENSE.md
)

Expand Down

0 comments on commit 210f2c7

Please sign in to comment.