Qt Path - Configuration for Building Slicer

Hi there!

I would like to build Slicer on Ubuntu 19.10. I installed Qt5 via:
$ sudo apt install qt5-default

Now I am struggling with the following command (see Documentation):
cmake -DCMAKE_BUILD_TYPE:STRING=Debug -DQt5_DIR:PATH=/path/to/Qt5.11.0/5.11.0/gcc_64/lib/cmake/Qt5 …/Slicer

Documentation:
https://www.slicer.org/wiki/Documentation/Nightly/Developers/Build_Instructions#Common_Prerequisites

How should I replace /path/to/QtSDK ?? I just can’t find such a path.

Thanks for helping!

  • marie

I just solved it myself. Thank you anyway!

It seems that the build instructions were not clear enough. Could you tell us how to change them to make them easier to follow?

Of course. In the documentation it says:

Qt 5.11: tested and recommended

  • To build Slicer: install Qt using the distribution package manager.
  • To package and redistribute Slicer: download and execute qt-unified-linux-x64-online.run, install Qt, make sure to select qtscript and qtwebengine components.

I thought only the first option was suitable for building 3DSlicer. It turned out, that the second solution works fine! After execution and installing version 5.11.0 (not 5.12), everything worked as expected. Versions older than 5.12 are available on the left (see archive tab in the installation window). I didn’t choose all components but qtscript and qtwebengine as recommended. Some options can occupy much space!

I don’t know whether it works with apt installation though.