Skip to content

Commit

Permalink
Pass on -DSUITESPARSE_CUDA to projects linking to GraphBLAS_CUDA
Browse files Browse the repository at this point in the history
  • Loading branch information
mmuetzel committed Sep 13, 2023
1 parent fdefecf commit a60daf3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 0 additions & 1 deletion GraphBLAS/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ endif ( )

if ( SUITESPARSE_CUDA )
# with CUDA and RMM
set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DSUITESPARSE_CUDA" )
add_subdirectory ( CUDA )
set ( GB_CUDA GraphBLAS_CUDA ${CUDA_LIBRARIES} )
set ( GB_RMM rmm_wrap ${CUDA_LIBRARIES} )
Expand Down
2 changes: 2 additions & 0 deletions GraphBLAS/CUDA/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ set_target_properties(GraphBLAS_CUDA PROPERTIES CUDA_ARCHITECTURES "52;75;80" )

target_link_libraries(GraphBLAS_CUDA CUDA::nvrtc CUDA::cudart_static CUDA::cuda_driver CUDA::nvToolsExt )

target_compile_definitions ( GraphBLAS_CUDA PUBLIC "SUITESPARSE_CUDA" )

target_include_directories ( GraphBLAS_CUDA
INTERFACE $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
$<INSTALL_INTERFACE:${SUITESPARSE_INCLUDEDIR}> )
Expand Down
2 changes: 1 addition & 1 deletion GraphBLAS/CUDA/Config/GraphBLAS_CUDA.pc.in
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ URL: https://github.com/DrTimothyAldenDavis/SuiteSparse
Description: CUDA support library for GraphBLAS in SuiteSparse
Version: @GraphBLAS_VERSION_MAJOR@.@GraphBLAS_VERSION_MINOR@.@GraphBLAS_VERSION_SUB@
Libs: -L${libdir} -lgraphblascuda
Cflags: -I${includedir}
Cflags: -I${includedir} -DSUITESPARSE_CUDA

0 comments on commit a60daf3

Please sign in to comment.