[Interest] Tweaking a static build of Qt 6 for Windows
Nuno Santos
nuno.santos at imaginando.pt
Thu Jan 26 16:52:38 CET 2023
Hi,
When I used to compile Qt 5 statically for Windows I would usually need to tweak a couple of settings under:
qtbase/mkspecs/common/msvc_desktop.conf
QMAKE_CFLAGS_RELEASE = -O2 -MT -Zc:strictStrings
QMAKE_CFLAGS_RELEASE_WITH_DEBUGINFO += -O2 -MT -Zi -Zc:strictStrings
QMAKE_CFLAGS_DEBUG = -Zi -MTd
QMAKE_LIBS_CORE = kernel32.lib user32.lib shell32.lib uuid.lib ole32.lib advapi32.lib ws2_32.lib gdi32.lib
Since I build plugins that can be opened multiple times, we need to change -MD to -MT. I would also need to link a couple extra libs. Don’t know why.
When building Qt 6, is this the same place for this type of settings or the fact that the build is managed by cmake this files are ignored and others are used. If so, which ones?
Thanks!
Regards,
Nuno
More information about the Interest
mailing list