Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix missing RMM_STATIC_CUDART define when compiling JNI with static CUDA runtime #10585

Merged
merged 1 commit into from
Apr 4, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions java/ci/build-in-docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ mkdir -p "$WORKSPACE/cpp/build"
cd "$WORKSPACE/cpp/build"
cmake .. -G"${CMAKE_GENERATOR}" \
-DCMAKE_INSTALL_PREFIX=$INSTALL_PREFIX \
-DCUDA_STATIC_RUNTIME=$ENABLE_CUDA_STATIC_RUNTIME \
-DUSE_NVTX=$ENABLE_NVTX \
-DCUDF_USE_ARROW_STATIC=ON \
-DCUDF_ENABLE_ARROW_S3=OFF \
Expand Down
22 changes: 3 additions & 19 deletions java/src/main/native/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -115,21 +115,7 @@ rapids_find_package(ZLIB REQUIRED)
# ##################################################################################################
# * RMM -------------------------------------------------------------------------------------------

find_path(
RMM_INCLUDE "rmm"
HINTS "${CUDF_CPP_BUILD_DIR}/_deps/rmm-src/include" "$ENV{RMM_ROOT}/include"
"$ENV{RMM_HOME}/include" "$ENV{CONDA_PREFIX}/include/rmm" "$ENV{CONDA_PREFIX}/include"
)

message(STATUS "RMM: RMM_INCLUDE set to ${RMM_INCLUDE}")

find_path(
SPDLOG_INCLUDE "spdlog"
HINTS "${CUDF_CPP_BUILD_DIR}/_deps/spdlog-src/include" "$ENV{RMM_ROOT}/_deps/spdlog-src/include"
"$ENV{RMM_ROOT}/include" "$ENV{CONDA_PREFIX}/include"
)

message(STATUS "SPDLOG: SPDLOG_INCLUDE set to ${SPDLOG_INCLUDE}")
include(${CUDF_SOURCE_DIR}/cmake/thirdparty/get_rmm.cmake)

# ##################################################################################################
# * ARROW -----------------------------------------------------------------------------------------
Expand Down Expand Up @@ -255,11 +241,9 @@ target_include_directories(
"${NVCOMP_INCLUDE}"
"${CMAKE_BINARY_DIR}/include"
"${CMAKE_SOURCE_DIR}/include"
"${SPDLOG_INCLUDE}"
"${CMAKE_SOURCE_DIR}/src"
"${JNI_INCLUDE_DIRS}"
"${CUDF_INCLUDE}"
"${RMM_INCLUDE}"
"${ARROW_INCLUDE}"
)

Expand Down Expand Up @@ -296,7 +280,7 @@ if(USE_GDS)
PUBLIC "${LIBCUDACXX_INCLUDE}" "${CUDF_INCLUDE}"
PRIVATE "${cuFile_INCLUDE_DIRS}"
)
target_link_libraries(cufilejni PRIVATE cudfjni "${cuFile_LIBRARIES}")
target_link_libraries(cufilejni PRIVATE cudfjni rmm::rmm "${cuFile_LIBRARIES}")
endif()

# ##################################################################################################
Expand All @@ -323,7 +307,7 @@ if(CUDF_JNI_LIBCUDF_STATIC)
endif()

target_link_libraries(
cudfjni PRIVATE ${CUDF_LINK} ${NVCOMP_LIBRARY} ${ARROW_LIBRARY} CUDA::cuda_driver
cudfjni PRIVATE ${CUDF_LINK} ${NVCOMP_LIBRARY} ${ARROW_LIBRARY} rmm::rmm CUDA::cuda_driver
)

# ##################################################################################################
Expand Down