Qt 6 报错qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found.

解决qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found. 然后,就发现不是包本身的问题,是使用远程服务器的问题,那么问题怎么解决呢? 阅读详情
AI摘要

博客围绕 Qt 6 报错“Could not load the Qt platform plugin “xcb””展开,介绍了一系列解决方法。包括检查平台插件路径、安装必要组件、验证配置、调试插件加载问题、安装字体支持、使用预编译版本、确认 X11 环境以及检查平台支持等,若问题未解决需提供相关信息进一步分析。

1. 检查 Qt 6 平台插件路径

Qt 6 的默认插件路径通常在以下位置:

  • /usr/lib/x86_64-linux-gnu/qt6/plugins/platforms/
  • 或安装路径下的 lib/qt6/plugins/platforms/
检查插件路径:

运行以下命令查找 libqxcb.so:

find / -name "libqxcb.so" 2>/dev/null

如果找到该文件:

  • 设置 QT_PLUGIN_PATH 指向包含 platforms 目录的路径:
    export QT_PLUGIN_PATH=/path/to/qt6/plugins
    

如果未找到插件,请继续进行以下步骤。


2. 安装 Qt 6 必要组件

Qt 6 的 xcb 插件需要安装以下依赖项:

  • Qt 6 基础库
  • X11 和 xcb 相关依赖库
安装命令:
sudo apt-get update
sudo apt-get install qt6-base-dev libxcb1 libx11-xcb1 libxcb-util1 libxcb-xinerama0 \
                     libxcb-keysyms1 libxcb-image0 libxcb-randr0 libxcb-render-util0 \
                     libxcb-shape0 libxcb-xfixes0 libxcb-sync1 libxcb-icccm4 \
                     libxcb-xkb1 libxkbcommon-x11-0

如果你的系统没有预装 Qt 6,可以通过官方 APT 源或手动下载 Qt 6 安装包。

官方 APT 安装 Qt 6:

添加 Qt 官方 APT 源:

wget -nv https://download.qt.io/online/qt6/qt-account-linux-repo.deb
sudo dpkg -i qt-account-linux-repo.deb
sudo apt-get update
sudo apt-get install qt6-base-dev

3. 验证 Qt 6 配置

确保 Qt 6 的环境变量正确配置。

验证命令:

运行以下命令,确认路径:

echo $QT_PLUGIN_PATH
echo $LD_LIBRARY_PATH

如果变量未正确配置,显式设置:

export QT_PLUGIN_PATH=/path/to/qt6/plugins
export LD_LIBRARY_PATH=/path/to/qt6/lib:$LD_LIBRARY_PATH

4. 调试插件加载问题

Qt 提供了一个调试机制,可显示插件加载详细信息。

启用调试:
export QT_DEBUG_PLUGINS=1
./your_application

查看输出日志,确认是否有具体的依赖问题。如果日志中提到缺少某些库,请安装相关库。


5. 安装字体支持

xcb 插件通常需要字体配置支持。

安装命令:
sudo apt-get install libfontconfig1 libfreetype6

6. 使用预编译版本的 Qt 6

如果你当前使用的 Qt 是自己编译的,可能导致插件路径或依赖库缺失。建议使用官方预编译版本。

下载和安装:
  1. 从 Qt 官方网站 下载预编译包。
  2. 解压后,设置路径:
    export PATH=/path/to/qt6/bin:$PATH
    export QT_PLUGIN_PATH=/path/to/qt6/plugins
    export LD_LIBRARY_PATH=/path/to/qt6/lib:$LD_LIBRARY_PATH
    

7. 确认 X11 环境

xcb 插件需要运行在支持 X11 的环境中。如果在无头服务器或 Wayland 环境中运行,请确保 X11 正常工作。

安装虚拟显示(仅适用于无头服务器):
sudo apt-get install xvfb
export DISPLAY=:0
xvfb-run ./your_application

8. 检查 Qt 6 的平台支持

Qt 6 支持多种平台插件(如 Wayland、XCB)。如果系统使用的是 Wayland,可以尝试切换平台插件:

./your_application -platform wayland

如果问题依然存在,强制使用 XCB:

./your_application -platform xcb

总结

