Packaging problem on Linux with Qt 5.15.0

I packaged a Slicer using the latest nightly and Ubuntu 18.04, gcc 7.5.0, and Qt 5.15.0, and when unpacking and executing it, Slicer fails to start due to an error
.../Slicer-4.11.0-2020-08-26-linux-amd64/bin/SlicerApp-real: error while loading shared libraries: cannot open shared object file: No such file or directory

When I manually copy the files* to the package, it works without problems.

There is some uncertainty about using Qt on Linux (see what I posted about it few days ago). Also note that the factory builds still use an older Qt (5.11.2).

So I have two questions:

  1. Does anyone has an idea how to make sure the missing files are included in the package?
  2. Are there plans updating the Linux build to 5.15.0? The build instructions (Qt 5.9.5), the actual version used by the factory (5.11.2), and the long-term Slicer plans (5.15.0) don’t seem to match.

Thank you!

The Linux build was updated to Qt 5.15 for a short period when the other platforms were being updated. However there were those errors as you explained above and there wasn’t any more effort in resolving those. You can read about the issues in

1 Like

An attempt was tried to update the SlicerBlockInstallQt.cmake but then that broke Windows packaging so it was reverted.

1 Like

Thanks @jamesobutler for the summary! Looking at the topics it seems two different problems. I only encountered one of them. I’ll take a look at the packaging issue in case I find a good solution.

@cpinter @jamesobutler Thanks for your help working on this :pray:

The only thing that occurred to me so far is adding QmlModels only for Unix-type OS.

@Sam_Horvath @jcfr Do you guys remember how adding it broke the Windows packaging?

Following this configuration I had no issues, but it is true that then the binaries (, in practise, will work only for other ubuntu 20.04 users.

Addittionally, at the kapteyn they built a working version of SlicerAstroApp on centos 7 ( with Qt5.15.0 (I’ll ask all the building info later on and I’ll report), but then users on pretty old linux flavours got this at startup (as for the packing os information, I’ll write the os information asap):

qt.qpa.plugin: Could not load the Qt platform plugin “xcb” in “” even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: xcb.

@vdhulst if you have the packing os info of centos 7, can you post them? thanks!

the centos binaries in have been compiled and packed with the slicer/buildenv-qt5-centos7:latest in, i.e.:

centos 7.8
cmake 3.17.1
gcc 5.3.1 (Red Hat 5.3.1-6 from devtoolset 4)
qt 5.15.0

and it seems that the qt plugin error in the previos post was because of the missing of the library libxcb-xinerama0 in the old user machine.

Now they are testing the build using the 4.11-2018.10.17 from

It led to the following on Windows:

and on Linux:

1 Like


I did not find a way around this installation problem. I reinstalled Windows and reinstalled Slicer. Since then, everything is running great.



P.S.: @cpinter we tried the following kitware factory machine configuration:

centos 7.6
cmake 3.13.4
5.3.1 (Red Hat 5.3.1-6 from devtoolset 4)
qt 5.11.2

and it produced a version working on all the linux flavours

It would be nice to have the Qt5.15.0 version. However, we didn’t manage to make a fully working Qt5.15.0 version on all the linux flavours and os versions. Although it was working on the majority of them, the recent ones at least, on old linux os you can have issues with libxcb-xinerama0 and also require an hack for packing krb5-libs. The configuration is:

centos 7.8
cmake 3.17.1
gcc 5.3.1 (Red Hat 5.3.1-6 from devtoolset 4)
qt 5.15.0

P.S.2: I confirm that the packing wih, but then the users need relatively “new” os linux versions.

Do you mean that* was successfully added to the package?

I didn’t ckecked. I should have done. But we had no issue in running the app (however, I did’t check either if it was using system libraries for eventual missing ones). I’ll check tomorrow and I’ll let you know.

@cpinter so I checked on the version built with (ubuntu 20.04, gcc9.3, cmake 3.17.3, qt5.15.0). It is true that the libQt5QmlModels libraries are not packed, but from a fast analysis with ldd on SlicerAstroApp-real and few libs in the libs folder, I didn’t see any depedepence from libQt5QmlModels.

Can you point out which one require libQt5QmlModels?

P.S.: SlicerAstroApp is at Slicer commit 1ed419ef83bebe918cefbf78039cfc9d84967571 (14-08-2020)

P.S.2: I am interested to know, since I told to people that the Qt5.15 version in if used on ubuntu 20.04 will work :slight_smile: (and at least on 1 another laptop it worked)

After the recent changes in Slicer CMake, the* files are properly packaged on Linux as well.