diff --git a/docs_src/manuals/introduction/introduction.rst b/docs_src/manuals/introduction/introduction.rst index cf0bd8c3d..c88c66edc 100644 --- a/docs_src/manuals/introduction/introduction.rst +++ b/docs_src/manuals/introduction/introduction.rst @@ -142,10 +142,7 @@ lines to your CMake project URL https://github.com/GridTools/gridtools/archive/.tar.gz ) FetchContent_GetProperties(GridTools) - if(NOT GridTools_POPULATED) - FetchContent_Populate(GridTools) - add_subdirectory(${gridtools_SOURCE_DIR} ${gridtools_BINARY_DIR}) - endif() + FetchContent_MakeAvailable(GridTools) where ** is the git tag of the |GT| release, e.g. ``v2.0.0``. diff --git a/tests/regression/py_bindings/CMakeLists.txt b/tests/regression/py_bindings/CMakeLists.txt index c2187ff2d..6234be7af 100644 --- a/tests/regression/py_bindings/CMakeLists.txt +++ b/tests/regression/py_bindings/CMakeLists.txt @@ -12,12 +12,7 @@ FetchContent_Declare( GIT_TAG v2.10.0 ) -FetchContent_GetProperties(pybind11) -if(NOT pybind11_POPULATED) - FetchContent_Populate(pybind11) - set(PYTHON_EXECUTABLE ${Python_EXECUTABLE}) - add_subdirectory(${pybind11_SOURCE_DIR} ${pybind11_BINARY_DIR}) -endif() +FetchContent_MakeAvailable(pybind11) pybind11_add_module(py_implementation implementation.cpp)