Problem Description After installing Qt5.15.0, an error pops up when running a test case:
According to the problem description, the Qt platform plug-in "xcb" can be found but cannot be loaded. Although it is said that reinstalling may solve the problem, if this is possible, try to use it as the last option. Positioning Problem Modify the configuration file ~/.bashrc: $ vim ~/.bashrc Adding the following statement at the end will list detailed error messages when qtcreator is started. export QT_DEBUG_PLUGINS=1 as follows: Save and exit editing to make the configuration file effective: $ source ~/.bashrc When starting qtcreator, the following detailed error message will pop up: At the bottom of the printed error message, the real cause of the error was found: That is the problem of Qt dynamic link library. When loading libqxcb.so library, you also need to load libxcb-xinerama library. #Replace with your own error directory$ cd /home/brainiac/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/ Run ldd libqxcb.so to view the associated content: $ ldd libqxcb.so It was found that the libxcb-xinerama.so.0 library does not exist. Workaround Install the libxcb-xinerama library: #If there are other dependent libraries that have not been installed, install them as well. $ sudo apt-get install libxcb-xinerama0 After the installation is complete, check the associated content again and find that the problem has been fixed: $ ldd libqxcb.so Run the qt program again and it will run normally. postscript I can happily code again. Summarize This is the end of this article about how to solve the problem of qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in Qt under Ubuntu 18.04. For more information about how to solve the problem of qt.qpa.plugin in Qt under Ubuntu 18.04, please search for previous articles on 123WORDPRESS.COM or continue to browse the related articles below. I hope you will support 123WORDPRESS.COM in the future! You may also be interested in:
|
<<: Detailed tutorial for downloading and installing mysql8.0.21
>>: Detailed explanation of the use of $emit in Vue.js
Query the current date SELECT CURRENT_DATE(); SEL...
Database MySQL version 8.0.18 Download a DBeaver....
1. Add the plug-in and add the following configur...
MySql uses joined table queries, which may be dif...
Table of contents 1.DB,DBMS,SQL 2. Characteristic...
This article mainly describes two kinds of underl...
Purpose Encapsulate the carousel component and us...
This article shares the specific code for JavaScr...
Table of contents 1. Comparison of data before an...
1. Modify the firewall configuration file # vi /e...
1. Basic steps 1: Install yarn add vue-i18n Creat...
Table of contents 1. Variable Overview 1.1 Storag...
1. CSS Navigation Bar (1) Function of the navigat...
Difference between HTML and XHTML 1. XHTML elemen...