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

Update and clarify dependencies #737

Merged
merged 2 commits into from
Jan 4, 2025
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
18 changes: 12 additions & 6 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ endif()

if("${DDC_BUILD_PDI_WRAPPER}")
if(NOT TARGET PDI::PDI_C)
find_package(PDI REQUIRED COMPONENTS C)
find_package(PDI 1.6...<2 REQUIRED COMPONENTS C)
endif()
endif()

Expand All @@ -79,15 +79,17 @@ if("${BUILD_TESTING}" AND "${DDC_BUILD_TESTS}")

if("${DDC_GTest_DEPENDENCY_POLICY}" STREQUAL "AUTO")
if(NOT TARGET GTest::GTest AND NOT TARGET GTest::gtest)
find_package(GTest QUIET)
# 1.14...<2 but GTest module does not support range version
find_package(GTest 1.14 QUIET)
if(NOT GTest_FOUND)
ddc_configure_googletest()
endif()
endif()
elseif("${DDC_GTest_DEPENDENCY_POLICY}" STREQUAL "EMBEDDED")
ddc_configure_googletest()
elseif("${DDC_GTest_DEPENDENCY_POLICY}" STREQUAL "INSTALLED")
find_package(GTest REQUIRED)
# 1.14...<2 but GTest module does not support range version
find_package(GTest 1.14 REQUIRED)
endif()
endif()

Expand All @@ -103,22 +105,22 @@ if("${DDC_BUILD_BENCHMARKS}")

if("${DDC_benchmark_DEPENDENCY_POLICY}" STREQUAL "AUTO")
if(NOT TARGET benchmark::benchmark)
find_package(benchmark QUIET)
find_package(benchmark 1.8...<2 QUIET)
if(NOT benchmark_FOUND)
ddc_configure_benchmark()
endif()
endif()
elseif("${DDC_benchmark_DEPENDENCY_POLICY}" STREQUAL "EMBEDDED")
ddc_configure_benchmark()
elseif("${DDC_benchmark_DEPENDENCY_POLICY}" STREQUAL "INSTALLED")
find_package(benchmark REQUIRED)
find_package(benchmark 1.8...<2 REQUIRED)
endif()
endif()

## Doxygen

if("${DDC_BUILD_DOCUMENTATION}")
find_package(Doxygen 1.8.13 REQUIRED OPTIONAL_COMPONENTS dot)
find_package(Doxygen 1.8.13...<2 REQUIRED OPTIONAL_COMPONENTS dot)
endif()

# Our project
Expand Down Expand Up @@ -203,6 +205,8 @@ if("${DDC_BUILD_KERNELS_SPLINES}")
)
if("${DDC_KokkosKernels_DEPENDENCY_POLICY}" STREQUAL "AUTO")
if(NOT TARGET Kokkos::kokkoskernels)
# fork https://github.com/yasahi-hpc/kokkos-kernels
# on branch develop-spline-kernels-v2
find_package(KokkosKernels QUIET)
if(NOT KokkosKernels_FOUND)
ddc_configure_kokkos_kernels()
Expand All @@ -211,6 +215,8 @@ if("${DDC_BUILD_KERNELS_SPLINES}")
elseif("${DDC_KokkosKernels_DEPENDENCY_POLICY}" STREQUAL "EMBEDDED")
ddc_configure_kokkos_kernels()
elseif("${DDC_KokkosKernels_DEPENDENCY_POLICY}" STREQUAL "INSTALLED")
# fork https://github.com/yasahi-hpc/kokkos-kernels
# on branch develop-spline-kernels-v2
find_package(KokkosKernels REQUIRED)
endif()

Expand Down
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,28 @@ If you like the project, please leave us a github star.

If you want to know more, join un on [Slack](https://join.slack.com/t/ddc-lib/shared_invite/zt-14b6rjcrn-AwSfM6_arEamAKk_VgQPhg)

## Prerequisites

To use DDC core, one needs the following dependencies:

* a C++17-compliant compiler
* CMake 3.22...<4
* Kokkos 4.4...4.5
* (optional, micro benchmarking) Benchmark 1.8...<2
* (optional, documentation) Doxygen 1.8.13...<2
* (optional, unit-testing) GoogleTest 1.14...<2

To use DDC components, one needs the following dependencies:

* (optional, fft interface) DDC::fft
* Kokkos-fft 0.2.1...<1
* (optional, IO interface) DDC::pdi
* PDI 1.6...<2
* (optional, spline interpolation) DDC::splines
* Ginkgo 1.8.0
* Kokkos Kernels fork <https://github.com/yasahi-hpc/kokkos-kernels> on branch develop-spline-kernels-v2


## Getting the code and basic configuration

```bash
Expand Down
4 changes: 3 additions & 1 deletion cmake/DDCConfig.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,13 @@ if(@DDC_BUILD_KERNELS_SPLINES@)
list(PREPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR})
ddc_find_dependency(LAPACKE)
list(POP_FRONT CMAKE_MODULE_PATH)
# fork https://github.com/yasahi-hpc/kokkos-kernels
# on branch develop-spline-kernels-v2
ddc_find_dependency(KokkosKernels)
endif()

if(@DDC_BUILD_PDI_WRAPPER@)
ddc_find_dependency(PDI COMPONENTS C)
ddc_find_dependency(PDI 1.6...<2 COMPONENTS C)
endif()

include(${CMAKE_CURRENT_LIST_DIR}/DDCTargets.cmake)
Expand Down
2 changes: 1 addition & 1 deletion vendor/benchmark
Submodule benchmark updated 157 files
2 changes: 1 addition & 1 deletion vendor/googletest
Submodule googletest updated 170 files
Loading