summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--cmake/QtSetup.cmake10
1 files changed, 9 insertions, 1 deletions
diff --git a/cmake/QtSetup.cmake b/cmake/QtSetup.cmake
index ee88ac8852..28b0ad62c4 100644
--- a/cmake/QtSetup.cmake
+++ b/cmake/QtSetup.cmake
@@ -34,7 +34,15 @@ endif()
# Appends a 'debug postfix' to library targets (not executables)
# e.g. lib/libQt6DBus_debug.5.12.0.dylib
if(WIN32)
- set(CMAKE_DEBUG_POSTFIX "d")
+ if(MINGW)
+ # On MinGW we don't have "d" suffix for debug libraries like on Linux,
+ # unless we're building debug and release libraries in one go.
+ if(FEATURE_debug_and_release)
+ set(CMAKE_DEBUG_POSTFIX "d")
+ endif()
+ else()
+ set(CMAKE_DEBUG_POSTFIX "d")
+ endif()
elseif(APPLE)
set(CMAKE_DEBUG_POSTFIX "_debug")
set(CMAKE_FRAMEWORK_MULTI_CONFIG_POSTFIX_DEBUG "_debug")