gentoo-ebuilds/sci-libs/hipSOLVER/files/hipSOLVER-7.0.1-find-cholmod.patch
Sv. Lockal fa56164ea8
sci-libs/hipSOLVER: add 7.0.2
Bug: https://bugs.gentoo.org/964799

Signed-off-by: Sv. Lockal <lockalsash@gmail.com>
Part-of: https://github.com/gentoo/gentoo/pull/44165
Signed-off-by: Sam James <sam@gentoo.org>
2025-10-21 19:47:35 +01:00

21 lines
919 B
Diff

Gentoo install cholmod.h into /usr/include directly and uses PkgConfig
--- a/library/src/CMakeLists.txt
+++ b/library/src/CMakeLists.txt
@@ -153,14 +153,10 @@ if(NOT USE_CUDA)
list(APPEND static_depends PACKAGE rocsparse)
endif()
- find_package(CHOLMOD QUIET)
- if(NOT TARGET SuiteSparse::CHOLMOD)
- # try again with the custom find modules for older versions of suitesparse
- list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/suitesparse)
- find_package(CHOLMOD REQUIRED)
- endif()
+ find_package(PkgConfig REQUIRED)
+ pkg_check_modules(CHOLMOD REQUIRED IMPORTED_TARGET cholmod)
- target_link_libraries( hipsolver PRIVATE roc::rocsparse SuiteSparse::CHOLMOD)
+ target_link_libraries( hipsolver PRIVATE roc::rocsparse PkgConfig::CHOLMOD)
set_source_files_properties(${hipsolver_source}
PROPERTIES
COMPILE_DEFINITIONS HAVE_ROCSPARSE