Skip to content

Commit

Permalink
sync
Browse files Browse the repository at this point in the history
  • Loading branch information
DrTimothyAldenDavis committed Dec 6, 2023
1 parent d5c547a commit b177d27
Showing 1 changed file with 27 additions and 17 deletions.
44 changes: 27 additions & 17 deletions cmake_modules/FindGraphBLAS.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -80,41 +80,51 @@ if ( GraphBLAS_FOUND )
message ( STATUS "Found SuiteSparse::GraphBLAS" )
get_property ( _graphblas_aliased TARGET SuiteSparse::GraphBLAS
PROPERTY ALIASED_TARGET )
if ( "${_graphblas_aliased}" STREQUAL "" )
add_library ( GraphBLAS::GraphBLAS ALIAS SuiteSparse::GraphBLAS )
else ( )
add_library ( GraphBLAS::GraphBLAS ALIAS ${_graphblas_aliased} )
endif ( )
if ( GRAPHBLAS_VERSION LESS "8.3.0" AND _lagraph_gb_common_tree )
# workaround for incorrect INTERFACE_INCLUDE_DIRECTORIES of
# SuiteSparse:GraphBLAS 8.2.x before installation
# (did not have "/Include")
get_property ( _inc TARGET GraphBLAS::GraphBLAS PROPERTY
get_property ( _inc TARGET SuiteSparse::GraphBLAS PROPERTY
INTERFACE_INCLUDE_DIRECTORIES )
target_include_directories ( GraphBLAS::GraphBLAS INTERFACE
${_inc}/Include )
if ( "${_graphblas_aliased}" STREQUAL "" )
target_include_directories ( SuiteSparse::GraphBLAS INTERFACE
${_inc}/Include )
else ( )
target_include_directories ( ${_graphblas_aliased} INTERFACE
${_inc}/Include )
endif ( )
message ( STATUS "additional include: ${_inc}/Include" )
endif ( )
if ( "${_graphblas_aliased}" STREQUAL "" )
add_library ( GraphBLAS::GraphBLAS ALIAS SuiteSparse::GraphBLAS )
else ( )
add_library ( GraphBLAS::GraphBLAS ALIAS ${_graphblas_aliased} )
endif ( )
endif ( )
if ( TARGET SuiteSparse::GraphBLAS_static )
message ( STATUS "Found SuiteSparse::GraphBLAS_static" )
# It's not possible to create an alias of an alias.
get_property ( _graphblas_aliased TARGET SuiteSparse::GraphBLAS_static
PROPERTY ALIASED_TARGET )
if ( "${_graphblas_aliased}" STREQUAL "" )
add_library ( GraphBLAS::GraphBLAS_static ALIAS SuiteSparse::GraphBLAS_static )
else ( )
add_library ( GraphBLAS::GraphBLAS_static ALIAS ${_graphblas_aliased} )
endif ( )
if ( GRAPHBLAS_VERSION LESS "8.3.0" AND _lagraph_gb_common_tree )
# workaround for incorrect INTERFACE_INCLUDE_DIRECTORIES of
# SuiteSparse:GraphBLAS 8.2.x before installation
# (did not have "/Include")
get_property ( _inc TARGET GraphBLAS::GraphBLAS_static PROPERTY
get_property ( _inc TARGET SuiteSparse::GraphBLAS_static PROPERTY
INTERFACE_INCLUDE_DIRECTORIES )
target_include_directories ( GraphBLAS::GraphBLAS_static INTERFACE
${_inc}/Include )
message ( STATUS "additional include: ${_inc}/Include" )
if ( "${_graphblas_aliased}" STREQUAL "" )
target_include_directories ( SuiteSparse::GraphBLAS_static INTERFACE
${_inc}/Include )
else ( )
target_include_directories ( ${_graphblas_aliased} INTERFACE
${_inc}/Include )
endif ( )
message ( STATUS "additional include: ${_inc}/Include" )
endif ( )
if ( "${_graphblas_aliased}" STREQUAL "" )
add_library ( GraphBLAS::GraphBLAS_static ALIAS SuiteSparse::GraphBLAS_static )
else ( )
add_library ( GraphBLAS::GraphBLAS_static ALIAS ${_graphblas_aliased} )
endif ( )
endif ( )
return ( )
Expand Down

0 comments on commit b177d27

Please sign in to comment.