I solved this problem.
A Ilittle bit rube, but works.
Here are the patches if anybody needs them. :-)
--- qttools/src/assistant/CMakeLists.txt 2023-09-24 09:45:36.000000000 +0100
+++ qttools/src/assistant/CMakeLists.txt 2024-08-13 18:50:42.744407900 +0100
@@ -17,21 +17,22 @@
return()
endif()
add_subdirectory(help)
add_subdirectory(assistant)
add_subdirectory(qhelpgenerator)
set(QLITEHTML_BIN_PATH ${INSTALL_BINDIR})
set(QLITEHTML_LIBRARY_PATH ${INSTALL_LIBDIR})
set(QLITEHTML_LIBRARY_TYPE STATIC)
set(BUILD_SHARED_LIBS OFF)
-if(QT_FEATURE_static_runtime AND MSVC)
+#if(QT_FEATURE_static_runtime AND MSVC)
+if(MSVC)
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")
endif()
add_subdirectory(qlitehtml/src EXCLUDE_FROM_ALL)
if(TARGET qlitehtml)
qt_autogen_tools_initial_setup(qlitehtml)
# The litehtml and gumbo targets will not be available here if they are not built by Qt
# but found in the system, because they are imported only to the subdirectory scope
# where find_package was called. But that's fine, we wouldn't be able to set compiler flags
# on them anyway.
if(TARGET litehtml)
--- qtmultimedia/src/3rdparty/resonance-audio/CMakeLists.txt 2023-09-24 11:12:48.000000000 +0100
+++ qtmultimedia/src/3rdparty/resonance-audio/CMakeLists.txt 2024-08-13 19:08:11.046330800 +0100
@@ -11,25 +11,25 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
# Static/dynamic runtime can be selected via -DSTATIC_MSVC_RUNTIME=ON|OFF
macro(configure_msvc_runtime)
if (NOT BUILD_WWISE_AUTHORING_PLUGIN)
option(STATIC_MSVC_RUNTIME "Static linkage of MSVC runtime" ON)
SET(MSVC_RUNTIME_FLAG "/MT" CACHE STRING "MSVC Runtime flag")
- if (STATIC_MSVC_RUNTIME)
+ #if (STATIC_MSVC_RUNTIME)
SET(MSVC_RUNTIME_FLAG "/MT")
- else ()
- SET(MSVC_RUNTIME_FLAG "/MD")
- endif ()
+ #else ()
+ # SET(MSVC_RUNTIME_FLAG "/MD")
+ #endif ()
message(STATUS "MSVC Runtime flag: ${MSVC_RUNTIME_FLAG}")
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} ${MSVC_RUNTIME_FLAG}" CACHE INTERNAL "" FORCE)
set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} ${MSVC_RUNTIME_FLAG}d" CACHE INTERNAL "" FORCE)
set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} ${MSVC_RUNTIME_FLAG}" CACHE INTERNAL "" FORCE)
set(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} ${MSVC_RUNTIME_FLAG}d" CACHE INTERNAL "" FORCE)
endif (NOT BUILD_WWISE_AUTHORING_PLUGIN)
endmacro()
macro(use_cxx11)
set(CMAKE_CXX_STANDARD 11)
--- qtbase/cmake/QtPublicTargetHelpers.cmake 2023-09-21 19:24:26.000000000 +0100
+++ qtbase/cmake/QtPublicTargetHelpers.cmake 2024-08-13 18:39:43.681027000 +0100
@@ -312,12 +312,17 @@
set(link_option PRIVATE)
else()
set(link_option INTERFACE)
endif()
if(CLANG)
target_link_options(${target} ${link_option} "LINKER:-Bstatic")
else()
target_link_options(${target} ${link_option} "-static")
endif()
endif()
+ else()
+ if(MSVC)
+ set_property(TARGET ${target} PROPERTY
+ MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>")
+ endif()
endif()
endfunction()