Build Slicer 4.10 with Qt5 and VTK 8 on WIndows 10 using VS2015

It seems the instruction page and the qt easy build need an update. I could not find a working-script to build Qt5 with ssl support. Does anyone build Slicer with the above configuration successfully?

There isn’t a qt-easy-build script for Qt5w/openssl on Windows. I issued a PR https://github.com/jcfr/qt-easy-build/pull/45 awhile back that attempted to add the support. Though I’ve been building Slicer on Windows by using the regular pre-built Qt5 binaries downloaded from the web. You can see https://www.slicer.org/wiki/Documentation/Nightly/Developers/Build_Instructions/Prerequisites/Qt5 for instructions related to that.

1 Like

Thanks for your quick reply. I will try this.

Where did you find instructions that told you need Qt5 with OpenSSL for building nightly versions?

The instructions that I’ve found state that you need to use reqular Qt installer:

Qt5 recommended and officially supported . Download qt-unified-windows-x86-online.exe and install Qt along with qtscript and qtwebengine components. For building with VS2015, Qt version 5.10.x or older is required. For more details, read step-by-step guide.

Where did you find instructions that told you need Qt5 with OpenSSL for building nightly versions?

I thought it is the same as qt4. I thought the page is not updated because of the part after this line

 svn co http://svn.slicer.org/Slicer4/<MARKER> Slicer-r<SVNREVISION> -r <SVNREVISION>

It does not include 4.10

The default configuration in CMakeLists.txt specifies enable PythonQt with openssl. Maybe this should be set to “Off” if it isn’t truly the preferred configuration, otherwise you’ll end up with those QSslSocket error messages when starting Slicer. Or maybe update qt-easy-build to work for other platforms. Looks like right now it only passes on Mac for Qt 5.10.0.

Just to let you know your contribution wasn’t forgotten and will be integrated. The time being, building against he official Qt installer should work.

otherwise you’ll end up with those QSslSocket error messages when starting Slicer

Out of curiosity, is this already tracked by a Slicer issue ?

No problem about the PR. It hasn’t been a top priority.

I actually forget to uncheck the PythonQt with openssl cmake entry when using the regular Qt5 downloaded from the official installer. I get the following errors when starting Slicer:

qt.network.ssl: QSslSocket: cannot resolve SSL_set_alpn_protos
qt.network.ssl: QSslSocket: cannot resolve SSL_CTX_set_alpn_select_cb
qt.network.ssl: QSslSocket: cannot resolve SSL_get0_alpn_selected

I figured this was similar to one of the “Common Errors” in the Slicer build instructions. See here. I don’t see any issue for that in the issue tracker, but I wouldn’t really call it a bug since it’s just an error with how I configured the build.

The build works. Thanks everyone!