是否有关于如何在Raspberry Pi3上构建Qt5.6甚至5.5的工作指南?
我在Wiki上发现了一些指南,这些指南在某种程度上看起来都是不完整的,我试过的最后一个是:
https://wiki.qt.io/RaspberryPi2EGLFS
在我到达之前哪个是好的:
./configure -release -opengl es2 -device linux-rasp-pi2-g++ -device-option CROSS_COMPILE=~/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf- -sysroot ~/raspi/sysroot -opensource -confirm-license -make libs -prefix /usr/local/qt5pi -extprefix ~/raspi/qt5pi -hostprefix ~/raspi/qt5 -v
我不确定它是否因为它是一个Pi2但是这个错误:
The OpenGL ES 2.0 functionality test failed!
You migh need to modify the include and library search paths by editing QMAKE_INCDIR_OPENGL_ES2, QMAKE_LIBDIR_OPENGL_ES2 and QMAKE_LIBS_OPENGL_ES2 in /home/.../raspi/qtbase/mkspace/mkspecs/devices/linux-rasp-p2-g++.
我不确定如何进一步发展,谢谢 .
编辑,继承了更多信息:
我有一个Raspberry Pi 3,运行:
Linux pi3 4.1.21.v7+ #872 SMP Wed Apr 6 17:34:14 BST 2016 armv71 GNU/Linux
我看到的第一个错误是:./ configure:3497:./ configure:/ home / simon / raspi / tools / arm-bcm2708 / gcc-linaro-arm-linux-gnueabihf-raspbian / bin / arm-linux-gnueabihf-克:没找到
我去了:
~/raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin
并输入:arm-linux-gnueabihf-g
它没有安装,所以:sudo apt-get install g -arm-linux-gnueabihf
安装好了,然后再次尝试了configure指令,结果相同,还是找不到arm-linux-gnueabihf-g
编辑2016/06/12 ...我尝试了另一个来源:
这也有问题,有两个库是一个问题:
libjpeg62-dev and libxcb-sync0-dev
任何人都可以向我推荐准确且有效的信息吗?
编辑2016/06/13,在按照RSATom发布的信息后,我尝试了维基页面上的信息和下载Qt,两者在执行配置时都会产生相同的结果...
运行配置测试(阶段2)...无法处理平台'devices / linux-rasp-pi2-g'的makepec项目错误:编译器/ home / pi / raspi / tools / arm-bcm2708 / gcc-linaro-arm-找不到linux-gnueabihf-raspbian / bin / arm-linux-gnueabihf-g . 检查CROSS_COMPILE -device-option的值无法读取qmake配置文件/ home / pi / qtbase / mkspecs / devices / linux-rasp-pi2 -g /qmake.conf . 处理项目文件时出错:/ dev / null
make make: *** No targets specified and no makefile found. Stop. pi@pi3:~/qtbase $ make install make: *** 没有规则来制作目标'install' . 停止 .
2 nd企图,2016/06/14 ......
OpenGL ES 2.0已禁用 . OpenGL ES 2.0功能测试失败了!您可能需要通过编辑/ home / pi / raspi / qt5pi / qtbase / mkspecs / devices / linux-rasp-pi2-g中的QMAKE_INCDIR_OPENGL_ES2,QMAKE_LIBDIR_OPENGL_ES2和QMAKE_LIBS_OPENGL_ES2来修改包含和库搜索路径 .
3 rd企图,2016/06/15 ......
好的,从头开始并按照以下信息:
https://wiki.qt.io/RaspberryPi2EGLFS
首先,我在Pi 3上检查了我的操作系统:
uname -a
结果:
Linux pi3 4.4.9-v7+ #884 SMP Fri May 6 17:28:59 BST 2016 armv7l GNU/Linux
然后:
lsb_release -a
结果:
No LSB modules are available.
Distributor ID: Raspbian
Description: Raspbian GNU/Linux 8.0 (jessie)
Release: 8.0
Codename: jessie
确定了这一点后,我跳到了第3步 .
第4步,我第一次没有正确阅读,我不希望跨平台开发我想直接在Pi 3上开发 .
但是,我有Oracle VirtualBox运行版本5.0.20 r106931和一个Ubuntu虚拟机,启动了这个,当前版本的Ubuntu:
uname -a
Linux simon-VirtualBox 3.19.0-59-generic #66-14.04.1-Ubuntu SMP Fri May 13 17:27:10 UTC 2016 x86_64 x84_64 GNU/Linuxu
lsb_release -a
No LSB modules are available.
Dsitributor ID: Ubuntu
Description: Ubuntu 14.04.4 LTS
Release: 14.04
Codename: trusty
已完成步骤4,5,6 .
将步骤7中的链接替换为:
wget download.qt.io/official_releases/qt/5.6/5.6.0/single/qt-everywhere-opensource-src-5.6.0.tar.gz
然后提取:
tar -zxvf qt-everywhere-opensource-src-5.6.0.tar.gz
完成重命名文件夹'qt-everywhere-opensource-src-5.6.0'到'qtbase'后:
mv qt-everywhere-opensource-src-5.6.0 qtbase
然后在克隆指令后继续执行步骤7:
cd qtbase
此时,在滚动消息几秒钟后会出现大量错误,其结尾为:
OpenGL ES 2.0 disabled.
The OpenGL ES 2.0 functionality test failed!
You might need to modify the include and library search paths by editing
QMAKE_INCDIR_OPENGL_ES2, QMAKE_LIBDIR_OPENGL_ES2 and QMAKE_LIBS_OPENGL_ES2 in
/ home / simon / raspi / qtbase / qtbase / mkspecs / devices / linux-rasp-pi2-g .
4 th尝试,2016/06/18 ......
感谢RSATom的努力,事情取得了一些进展 .
我使用以下方法升级了Jessie的安装:
wget https://raw.githubusercontent.com/Topguy/Raspberry-Qt5-experiments/master/qt5_twolife_jessie_setup.sh
使下载的脚本可执行:
chmod +x qt5_twolife_jessie_setup.sh
执行脚本:
./qt5_twolife_jessie_setup.sh
这将添加一个新的存储库,用于更新,更新系统:
sudo apt-get update
sudo apt-get upgrade
确保您拥有所有必需的工具:
sudo apt-get install build-essential
确保您具有所需的opengl组件:
sudo apt get install libgl1-mesa-dev libglu1-mesa-dev
安装qt5:
sudo apt-get install qt5-default
再次更新系统:
sudo apt-get update
sudo apt-get upgrade
这是我被卡住的地方,因为系统不允许我执行qtcreator的安装:
sudo apt-get install qtcreator
它出错了,如果我然后重新启动Pi,它将无法启动,我已经执行了两次这个序列,虽然看起来确实安装了Qt5.5,但是它没有完成并且打砖,或者至少不会启动SD卡重新闪存 .
我现在正在寻找一个解决方案来找出为什么Pi在安装此更新后不会预订以及为什么qtcreator不会安装 .
5 th尝试,2016/06/19 ......
下载的Qt5.7源代码:
wget http://download.qt.io/official_releases/qt/5.7/5.7.0/single/qt-everywhere-opensource-src-5.7.0.tar.gz
提取:
tar -zxvf qt-everywhere-opensource-src-5.7.0.tar.gz
感谢dbmitch,链接:
它如此令人沮丧,上面的链接看起来非常有前景,但我找不到任何链接到提到的Pi 3 Qt图像 .
2016/06/29 今天发现,看起来很有希望,今晚会尝试:Building Your Own Embedded Linux Image
我很快就没有耐心了,按照上面链接的说明,我真的不认为这个页面的作者已经尝试过使用链接上提供的工具 .
QtCreator中的菜单引用不存在 . 它不容易理解,他们是否想要促进产品的使用?我每天都在工作中使用Qt环境并且它非常出色,但为什么在应该支持的平台上实现这一点并非如此困难?
2016 / 07/01幸运第六次?...
一世在这一行上简单地改变了5.6到5.7:
git clone git://code.qt.io/qt/qtbase.git -b 5.6
它的工作原理......至少我在Ubuntu 16.04上构建并制作了5.7,当它完成时我会将它同步到...我会回来发布结果 .
看我的回答......
3 回答
最后成功,请点击此链接:
Installing 5.6 step by step instructions
最后我实际上安装了5.7并且效果很好!只需将git pull参数从5.6更改为5.7即可!
非常感谢RSATom
尝试安装libgl1-mesa-dev,libglu1-mesa-dev和mesa-common-dev .
Link describing preparing RaspPi for Boot to QT
不确定这是否会对您有所帮助,因为看起来您正在尝试构建自己的,但看起来最新版本可能会为您提供另一种选择 .
Downloads for QT 5.7
在release notes for 5.7版刚刚发布的6月16日
从他们的博客......
https://blog.qt.io/blog/2016/06/16/qt-5-7-for-device-creation/
New Device Images