如果问题仍未解决,请提供以下信息以便进一步分析:

  1. QT_DEBUG_PLUGINS=1 的完整调试输出。
  2. find / -name "libqxcb.so" 的结果。
  3. 你的 Qt 6 安装方式(系统包、手动编译、官方预编译版本)。
qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in “/home/.conda/envs/py39/lib/pyth 报错解释:这个错误表明Qt应用程序试图加载名为"xcb"的平台插件时失败了。xcb是X Window系统的C语言库,它允许客户端程序通过X Window系统与X服务器通信。Qt使用这个插件来在X Window系统上绘制图形用户界面。问题可能是因为:xcb插件不在指定的目录中。环境变量没有正确设置,导致Qt无法找到插件。插件可能因为缺少依赖或者是不兼容的版本而无法加载。解决方法:确认xcb插件是否存在于指定的目录中。如果不存在,可能需要安装或重新安装Qt。 阅读详情

相关推荐

关于qt.qpa.plugin: Could not load the Qt platform plugin “xcb“的问题

今天在运行代码的时候出现了以下错误,经查找资料,找到了解决方法。 错误如下: QFactoryLoader::QFactoryLoader() checking directory path "/usr/bin/platforms" ... Cannot load library /usr/local/lib/python3.6/dist-packages/cv2/qt/plugins/platforms/libqxcb.so: (libSM.so.6: cannot open shared object

Cl2212的博客 1万+

qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found.

这句话意思是Qt应用程序时缺少xcb平台插件。这可能是因为未安装相应的Qt平台插件库,或者环境变量未正确设置。我们可以通过一下命令解决。

单片机菜鸟学习之路 8594

出现“qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ‘ ’even though it was found

出现“qt.qpa.plugin: Could not load the Qt platform plugin “xcb” in ‘ ’even though it was found 执行.py文件报错: 一个使用Pyqt5库的Python程序时,出现报错: // 注意看最后一段报错信息 Got keys from plugin meta data ("xcb") QFactoryLoader::QFactoryLoader() checking directory path "/usr/bin/plat

qq_49641239的博客 3万+

ubuntu20.04 安装 Qt 后无法启动,出现报错:Could not load the Qt platform plugin “xcb” even though it was found!

本篇博文是记录了作者在安装Qt时遇到的问题以及解决方案。其中包括了Qt在ubuntu系统中的安装以及解决安装后无法启动Qt以及出现报错的问题(Could not load the Qt platform plugin "xcb" even though it was found)。

XY_39的博客 1万+

彻底解决 “Could not load the Qt platform plugin ‘xcb‘” 问题【Qt Linux 部署指南】

摘要: 在Linux(如Ubuntu 18.04)部署Qt程序时,常见“无法加载xcb平台插件”错误,即使插件文件存在。问题根源多为XCB依赖库缺失(如libxcb-xinerama0)。解决方案包括: 安装完整依赖:sudo apt install libxcb-*系列库; 最小修复:优先补装libxcb-xinerama0; 手动检查:通过ldd定位缺失库; 指定插件路径:设置QT_QPA_PLATFORM_PLUGIN_PATH。 调试时可使用QT_DEBUG_PLUGINS=1输出日志,无GUI环境

博客 1068

ANSYS接触分析实战:从法兰连接案例看接触刚度与穿透容差的黄金搭配

本文以法兰连接为实战案例,深入解析了ANSYS接触分析中接触刚度(FKN)与穿透容差(FTOLN)的参数设置策略。通过系统性敏感性分析,揭示了这对关键参数的博弈关系与调优逻辑,旨在帮助工程师在保证计算收敛的同时,获得高精度的有限元分析结果,有效解决工程中的非线性接触难题。

moon9的博客 317

Qt运行程序报错:Could not load the Qt platform plugin “xcb“ in ““ even though it was found

Qt运行程序报错:Could not load the Qt platform plugin “xcb“ in ““ even though it was found

ZY2826的博客 7344

终端以太网接入Internet实验

实验过程: 1.布局 2.连接 3.配置Route0和Route1 4.配置RIP 5.static: 6.查看Route0,Route1的路由表: 7.完成PC2和server0 IP地址,子网掩码和默认网关地址的配置: 8.命令行: 9.启动PC0桌面下的PPPoe宽带连接程序: 10.启动PC1桌面下的PPPoe宽带连接程序: 11.验证PC0和PC2的ICMP报文传输过程 12.验证PC1和server0的ICMP报文传输过程 关键命令说明

chaojidagouzi的博客 4085

ubuntu安装qt5 Could not load the Qt platform plugin "xcb" in "" even though it was found.

百度了好久都没有发现能够解决问题的方法,终于,综合了好几篇博客,得出了如下的解决方法。 Ubuntu安装qt5,启动qtcreator的时候报错,错误如下 This application failed to start because it could not find or load the Qt platform plugin "xcb" in "". Available platform...

u012768805的博客 2万+

DQN网络代码调用env.reset()后存储观测信息报错问题ValueError: setting an array element with a sequence.解决处理

**reset()函数返回的是一个array类型以及其中数据的type!模拟游戏进行学习任务。因此需要将observation指定为真正需要的array信息即可,得到的的变量observation类型与Agent存储时的。因此怀疑返回的observation有问题,于是通过。报错信息提示为数据维度不对应,也即最初通过。在强化学习DQN网络代码实现过程中,针对。

Vulcan_Q的博客 4094

Linux安装消息队列IBM MQ 7.5开发版安装配置详解

消息队列IBM MQ 7.5开发版安装配置详解 文章目录消息队列IBM MQ 7.5开发版安装配置详解前言一、什么是IBM MQ?二、安装前准备1、安装前准备2、安装MQ Server3、启动实例4、创建队列一个名为TEXT的队列(测试)5、启动端口监听6、启动成功总结 前言 IBM 已经熟练地优化了 MQ(消息队列),在市场上已有超过 25 年的历史。借助 MQ(消息队列),如果无法立即传递消息,那么会在其等待队列中确保消息安全,直到保证传递为止。竞争产品可能会传递两次消息或根本不传递消息,而 M

zhx__的博客 5169

【QT】解决问题:qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found.

👉本文介绍解决qtcreator运行问题的过程:qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found.

wkd_007的博客 2879

b站视频链接快速获取

快速获取b站视频数据

qq_45889931的博客 8137

qt.qpa.plugin: Could not find the Qt platform plugin “xcb“ in ““ 详细解决办法

qt.qpa.plugin: Could not find the Qt platform plugin “xcb“ in ““ 详细解决办法

qq_45983373的博客 3万+

把 ABAP SQL 窗口函数讲透:从 OVER 到 LEAD、RANK 与累计分析

ABAP SQL窗口函数在不丢失明细记录的前提下,为每行数据提供组内统计和排名功能。它通过OVER子句定义计算窗口,支持三类函数:聚合型(AVG/SUM等)、排名型(ROW_NUMBER/RANK等)和取值型(LEAD/LAG)。相比GROUP BY会合并多行数据,窗口函数保留原始记录同时附加计算结果,特别适合需要保留明细又要展示统计信息的业务场景,如销售排名、客户分层分析等。语法核心是OVER子句,通过PARTITION BY分组,ORDER BY排序,可灵活定义计算范围。

2007 年 ~ 2025 年,深耕 SAP 技术 18 年 1279

使用 Simulink Real-Time 搭建一个完整的实时信号采集与滤波系统模型

本文详细介绍了基于Simulink Real-Time构建实时信号采集与滤波系统的完整流程。主要内容包括:系统配置(模型创建与参数设置)、信号采集模块搭建(模拟信号源或真实硬件连接)、实时滤波器设计(浮点/定点)、输出可视化(Scope/ToWorkspace等)、模型编译与下载到目标机、外部模式在线调试及数据保存方法。系统可实现微秒级实时信号处理,适用于工业控制、航空航天等对时间确定性要求高的场景。文章还提供了优化建议(多速率建模、优先级调度等)和应用场景说明,帮助读者快速掌握实时系统开发的核心技能。

amy_mhd的博客 309

报错 qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found.

发现是Qt加载插件出现问题,通过设置QT_DEBUG_PLUGINS=1,可以查看Qt的插件加载信息。 所以先设置环境变量: export QT_DEBUG_PLUGINS=1 再次运行程序时,会打印出很多信息,重点是最后一段: 它提示无法加载libqxcb.so,原因是libxcb-icccm.so.4: 无法打开共享对象文件: 没有那个文件或目录,也就是说libxcb-icccm.so.4共享库丢失,导致无法加载libqxcb.so。 于是运行 apt search libxcb-i...

是鲤鱼啊 3万+

UEFI 基础教程 (零) - 目录

UEFI 基础教程 (十八) — UEFI Build Process简单分析。UEFI 基础教程 (十五) — 获取UEFI MemoryMap。UEFI 基础教程 (六)   —  PROTOCOL 简单使用。UEFI 基础教程 (十)   —  FileIO 简单使用。UEFI 基础教程 (一)   —  搭建UEFI开发环境。UEFI 基础教程 (九)   —  EVENT 简单使用。UEFI 基础教程 (七)   —  HOB 简单使用。UEFI 基础教程 (八)   —  PCD 简单使用。..

技术联盟 1541

【DeBug】qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found.

pyqt5在ubuntu中报错 一、报错信息 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. Avail

Liu Feng's Blog 6699

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

Outlook Express 6 (OE6) for Win7/Win8/Win10

英文版 Outlook Express6.0, 兼容Win7/Win10/WinXP,解压就可用。

【Docker】OpenCV:qt.qpa.plugin: Could not load the Qt platform plugin “xcb”

一、问题描述 具体报错如下: qt.qpa.plugin: Could not load the Qt platform plugin “xcb” in “*************/site-packages/cv2/qt/plugins” even though it was found. This application failed to start because no Qt platform plugin could be initialized. Reinstalling the applic

Felaim的博客 9057

WINCC7.3破解文件

WINCC7.3硬件够破解文件,有需要的下载!WINCC7.3硬件够破解文件,有需要的下载!

(已解决)报错:qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found

问题: ubuntu16.04系统,pycharm运行程序报错: 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 probl

Keyu_logs 5551

VB摄像头监控

该VB模块可对摄像头捕获的画面进行录像等,可在创建的窗口进行控制

pyqt qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was found.

当我玩一下 PyQt 时,问题出现了 问题代码: #! /usr/bin/env python # -*- coding: utf-8 -*- import sys from PyQt5 import QtWidgets, QtCore if __name__ == '__main__': app = QtWidgets.QApplication(sys.argv) widget = QtWidgets.QWidget() widget.resize(320, 240)

gfdgd xi 2882

远程服务器调试GUI界面报错qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was

通过连接远程服务器运行代码,并实现GUI界面的本地显示。

m3026739773的博客 1100

Ubuntu 22.04 qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in even though it was found.

总结:此方法并不一定适用于所有人,我尝试将各种依赖安装、添加,但仍无法解决,最后加上这条语句后即可运行,也推荐一下stack overflow这个网站上检索查找问题解决 弊端是都是英文 要有一定英文基础。但笔者在查看网上多篇文章 尝试多种方法并添加相关依赖、多次重新下载也无法解决此问题,最后在stack overflow网站尝试寻找解决方法,运行后即可打开。问题: 在Linux环境下 环境:Ubuntu22.04 安装Qt版本:Qt6.2.4 安装后点击QtCreator图标无效。

warrior____的博客 3275

Ubuntu20.04 解决qt.qpa.plugin: Could not load the Qt platform plugin “xcb“ in ““ even though it was

在这其中的libQt5XcbQpa.so.5 => not found,说明缺少libQt5XcbQpa.so.5,安装libqt5gui5软件包,来补全缺失的包。我使用的是ubuntu子系统,可以在win的文件管理器中查找libxcb.so,找到libxcb.so所在的位置。注意cd后的文件路径为你自己的文件路径,还有就是在win的文件管理器中复制的文件路径为"\"需要改为“/”。如果还缺少包,只需要安装相应的软件包就行,至此我电脑的这个问题解决了。造成这个问题的原因可能是缺少libxcb.so包。

UniqueLiu126的博客 3667
上一篇: python报错ModuleNotFoundError: No module named ‘_bz2
下一篇: fairseq 0.12.2 depends on omegaconf<2.1 hydra-core 1.0.7 depends on omegaconf<2.1 and >=2.0.5
dbcccccsds
博客等级 码龄6年 3190粉丝 91原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值
⌂ 换网址