QT5.2.x crosscompile general advice
i'm trying to cross-compile QT5.2 for my raspberry, like most of you do ;-)
I need some general advice.
What I've done:
- I already have raspbian configured and running and don't want to change it anymore (if possible)
- I'm following the steps described in http://qt-project.org/wiki/RaspberryPi_Beginners_guide
What do i have to do differently so that i can:
- crosscompile and install QT on my host linux, e.g. to one folder. The beginners guide somehow merges the compiled QT file into a wheezy image. But i want to keep my existing raspbian system
- copy that folder to my raspberry and run a qt-programm
- raspberry: NOOBS - raspbian image
- Host: Linux Debian (downloaded the newest version via net-installer; i don't know which version exactly)
Thanks a lot for your help,
actually i don't mind any more to use a fresh raspbian installation. If it keeps me from more headache, then that's the way to go.
bq. I followed it as well and I got it working after pulling a few hairs.
Ok, that's the interesting part now.
- Which parts did you follow exactly and which did you have to change? Even if the changes were small.
- Any other steps you needed to do, which is not explained in the guide?
- Did you follow the guide itself or did you use the script "bakeqtpi.bash"?
bq. Not all modules in the guide will work
- Can you tell me which ones won't work?
- What about QtQuick or qmlviewer/qmlscene?
Thanks a lot for your help. Would be great if i could finally built it.
thanks so much. That were exactly the hints i needed.
- I used the latest rasbpian image
- I didn't use the bakeqt.bash script
- I didn't use the patch
Now, i could successfully run the QTquick example, which i cross-compiled on my host-pc with qtcreator.
There are still a few things i'm stuck with, so you might be able to help with those as well:
- qmlviewer/qmlscene don't come with the normal download of the qt5 binaries, right? Where do i get them?
- Some qt5 module folders were empty, that was the same for you, right? But, the folder qtjsbackend doesn't exist at all. Same for you?
- Weird: i can compile and run a qtquick hello world programm on my raspberry, but cannot compile it for my debian host desktop:
/mnt/rasp-pi-rootfs/usr/local/qt5pi/include/QtGui/qopengl.h:82: Fehler: GLES2/gl2.h: No such file or directory
- How can i automatically mount the RPI image at the start of my debian host?
What's the entry in /etc/fstab for the following mount command:
sudo mount -o loop,offset=62914560 2014-01-07-wheezy-raspbian.img /mnt/rasp-pi-rootfs
- Where do i have to enter the following command from the beginners tutorial. I cannot find the edit field in QTcreator
Then go to the “Rasperry Pi” kit tab->System Environment and add LD_LIBRARY_PATH which is set to /usr/local/qt5pi/lib
Thanks so much again for your help,
it now works for me well enough, to keep it that way. ;-)
I still cannot run an application on the desktop AND on the raspberry pi. I have to build two different apps for it.
I thought that's one of the big advantages of QT that i can create a qml app and run it on the desktop. When it's finished i would deploy it to my raspberry, simple by changing the kit?!
Thanks anyway, Ben