[suitesparse] Fixing SuiteSparse_INCLUDE_DIRS is not usable from the port. (#11945)

* correct _SuiteSparse_PREFIX.

* Update portfile.cmake
This commit is contained in:
Sean Yen 2020-06-30 14:43:32 -07:00 committed by GitHub
parent 3f6342db6d
commit 7c9bf0a6cd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 6 deletions

View File

@ -1,5 +1,5 @@
Source: suitesparse Source: suitesparse
Version: 5.4.0-5 Version: 5.4.0-6
Build-Depends: clapack (!osx) Build-Depends: clapack (!osx)
Homepage: http://faculty.cse.tamu.edu/davis/SuiteSparse Homepage: http://faculty.cse.tamu.edu/davis/SuiteSparse
Description: algebra library Description: algebra library

View File

@ -117,12 +117,14 @@ index c6e2834..5ef08a6 100644
# Disable COMPLEX numbers: disable it by default, since it causes problems in some platforms. # Disable COMPLEX numbers: disable it by default, since it causes problems in some platforms.
SET(HAVE_COMPLEX OFF CACHE BOOL "Enables building SuiteSparse with complex numbers (disabled by default to avoid problems in some platforms)") SET(HAVE_COMPLEX OFF CACHE BOOL "Enables building SuiteSparse with complex numbers (disabled by default to avoid problems in some platforms)")
diff --git a/cmake/SuiteSparse-config-install.cmake.in b/cmake/SuiteSparse-config-install.cmake.in diff --git a/cmake/SuiteSparse-config-install.cmake.in b/cmake/SuiteSparse-config-install.cmake.in
index cb1f51f..49387b8 100644 index cb1f51f..12f654c 100644
--- a/cmake/SuiteSparse-config-install.cmake.in --- a/cmake/SuiteSparse-config-install.cmake.in
+++ b/cmake/SuiteSparse-config-install.cmake.in +++ b/cmake/SuiteSparse-config-install.cmake.in
@@ -4,13 +4,10 @@ get_filename_component(_SuiteSparse_PREFIX "${_SuiteSparse_SELF_DIR}" PATH) @@ -2,15 +2,11 @@
get_filename_component(_SuiteSparse_PREFIX "${_SuiteSparse_PREFIX}" PATH) get_filename_component(_SuiteSparse_SELF_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
get_filename_component(_SuiteSparse_PREFIX "${_SuiteSparse_SELF_DIR}" PATH)
get_filename_component(_SuiteSparse_PREFIX "${_SuiteSparse_PREFIX}" PATH) get_filename_component(_SuiteSparse_PREFIX "${_SuiteSparse_PREFIX}" PATH)
-get_filename_component(_SuiteSparse_PREFIX "${_SuiteSparse_PREFIX}" PATH)
-find_package(LAPACK CONFIG) -find_package(LAPACK CONFIG)
-if (NOT LAPACK_FOUND) # Load the LAPACK package with which we were built. -if (NOT LAPACK_FOUND) # Load the LAPACK package with which we were built.
@ -136,7 +138,7 @@ index cb1f51f..49387b8 100644
# Report SuiteSparse header search locations. # Report SuiteSparse header search locations.
set(SuiteSparse_INCLUDE_DIRS ${_SuiteSparse_PREFIX}/include) set(SuiteSparse_INCLUDE_DIRS ${_SuiteSparse_PREFIX}/include)
@@ -31,6 +28,11 @@ set(SuiteSparse_LIBRARIES @@ -31,6 +27,10 @@ set(SuiteSparse_LIBRARIES
SuiteSparse::spqr SuiteSparse::spqr
@SuiteSparse_EXPORTED_METIS_LIBS@ @SuiteSparse_EXPORTED_METIS_LIBS@
) )
@ -147,4 +149,3 @@ index cb1f51f..49387b8 100644
+ +
+set(SUITESPARSE_FOUND TRUE) +set(SUITESPARSE_FOUND TRUE)
+set(SuiteSparse_FOUND TRUE) +set(SuiteSparse_FOUND TRUE)
+