Skip to content

Commit

Permalink
Link CMAKE_DL_LIBS when dlopen is used. (#10447)
Browse files Browse the repository at this point in the history
  • Loading branch information
trivialfis authored Jun 19, 2024
1 parent 45150a8 commit 63418d2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions cmake/Utils.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,7 @@ function(xgboost_link_nccl target)
set(xgboost_nccl_flags -DXGBOOST_USE_NCCL=1)
if(USE_DLOPEN_NCCL)
list(APPEND xgboost_nccl_flags -DXGBOOST_USE_DLOPEN_NCCL=1)
target_link_libraries(${target} PRIVATE ${CMAKE_DL_LIBS})
endif()

if(BUILD_STATIC_LIB)
Expand Down

0 comments on commit 63418d2

Please sign in to comment.