Skip to content

Commit

Permalink
Update cuspatial version for calver, fix CMake FindPackage cudf (#401)
Browse files Browse the repository at this point in the history
* Update cuspatial version for calver
* Fix CMake `FindPackage(cudf)`

Authors:
  - Paul Taylor (https://github.com/trxcllnt)

Approvers:
  - Keith Kraus (https://github.com/kkraus14)
  - Ray Douglass (https://github.com/raydouglass)

URL: #401
  • Loading branch information
trxcllnt authored May 18, 2021
1 parent 63a6706 commit e0ee443
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 8 deletions.
2 changes: 1 addition & 1 deletion conda/environments/cuspatial_dev_cuda11.0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ channels:
dependencies:
- clang=8.0.1
- clang-tools=8.0.1
- cudf=0.20.*
- cudf=21.06.*
- cudatoolkit=11.0
- gdal>=3.0.2
- geopandas=0.7.0
Expand Down
4 changes: 2 additions & 2 deletions conda/environments/cuspatial_dev_cuda11.1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ channels:
dependencies:
- clang=8.0.1
- clang-tools=8.0.1
- cudf=0.20.*
- cudf=21.06.*
- cudatoolkit=11.1
- gdal>=3.0.2
- geopandas=0.7.0
- cmake>=3.14
- cmake>=3.18
- cython>=0.29,<0.30
- gtest
- gmock
4 changes: 2 additions & 2 deletions conda/environments/cuspatial_dev_cuda11.2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ channels:
dependencies:
- clang=8.0.1
- clang-tools=8.0.1
- cudf=0.20.*
- cudf=21.06.*
- cudatoolkit=11.2
- gdal>=3.0.2
- geopandas=0.7.0
- cmake>=3.14
- cmake>=3.18
- cython>=0.29,<0.30
- gtest
- gmock
2 changes: 1 addition & 1 deletion cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ elseif(CMAKE_CUDA_ARCHITECTURES STREQUAL "")
set(CUSPATIAL_BUILD_FOR_DETECTED_ARCHS TRUE)
endif()

project(CUSPATIAL VERSION 0.20.0 LANGUAGES C CXX)
project(CUSPATIAL VERSION 21.06.00 LANGUAGES C CXX)

# Needed because GoogleBenchmark changes the state of FindThreads.cmake,
# causing subsequent runs to have different values for the `Threads::Threads` target.
Expand Down
10 changes: 8 additions & 2 deletions cpp/cmake/thirdparty/CUSPATIAL_GetCUDF.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,16 @@ function(find_and_configure_cudf VERSION)
return()
endif()

if(${VERSION} MATCHES [=[([0-9]+)\.([0-9]+)\.([0-9]+)]=])
set(MAJOR_AND_MINOR "${CMAKE_MATCH_1}.${CMAKE_MATCH_2}")
else()
set(MAJOR_AND_MINOR "${VERSION}")
endif()

CPMFindPackage(NAME cudf
VERSION ${VERSION}
GIT_REPOSITORY https://github.com/rapidsai/cudf.git
GIT_TAG branch-${VERSION}
GIT_TAG branch-${MAJOR_AND_MINOR}
GIT_SHALLOW TRUE
SOURCE_SUBDIR cpp
OPTIONS "BUILD_TESTS OFF"
Expand All @@ -36,6 +42,6 @@ function(find_and_configure_cudf VERSION)
fix_cmake_global_defaults(cudf::cudftestutil)
endfunction()

set(CUSPATIAL_MIN_VERSION_cudf "${CUSPATIAL_VERSION_MAJOR}.${CUSPATIAL_VERSION_MINOR}")
set(CUSPATIAL_MIN_VERSION_cudf "${CUSPATIAL_VERSION_MAJOR}.${CUSPATIAL_VERSION_MINOR}.00")

find_and_configure_cudf(${CUSPATIAL_MIN_VERSION_cudf})

0 comments on commit e0ee443

Please sign in to comment.