diff --git a/dependencies.yaml b/dependencies.yaml index 730bed3e..4e4ea714 100644 --- a/dependencies.yaml +++ b/dependencies.yaml @@ -169,7 +169,7 @@ dependencies: - zlib - output_types: [conda] packages: - - fmt==9.1.0 + - fmt==10.2.1 py_version: specific: - output_types: conda diff --git a/rapids-cmake/cpm/patches/fmt/fix_10_1_1_version.diff b/rapids-cmake/cpm/patches/fmt/fix_10_1_1_version.diff deleted file mode 100644 index 8a66afd4..00000000 --- a/rapids-cmake/cpm/patches/fmt/fix_10_1_1_version.diff +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/include/fmt/core.h b/include/fmt/core.h -index 1fe13888..f9e3b7d6 100644 ---- a/include/fmt/core.h -+++ b/include/fmt/core.h -@@ -18,7 +18,7 @@ - #include - - // The fmt library version in the form major * 10000 + minor * 100 + patch. --#define FMT_VERSION 100100 -+#define FMT_VERSION 100101 - - #if defined(__clang__) && !defined(__ibmxl__) - # define FMT_CLANG_VERSION (__clang_major__ * 100 + __clang_minor__) diff --git a/rapids-cmake/cpm/patches/spdlog/nvcc_constexpr_fix.diff b/rapids-cmake/cpm/patches/spdlog/nvcc_constexpr_fix.diff deleted file mode 100644 index 5bc2915f..00000000 --- a/rapids-cmake/cpm/patches/spdlog/nvcc_constexpr_fix.diff +++ /dev/null @@ -1,41 +0,0 @@ -diff --git a/include/spdlog/common.h b/include/spdlog/common.h -index 0a262eb2..29ef2324 100644 ---- a/include/spdlog/common.h -+++ b/include/spdlog/common.h -@@ -62,17 +62,26 @@ - - // visual studio up to 2013 does not support noexcept nor constexpr - #if defined(_MSC_VER) && (_MSC_VER < 1900) --# define SPDLOG_NOEXCEPT _NOEXCEPT --# define SPDLOG_CONSTEXPR --# define SPDLOG_CONSTEXPR_FUNC inline -+ #define SPDLOG_NOEXCEPT _NOEXCEPT -+ #define SPDLOG_CONSTEXPR - #else --# define SPDLOG_NOEXCEPT noexcept --# define SPDLOG_CONSTEXPR constexpr --# if __cplusplus >= 201402L --# define SPDLOG_CONSTEXPR_FUNC constexpr --# else --# define SPDLOG_CONSTEXPR_FUNC inline --# endif -+ #define SPDLOG_NOEXCEPT noexcept -+ #define SPDLOG_CONSTEXPR constexpr -+#endif -+ -+// If building with std::format, can just use constexpr, otherwise if building with fmt -+// SPDLOG_CONSTEXPR_FUNC needs to be set the same as FMT_CONSTEXPR to avoid situations where -+// a constexpr function in spdlog could end up calling a non-constexpr function in fmt -+// depending on the compiler -+// If fmt determines it can't use constexpr, we should inline the function instead -+#ifdef SPDLOG_USE_STD_FORMAT -+ #define SPDLOG_CONSTEXPR_FUNC constexpr -+#else // Being built with fmt -+ #if FMT_USE_CONSTEXPR -+ #define SPDLOG_CONSTEXPR_FUNC FMT_CONSTEXPR -+ #else -+ #define SPDLOG_CONSTEXPR_FUNC inline -+ #endif - #endif - - #if defined(__GNUC__) || defined(__clang__) diff --git a/rapids-cmake/cpm/versions.json b/rapids-cmake/cpm/versions.json index ce0382e2..ebeb51e1 100644 --- a/rapids-cmake/cpm/versions.json +++ b/rapids-cmake/cpm/versions.json @@ -39,16 +39,9 @@ "git_tag": "56c53beb6fb0cafd265b7fcc3df78ae487811b22" }, "fmt": { - "version": "10.1.1", + "version": "10.2.1", "git_url": "https://github.com/fmtlib/fmt.git", - "git_tag": "${version}", - "patches": [ - { - "file": "fmt/fix_10_1_1_version.diff", - "issue": "fmt 10.1.1 produces a CMake package with version 10.1.0", - "fixed_in": "10.2.0" - } - ] + "git_tag": "${version}" }, "GTest": { "version": "1.13.0", @@ -99,20 +92,13 @@ }, "rmm": { "version": "${rapids-cmake-version}", - "git_url": "https://github.com/rapidsai/rmm.git", - "git_tag": "branch-${version}" + "git_url": "https://github.com/jameslamb/rmm.git", + "git_tag": "update-fmt-and-spdlog" }, "spdlog": { - "version": "1.12.0", + "version": "1.13.0", "git_url": "https://github.com/gabime/spdlog.git", - "git_tag": "v${version}", - "patches": [ - { - "file": "spdlog/nvcc_constexpr_fix.diff", - "issue": "Fix constexpr mismatch between spdlog and fmt [https://github.com/gabime/spdlog/issues/2856]", - "fixed_in": "1.13" - } - ] + "git_tag": "v${version}" }, "Thrust": { "version": "1.17.2", diff --git a/testing/cpm/cpm_generate_pins-nested/CMakeLists.txt b/testing/cpm/cpm_generate_pins-nested/CMakeLists.txt index 5151d285..6320281e 100644 --- a/testing/cpm/cpm_generate_pins-nested/CMakeLists.txt +++ b/testing/cpm/cpm_generate_pins-nested/CMakeLists.txt @@ -24,8 +24,15 @@ add_subdirectory(b) include(${rapids-cmake-dir}/cpm/init.cmake) rapids_cpm_init(GENERATE_PINNED_VERSIONS) +# only check projects that were downloaded by CPM (ignore those already in the build environment) +# # don't check cuco here as it uses hashes and that breaks our verify script -set(projects-to-verify rmm fmt spdlog CCCL) +foreach(proj IN ITEMS rmm fmt spdlog CCCL) + if(${proj}_SOURCE_DIR) + list(APPEND projects-to-verify ${proj}) + endif() +endforeach() + add_custom_target(verify_generated_pins ALL COMMAND ${CMAKE_COMMAND} -S="${CMAKE_SOURCE_DIR}/verify/" -B"${CMAKE_BINARY_DIR}/verify_build" -D"rapids-cmake-dir=${rapids-cmake-dir}" diff --git a/testing/cpm/cpm_generate_pins-nested/verify/CMakeLists.txt b/testing/cpm/cpm_generate_pins-nested/verify/CMakeLists.txt index 918846b0..aea5c4b7 100644 --- a/testing/cpm/cpm_generate_pins-nested/verify/CMakeLists.txt +++ b/testing/cpm/cpm_generate_pins-nested/verify/CMakeLists.txt @@ -32,22 +32,29 @@ foreach(proj IN LISTS projects-to-verify) rapids_cpm_package_details(${proj} ${proj}_version ${proj}_repository ${proj}_tag ${proj}_shallow ${proj}_exclude) endforeach() - -file(READ "${CMAKE_CURRENT_BINARY_DIR}/../rapids-cmake/pinned_versions.json" json_data) - # Verify that the pinned_versions is valid json by using it rapids_cpm_package_override("${CMAKE_CURRENT_BINARY_DIR}/../rapids-cmake/pinned_versions.json") +# helper macro for gathering versions.json and pinned_versions.json content to be printed in error messages +macro(_get_json_data) + include("${rapids-cmake-dir}/cpm/detail/get_default_json.cmake") + include("${rapids-cmake-dir}/cpm/detail/get_override_json.cmake") + get_default_json(${proj} default_versions) + get_override_json(${proj} pinned_versions) +endmacro() + foreach(proj IN LISTS projects-to-verify) # Verify that each git_tag is now different. rapids_cpm_package_details(${proj} ${proj}_version ${proj}_repository pin_${proj}_tag pin_${proj}_shallow ${proj}_exclude) if(pin_${proj}_tag STREQUAL ${proj}_tag) - message(FATAL_ERROR "pinned ${proj} tag (${pin_${proj}_tag}) should differ compared to baseline ${${proj}_tag}") + _get_json_data() + message(FATAL_ERROR "pinned ${proj} tag (${pin_${proj}_tag}) should differ compared to baseline ${${proj}_tag}\npinned_versions.json:\n${pinned_versions}\nversions.json:\n${default_versions}") endif() # Everything should have shallow marked as false # so that clones by SHA1 work if(pin_${proj}_shallow) - message(FATAL_ERROR "pin_${proj}_shallow is expected to be false, but got ${pin_${proj}_shallow}") + _get_json_data() + message(FATAL_ERROR "pin_${proj}_shallow is expected to be false, but got ${pin_${proj}_shallow}\npinned_versions.json:\n${pinned_versions}\nversions.json:\n${default_versions}") endif() endforeach() diff --git a/testing/cpm/cpm_generate_pins-simple/CMakeLists.txt b/testing/cpm/cpm_generate_pins-simple/CMakeLists.txt index 6be74385..72c98cd9 100644 --- a/testing/cpm/cpm_generate_pins-simple/CMakeLists.txt +++ b/testing/cpm/cpm_generate_pins-simple/CMakeLists.txt @@ -22,7 +22,14 @@ include(${rapids-cmake-dir}/cpm/rmm.cmake) rapids_cpm_init(GENERATE_PINNED_VERSIONS) rapids_cpm_rmm() -set(projects-to-verify rmm fmt spdlog CCCL) + +# only check projects that were downloaded by CPM (ignore those already in the build environment) +foreach(proj IN ITEMS rmm fmt spdlog CCCL) + if(${proj}_SOURCE_DIR) + list(APPEND projects-to-verify ${proj}) + endif() +endforeach() + add_custom_target(verify_generated_pins ALL COMMAND ${CMAKE_COMMAND} -S="${CMAKE_SOURCE_DIR}/verify/" -B"${CMAKE_BINARY_DIR}/verify_build" -D"rapids-cmake-dir=${rapids-cmake-dir}" diff --git a/testing/cpm/cpm_generate_pins-simple/verify/CMakeLists.txt b/testing/cpm/cpm_generate_pins-simple/verify/CMakeLists.txt index 736662b7..aea5c4b7 100644 --- a/testing/cpm/cpm_generate_pins-simple/verify/CMakeLists.txt +++ b/testing/cpm/cpm_generate_pins-simple/verify/CMakeLists.txt @@ -35,16 +35,26 @@ endforeach() # Verify that the pinned_versions is valid json by using it rapids_cpm_package_override("${CMAKE_CURRENT_BINARY_DIR}/../rapids-cmake/pinned_versions.json") +# helper macro for gathering versions.json and pinned_versions.json content to be printed in error messages +macro(_get_json_data) + include("${rapids-cmake-dir}/cpm/detail/get_default_json.cmake") + include("${rapids-cmake-dir}/cpm/detail/get_override_json.cmake") + get_default_json(${proj} default_versions) + get_override_json(${proj} pinned_versions) +endmacro() + foreach(proj IN LISTS projects-to-verify) # Verify that each git_tag is now different. rapids_cpm_package_details(${proj} ${proj}_version ${proj}_repository pin_${proj}_tag pin_${proj}_shallow ${proj}_exclude) if(pin_${proj}_tag STREQUAL ${proj}_tag) - message(FATAL_ERROR "pinned ${proj} tag (${pin_${proj}_tag}) should differ compared to baseline ${${proj}_tag}") + _get_json_data() + message(FATAL_ERROR "pinned ${proj} tag (${pin_${proj}_tag}) should differ compared to baseline ${${proj}_tag}\npinned_versions.json:\n${pinned_versions}\nversions.json:\n${default_versions}") endif() # Everything should have shallow marked as false # so that clones by SHA1 work if(pin_${proj}_shallow) - message(FATAL_ERROR "pin_${proj}_shallow is expected to be false, but got ${pin_${proj}_shallow}") + _get_json_data() + message(FATAL_ERROR "pin_${proj}_shallow is expected to be false, but got ${pin_${proj}_shallow}\npinned_versions.json:\n${pinned_versions}\nversions.json:\n${default_versions}") endif() endforeach()