diff -Naur double-conversion-3.3.1-orig/CMakeLists.txt double-conversion-3.3.1/CMakeLists.txt
--- double-conversion-3.3.1-orig/CMakeLists.txt	2025-02-14 13:03:13.000000000 +0300
+++ double-conversion-3.3.1/CMakeLists.txt	2025-05-23 21:15:21.673245400 +0300
@@ -10,6 +10,12 @@
   set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /D_DEBUG /D_ITERATOR_DEBUG_LEVEL=2")
 endif()
 
+if (BUILD_SHARED_LIBS)
+  set (target_suffix "shared")
+else ()
+  set (target_suffix "static")
+endif ()
+
 set(headers
     double-conversion/bignum.h
     double-conversion/bignum-dtoa.h
@@ -121,6 +128,7 @@
     EXPORT "${targets_export_name}"
     NAMESPACE "${namespace}"
     DESTINATION "${config_install_dir}"
+    FILE double-conversion-${target_suffix}-targets.cmake
 )
 
 if (MSVC AND BUILD_SHARED_LIBS)
diff -Naur double-conversion-3.3.1-orig/cmake/Config.cmake.in double-conversion-3.3.1/cmake/Config.cmake.in
--- double-conversion-3.3.1-orig/cmake/Config.cmake.in	2025-02-14 13:03:13.000000000 +0300
+++ double-conversion-3.3.1/cmake/Config.cmake.in	2025-05-23 21:12:16.251588400 +0300
@@ -1,4 +1,59 @@
 @PACKAGE_INIT@
 
-include("${CMAKE_CURRENT_LIST_DIR}/@targets_export_name@.cmake")
+set(@PROJECT_NAME@_known_comps static shared)
+set(@PROJECT_NAME@_comp_static NO)
+set(@PROJECT_NAME@_comp_shared NO)
+foreach (@PROJECT_NAME@_comp IN LISTS ${CMAKE_FIND_PACKAGE_NAME}_FIND_COMPONENTS)
+    if (@PROJECT_NAME@_comp IN_LIST @PROJECT_NAME@_known_comps)
+        set(@PROJECT_NAME@_comp_${@PROJECT_NAME@_comp} YES)
+    else ()
+        set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE
+            "@PROJECT_NAME@ does not recognize component `${@PROJECT_NAME@_comp}`.")
+        set(${CMAKE_FIND_PACKAGE_NAME}_FOUND FALSE)
+        return()
+    endif ()
+endforeach ()
+
+if (@PROJECT_NAME@_comp_static AND @PROJECT_NAME@_comp_shared)
+    set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE
+        "@PROJECT_NAME@ `static` and `shared` components are mutually exclusive.")
+    set(${CMAKE_FIND_PACKAGE_NAME}_FOUND FALSE)
+    return()
+endif ()
+
+set(@PROJECT_NAME@_static_targets "${CMAKE_CURRENT_LIST_DIR}/@PROJECT_NAME@-static-targets.cmake")
+set(@PROJECT_NAME@_shared_targets "${CMAKE_CURRENT_LIST_DIR}/@PROJECT_NAME@-shared-targets.cmake")
+
+macro(prj_load_targets type)
+    if (NOT EXISTS "${@PROJECT_NAME@_${type}_targets}")
+        set(${CMAKE_FIND_PACKAGE_NAME}_NOT_FOUND_MESSAGE
+            "@PROJECT_NAME@ `${type}` libraries were requested but not found.")
+        set(${CMAKE_FIND_PACKAGE_NAME}_FOUND FALSE)
+        return()
+    endif ()
+    include("${@PROJECT_NAME@_${type}_targets}")
+endmacro()
+
+if (@PROJECT_NAME@_comp_static)
+    prj_load_targets(static)
+elseif (@PROJECT_NAME@_comp_shared)
+    prj_load_targets(shared)
+elseif (DEFINED @PROJECT_NAME@_SHARED_LIBS AND @PROJECT_NAME@_SHARED_LIBS)
+    prj_load_targets(shared)
+elseif (DEFINED @PROJECT_NAME@_SHARED_LIBS AND NOT @PROJECT_NAME@_SHARED_LIBS)
+    prj_load_targets(static)
+elseif (BUILD_SHARED_LIBS)
+    if (EXISTS "${@PROJECT_NAME@_shared_targets}")
+        prj_load_targets(shared)
+    else ()
+        prj_load_targets(static)
+    endif ()
+else ()
+    if (EXISTS "${@PROJECT_NAME@_static_targets}")
+        prj_load_targets(static)
+    else ()
+        prj_load_targets(shared)
+    endif ()
+endif ()
+
 check_required_components("@PROJECT_NAME@")
