function(find_and_configure_spdlog)

    include(${rapids-cmake-dir}/cpm/spdlog.cmake)
    rapids_cpm_spdlog(FMT_OPTION "EXTERNAL_FMT_HO" INSTALL_EXPORT_SET rmm-exports)
    rapids_export_package(BUILD spdlog rmm-exports)

    if(spdlog_ADDED)
        rapids_export(
                BUILD spdlog
                EXPORT_SET spdlog
                GLOBAL_TARGETS spdlog spdlog_header_only
                NAMESPACE spdlog::)
        include("${rapids-cmake-dir}/export/find_package_root.cmake")
        rapids_export_find_package_root(BUILD spdlog [=[${CMAKE_CURRENT_LIST_DIR}]=] EXPORT_SET rmm-exports)
    endif()
endfunction()

find_and_configure_spdlog()