c++linuxqtubuntu

Install Qt on Ubuntu


Need to build simple GUI application. For this reason I decided to install Qt on my Ubuntu 16. I have downloaded open source Qt edition from theirs site. Got error while run:

g@ubuntu:~/Downloads$ ./qt-unified-linux-x86-2.0.5-2-online.run 
./qt-unified-linux-x86-2.0.5-2-online.run: error while loading shared libraries: libX11.so.6: cannot open shared object file: No such file or directory

How to fix that?


Solution

  • Before Debian 11 / Ubuntu 20.10, the ubuntu package name was qt5-default.

    This package was deprecated and now you should install qtbase5-dev, or one of the individual Qt modules if you just want the runtime:

    The corresponding Qt6 package is qt6-base-dev (note the extra -).