进入到安装目录下的/home/zhe/Qt/Tools/QtCreator/lib/Qt/plugins/platforms路径
./qtcreator 出现
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: eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, xcb.
修改bash.bashrc 在末尾一行添加
export QT_DEBUG_PLUGINS=1
然后source bash.bashrc
再次进入到安装目录下./qtcreator
出现
Got keys from plugin meta data (“xcb”)
QFactoryLoader::QFactoryLoader() checking directory path “/home/zhe/Qt/Tools/QtCreator/bin/platforms” …
Cannot load library /home/zhe/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so: (libxcb-util.so.1: 无法打开共享对象文件: 没有那个文件或目录)
QLibraryPrivate::loadPlugin failed on “/home/zhe/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so” : “Cannot load library /home/zhe/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so: (libxcb-util.so.1: 无法打开共享对象文件: 没有那个文件或目录)”
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.
进入/home/zhe/Qt/Tools/QtCreator/lib/Qt/plugins/platforms目录:
输入ldd libqxcb.so
找到libqxcb.so需要依赖哪些插件,发现libxcb-util.so.1 => not found
缺少libxcb-util.so.1库,
需要安装 libxcb-util1 库,但是 apt install 找不到那个库,所以干脆就把deb包给下下来安装:http://ftp.br.debian.org/debian/pool/main/x/xcb-util/libxcb-util1_0.4.0-1+b1_amd64.deb
下载下来后,安装这个deb包。sudo dpkg -i ./libxcb-util1_0.4.0-1+b1_amd64.deb
再次进入/home/zhe/Qt/Tools/QtCreator/lib/Qt/plugins/platforms 输入ldd libqxcb.so
显示已安装
点击桌面的图标可以打开了