I had a project where I had to do this in the main.cpp file to get it
to link with static Qt on Windows:
#ifdef _WIN32
#ifdef QT_STATIC
Q_IMPORT_PLUGIN(QWindowsIntegrationPlugin)
#endif
#endif
Those unresolved externals you posted look familiar... Does this fix it?
HTH,
On 2/13/2018 11:28 AM, Stuermer, Michael SP/HZA-ZSEP wrote:
> I try to do a CMake build with static C runtime and a static Qt 5.10.0
Make sure Qt is configured with both `-static` and `-static-runtime`,
and that it is built with the same compiler as CMake. See the command
used below to configure
I try to do a CMake build with static C runtime and a static Qt 5.10.0 build to
avoid runtime errors when giving the binaries to colleagues. The Visual Studio
version is 2017. AFAIK the official CMake builds already use this
"full-static-build" scheme. However I end up with some linking errors