-
Notifications
You must be signed in to change notification settings - Fork 190
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Abstract and consolidate CPM calls. * Update CPM used in example projects.
- Loading branch information
1 parent
bb001b7
commit a0ec74c
Showing
10 changed files
with
2,693 additions
and
1,234 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
set(_cccl_cpm_file "${CMAKE_CURRENT_LIST_DIR}/CPM.cmake") | ||
|
||
macro(cccl_get_boost) | ||
include("${_cccl_cpm_file}") | ||
CPMAddPackage("gh:boostorg/boost#boost-1.83.0") | ||
endmacro() | ||
|
||
macro(cccl_get_catch2) | ||
include("${_cccl_cpm_file}") | ||
CPMAddPackage("gh:catchorg/[email protected]") | ||
endmacro() | ||
|
||
macro(cccl_get_fmt) | ||
include("${_cccl_cpm_file}") | ||
CPMAddPackage("gh:fmtlib/fmt#11.0.1") | ||
endmacro() | ||
|
||
macro(cccl_get_nvbench) | ||
include("${_cccl_cpm_file}") | ||
CPMAddPackage("gh:NVIDIA/nvbench#main") | ||
endmacro() | ||
|
||
macro(cccl_get_nvtx) | ||
include("${_cccl_cpm_file}") | ||
CPMAddPackage( | ||
NAME NVTX | ||
GITHUB_REPOSITORY NVIDIA/NVTX | ||
GIT_TAG release-v3 | ||
DOWNLOAD_ONLY | ||
SYSTEM | ||
) | ||
include("${NVTX_SOURCE_DIR}/c/nvtxImportedTargets.cmake") | ||
endmacro() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
# Fetch nvbench | ||
CPMAddPackage("gh:NVIDIA/nvbench#main") | ||
cccl_get_catch2() | ||
cccl_get_nvbench() | ||
|
||
add_library(nvbench_helper OBJECT nvbench_helper/nvbench_helper.cuh | ||
nvbench_helper/nvbench_helper.cu) | ||
|
@@ -13,13 +13,12 @@ target_link_libraries(nvbench_helper PUBLIC CUB::CUB | |
target_include_directories(nvbench_helper PUBLIC "${CMAKE_CURRENT_LIST_DIR}/nvbench_helper") | ||
set_target_properties(nvbench_helper PROPERTIES CUDA_STANDARD 17 CXX_STANDARD 17) | ||
|
||
CPMAddPackage("gh:catchorg/[email protected]") | ||
|
||
option(CUB_ENABLE_NVBENCH_HELPER_TESTS "Enable tests for nvbench_helper" OFF) | ||
mark_as_advanced(CUB_ENABLE_NVBENCH_HELPER_TESTS) | ||
|
||
if (CUB_ENABLE_NVBENCH_HELPER_TESTS) | ||
CPMAddPackage(NAME Boost VERSION 1.83.0 GITHUB_REPOSITORY "boostorg/boost" GIT_TAG "boost-1.83.0") | ||
cccl_get_boost() | ||
|
||
function(add_nvbench_helper_test device_system) | ||
set(nvbench_helper_test_target nvbench_helper.test.${device_system}) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,17 +18,8 @@ else() | |
) | ||
endif() | ||
|
||
include("${CUB_SOURCE_DIR}/cmake/CPM.cmake") | ||
CPMAddPackage("gh:catchorg/[email protected]") | ||
|
||
CPMAddPackage( | ||
NAME NVTX | ||
GITHUB_REPOSITORY NVIDIA/NVTX | ||
GIT_TAG release-v3 | ||
DOWNLOAD_ONLY | ||
SYSTEM | ||
) | ||
include("${NVTX_SOURCE_DIR}/c/nvtxImportedTargets.cmake") | ||
cccl_get_catch2() | ||
cccl_get_nvtx() | ||
|
||
find_package(CUDAToolkit) | ||
|
||
|
Oops, something went wrong.