From 34e62cfb280dda4b8119d88e63c619311fed1dcb Mon Sep 17 00:00:00 2001 From: ptaylor Date: Tue, 7 Sep 2021 17:57:45 -0500 Subject: [PATCH 1/2] fix typo in the name of cudf-testing-targets.cmake --- cpp/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpp/CMakeLists.txt b/cpp/CMakeLists.txt index 81377a7ebc2..de6530084ad 100644 --- a/cpp/CMakeLists.txt +++ b/cpp/CMakeLists.txt @@ -738,7 +738,7 @@ rapids_export(BUILD cudf FINAL_CODE_BLOCK build_code_string) export(EXPORT cudf-testing-exports - FILE ${CUDF_BINARY_DIR}/cudf-testing.cmake + FILE ${CUDF_BINARY_DIR}/cudf-testing-targets.cmake NAMESPACE cudf::) rapids_export_write_dependencies(BUILD cudf-testing-exports "${CUDF_BINARY_DIR}/cudf-testing-dependencies.cmake") From e0ef1b18fb2d9300fe82b669b98accb352a1e593 Mon Sep 17 00:00:00 2001 From: ptaylor Date: Tue, 7 Sep 2021 18:47:16 -0500 Subject: [PATCH 2/2] add Arrow targets to build and install export sets after the ArrowCUDA_DIR has been populated --- cpp/cmake/thirdparty/get_arrow.cmake | 56 ++++++++++++++-------------- 1 file changed, 28 insertions(+), 28 deletions(-) diff --git a/cpp/cmake/thirdparty/get_arrow.cmake b/cpp/cmake/thirdparty/get_arrow.cmake index c67f316f7e9..3309be62dc3 100644 --- a/cpp/cmake/thirdparty/get_arrow.cmake +++ b/cpp/cmake/thirdparty/get_arrow.cmake @@ -101,34 +101,6 @@ function(find_and_configure_arrow VERSION BUILD_STATIC ENABLE_S3 ENABLE_ORC ENAB "ARROW_PROTOBUF_USE_SHARED ${ARROW_BUILD_SHARED}" "ARROW_ZSTD_USE_SHARED ${ARROW_BUILD_SHARED}") - if(Arrow_ADDED) - rapids_export(BUILD Arrow - VERSION ${VERSION} - EXPORT_SET arrow_targets - GLOBAL_TARGETS arrow_shared arrow_static - NAMESPACE cudf::) - - rapids_export(BUILD ArrowCUDA - VERSION ${VERSION} - EXPORT_SET arrow_cuda_targets - GLOBAL_TARGETS arrow_cuda_shared arrow_cuda_static - NAMESPACE cudf::) - endif() - # We generate the arrow-config and arrowcuda-config files - # when we built arrow locally, so always do `find_dependency` - rapids_export_package(BUILD Arrow cudf-exports) - rapids_export_package(INSTALL Arrow cudf-exports) - - # We have to generate the find_dependency(ArrowCUDA) ourselves - # since we need to specify ArrowCUDA_DIR to be where Arrow - # was found, since Arrow packages ArrowCUDA.config in a non-standard - # location - rapids_export_package(BUILD ArrowCUDA cudf-exports) - - include("${rapids-cmake-dir}/export/find_package_root.cmake") - rapids_export_find_package_root(BUILD Arrow [=[${CMAKE_CURRENT_LIST_DIR}]=] cudf-exports) - rapids_export_find_package_root(BUILD ArrowCUDA [=[${CMAKE_CURRENT_LIST_DIR}]=] cudf-exports) - set(ARROW_FOUND TRUE) set(ARROW_LIBRARIES "") @@ -184,6 +156,34 @@ function(find_and_configure_arrow VERSION BUILD_STATIC ENABLE_S3 ENABLE_ORC ENAB message(FATAL_ERROR "CUDF: Arrow library not found or downloaded.") endif() + if(Arrow_ADDED) + rapids_export(BUILD Arrow + VERSION ${VERSION} + EXPORT_SET arrow_targets + GLOBAL_TARGETS arrow_shared arrow_static + NAMESPACE cudf::) + + rapids_export(BUILD ArrowCUDA + VERSION ${VERSION} + EXPORT_SET arrow_cuda_targets + GLOBAL_TARGETS arrow_cuda_shared arrow_cuda_static + NAMESPACE cudf::) + endif() + # We generate the arrow-config and arrowcuda-config files + # when we built arrow locally, so always do `find_dependency` + rapids_export_package(BUILD Arrow cudf-exports) + rapids_export_package(INSTALL Arrow cudf-exports) + + # We have to generate the find_dependency(ArrowCUDA) ourselves + # since we need to specify ArrowCUDA_DIR to be where Arrow + # was found, since Arrow packages ArrowCUDA.config in a non-standard + # location + rapids_export_package(BUILD ArrowCUDA cudf-exports) + + include("${rapids-cmake-dir}/export/find_package_root.cmake") + rapids_export_find_package_root(BUILD Arrow [=[${CMAKE_CURRENT_LIST_DIR}]=] cudf-exports) + rapids_export_find_package_root(BUILD ArrowCUDA [=[${CMAKE_CURRENT_LIST_DIR}]=] cudf-exports) + set(ARROW_FOUND "${ARROW_FOUND}" PARENT_SCOPE) set(ARROW_LIBRARIES "${ARROW_LIBRARIES}" PARENT_SCOPE)