当前位置:网站首页>QT5.5.1桌面版安装配置过程中的疑难杂症处理(配置ARM编译套件)
QT5.5.1桌面版安装配置过程中的疑难杂症处理(配置ARM编译套件)
2022-06-27 15:34:00 【华为云】
记录在红帽6.3系统下安装QT5.5.1环境时,编译过程中,配置编译套件的过程中遇到各种问题的解决办法。介绍了如何配置Android编译环境、嵌入式ARM的编译环境等。
QT5.5.1桌面版安装配置过程中的疑难杂症处理(配置ARM编译套件)
QT 5.5.1红帽子编译
红帽子6.3安装QT5.5.1编译程序问题解决:
安装包命令:rpm -ivh xxxxx.rpm
解决问题1:构建arm编译器套件。
出错原因:选择arm编译器路径时软件会崩溃。
解决办法:手动填写arm编译器g++的路径即可。
好处:通过QT IDE软件即可直接编译出开发板可以直接运行的程序。
.png)





将可执行文件手动拷贝到开发板即可运行!
解决问题2:编译PC桌面版QT程序报错。
错误问题:
error: cannot find -lGL
error: collect2: ld returned 1 exit status
出错原因:缺少以下3个库
mesa-libGL-devel
mesa-libGLU-devel
freeglut-devel
解决办法:红帽子iso虚拟光盘中自带有安装包,直接进入到/media/RHEL_6.3 i386 Disc 1/Packages目录下进行安装即可。
注意:需要先点击虚拟机右下角将iso虚拟光盘挂载到Linux系统里。
安装步骤:
通过文件管理器进入到Packages目录,找到对应安装包,然后鼠标右键安装即可。







以上安装包安装成功之后,就可以直接运行QT程序:

解决问题3:嵌入式开发板qt5字体放置问题 。
问题描述: qt5字体必须放在移植时候指定的安装目录中才可以找到
解决办法:
export QT_QPA_FONTDIR=$QTDIR/lib/fonts 设置环境变量,解决字体路径问题 。
关键是前面加了export关键字,否则设置不起作用。
解决问题4:红帽子QT5.5 android配置

注意:搭建安卓环境需要下载Android版本的QT。


解决问题5:报错gtk库链接错误
将QT安装目录下的libqgtk2.so库删除掉即可。
示例:
/opt/Qt5.5.1.1/5.5/gcc/plugins/platformthemes/libqgtk2.so |
解决后这个问题后,QT程序才可以打开本地文件系统,浏览文件路径。否则遇到需要操作文件系统,或者需要选择路径时,程序就会崩溃掉。

解决后以下代码才可正常运行:
void Widget::on_pushButton_clicked() { QFileDialog::getOpenFileName(this, tr("Open File"), "/", tr("Images (*.png *.xpm *.jpg)")); } |
解决问题6:
QT5.5.1在红帽子中只要点击涉及到浏览文件系统相关选项时,软件将会崩溃。
错误提示:
./qtcreator: symbol lookup error: /opt/Qt5.5.1.1/Tools/QtCreator/bin/plugins/platformthemes/libqgtk2.so: undefined symbol: gtk_dialog_get_widget_for_response |
问题原因:QT自带的GTK库版本不兼容。
解决办法:将QT安装目录下的libqgtk2.so删除掉即可解决问题。
解决步骤:
rm /opt/Qt5.5.1.1/Tools/QtCreator/bin/plugins/platformthemes/libqgtk2.so |
注意:红色部分是自己QT的安装路径。


边栏推荐
- Scrapy framework (I): basic use
- 开源二三事|ShardingSphere 与 Database Mesh 之间不得不说的那些事
- #27ES6的数值扩展
- Condom giants' sales have fallen by 40% in the past two years. What are the reasons for the decline?
- CNN convolutional neural network (the easiest to understand version in History)
- 可变参数模板 Variadic Templates
- Piblup test report 1- pedigree based animal model
- On traversal of tree nodes
- PSS:你距离NMS-free+提点只有两个卷积层 | 2021论文
- 一场分销裂变活动,不止是发发朋友圈这么简单!
猜你喜欢

2022年最新《谷粒学院开发教程》:8 - 前台登录功能

PSS:你距離NMS-free+提點只有兩個卷積層 | 2021論文

About tensorflow using GPU acceleration

字节跳动埋点数据流建设与治理实践

E modulenotfounderror: no module named 'psychopg2' (resolved)

Keep valid digits; Keep n digits after the decimal point;

Pisa-Proxy 之 SQL 解析实践

substrate 技术每周速览 20220411

3.2 multiple condition judgment

#27ES6的数值扩展
随机推荐
Mode setting of pulseaudio (21)
Mobile terminal click penetration
PSS: you are only two convolution layers away from the NMS free+ point | 2021 paper
Go error collection | when a function uses a return value with a parameter name
QT audio playback upgrade (7)
logstash排除特定文件或文件夹不采集上报日志数据
Taishan Office Technology Lecture: the first difficulty is vertical positioning
Cesium 使用MediaStreamRecorder 或者MediaRecorder录屏并下载视频,以及开启摄像头录像。【转】
16 -- remove invalid parentheses
Let's talk about the process of ES Indexing Documents
Weekly snapshot of substrate technology 20220411
What should the ultimate LAN transmission experience be like
Hongmeng makes efforts! HDD Hangzhou station · offline salon invites you to build ecology
创建数据库并使用
Luogu_ P1008 [noip1998 popularization group] triple strike_ enumeration
等保2.0密码要求是什么?法律依据有哪些?
The interview lasted for half a year. Last month, I successfully got Alibaba p7offer. It was all because I chewed the latest interview questions in 2020!
洛谷入门1【顺序结构】题单题解
字节跳动埋点数据流建设与治理实践
CentOS8-postgresql初始化时报错:initdb: error: invalid locale settings; check LANG and LC_* environment