我试图在一个新的Debian上安装Qt开发环境,但没有成功。首先,由于xserver崩溃,自动在线安装程序甚至没有设法使我达到可用状态。我不得不手动将buster-backports添加到我的sources.list中(这可能会在以后变得相关)
之后的第一件事是从Qt网站下载并启动netinstaller。(qt-统一-linux-x64-4.0.1-1-online.run)
Qt设计器、翻译器和其他应用程序正常启动,但Qt创建者没有启动。
当从控制台启动它时,我会得到以下错误:
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.
Aborted使用详细的选项(导出QT_DEBUG_PLUGINS=1),我得到
Got keys from plugin meta data ("xcb")
QFactoryLoader::QFactoryLoader() checking directory path "/opt/Qt/Tools/QtCreator/bin/platforms" ...
Cannot load library /opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so: (libxcb-util.so.1: cannot open shared object file: No such file or directory)
QLibraryPrivate::loadPlugin failed on "/opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so" : "Cannot load library /opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so: (libxcb-util.so.1: cannot open shared object file: No such file or directory)"为了查找这个错误,每个人都建议安装libxcb-xinerama0,并且几乎每个人都对此表示感谢。所以我安装了它。什么都没变。
另一项建议是"sudo cp ~/..Xauthority /root“。
它也没有改变什么。
如果我从“软件中心”GUI中安装Qt创建者,就会得到一个旧版本的qtcreator,它会运行,但不会识别我安装的任何组件,所以它只是一个文本编辑器。
使用qtdiag检查qt版本
Qt 5.11.3 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 8.3.0) on "xcb"
OS: Debian GNU/Linux 10 (buster) [linux version 5.10.0-0.bpo.3-amd64]这很奇怪,因为我安装了QT5.15。此外,我还看到了许多需要至少QT5.12的GUI工具的报告,因此拥有5.11可能是个问题。我想我有QT5.11.3(甚至在安装Qt之前),因为我运行KDE,KDE使用Qt。
那么现在呢?只要卸载Qt,删除以"qt“开头的任何和所有包,几乎肯定会破坏我的系统。
发布于 2021-04-06 11:59:30
qt的众多论坛之一确实给出了一个答案:
sudo ln -s /usr/lib/x86_64-linux-gnu/libxcb-util.so.0 /usr/lib/x86_64-linux-gnu/libxcb-util.so.1Qt创建者现在开始。在安装libgl1-mesa-dev之前,我仍然无法构建任何GUI程序,甚至连一个"hello world“程序都无法构建(我怎么知道它的名字呢?)错误是一个通用的“找不到IGL")
https://unix.stackexchange.com/questions/643746
复制相似问题