Le Ngoc Thuong
Le Ngoc Thuong

Reputation: 309

Trying to build Qt 6.3.1 and dynamic linked with OpenSSL 3.0.5 on Windows

I am trying to build Qt 6.3.1 and dynamically linked with OpenSSL 3x on Windows. In the past, I can build Qt 6.1.3 with OpenSSL 3x and there is no problem at all. But with Qt 6.3.1 I think the default option for SSL functions is built with schannel Please ref this link: https://bugreports.qt.io/browse/QTBUG-82876

I've try to disable this option (schannel) in the file: qtbase/cmake/configure-cmake-mapping.md:

enter image description here

And here are my config options (add -no-schannel which I've added as above):

configure.bat -D FD_SETSIZE=4096 -release -prefix %DESTINATIONDIR% -shared -platform win32-msvc -opensource -confirm-license -openssl-linked -no-schannel -sql-psql -sql-sqlite -qt-zlib -qt-pcre --system-proxies -no-gui -no-widgets -no-gif -no-libpng -no-libjpeg -no-freetype -no-harfbuzz -no-accessibility -no-icu -no-fontconfig -no-opengl -no-egl -no-evdev -no-mtdev -no-sql-odbc -nomake tools -nomake examples -nomake tests -- -D OPENSSL_ROOT_DIR=%DEPENDENCIES_DIR%\openssl

And in the summary options, it also logs that schannel is disabled:

enter image description here

But when I check the module Qt6Network.dll it is not linked to OpenSSL libs

enter image description here

My expected is: the dependencies of Qt6Network.dll is linked to OpenSSL libs

enter image description here

So my questions are:

  1. How can I turn off schannel in the correct way?
  2. How can I make Qt6Network dynamically linked to OpenSSL libs?

Appreciate any help here, thank you!

Upvotes: 2

Views: 1843

Answers (1)

Le Ngoc Thuong
Le Ngoc Thuong

Reputation: 309

I've found that with Qt 6.2 and above, SSL function lib is not directly linked with the Qt6Network module anymore, it links through the plugin called tls

enter image description here enter image description here

I just need to pack this plugin along with Qt6Network and all set!

Upvotes: 1

Related Questions