Apt-get QT4 on the Raspberry Pi: Difference between revisions

From Qt Wiki
Jump to navigation Jump to search
No edit summary
 
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
[toc align_right="yes" depth="3"]
#REDIRECT [[Apt-get Qt4 on the Raspberry Pi]]
 
= Tutorial : apt-get install Qt4 on the Rasperry Pi =
 
Using the Raspbian image
 
== apt-get ==
 
Firstly I got the development tools needed by Qt Creator in the hope it would be less heavy for the Pi to download separately.<br /><code>sudo apt-get install qt4-dev-tools<code>
 
Then I went for Qt Creator<br /></code>sudo apt-get install qtcreator</code>
 
I also installed<br /><code>sudo apt-get install gcc<br />sudo apt-get install xterm<br />sudo apt-get install git-core<br />sudo apt-get install subversion</code><br />this gives as a result Qt Creator 2.5 with Qt 4.8.1 32 bit
 
== Problem : no toolchain. ==
 
We can only compile for remote embedded devices and this is not the case here, because we are on the Pi and not remotely accessing it.
 
=== I added a gcc toolchain ===
 
Tools/Options &gt; build &amp; run &gt; tab tool chains &gt; button add<br />Choose GCC<br />* Then set compiler path : /usr/bin/arm-linux-gnueabihf-gcc-4.6<br />* Debugger : /usr/bin/gdb<br />* Mkspec : default
 
=== Qt Creator seems to detect that we are going to deploy on a remote target. ===
 
To fix this :<br />* Go to menu help &gt; about plugins<br />* Uncheck device support &gt; remote linux<br />* Restart Qt Creator<br />* Go to tools &gt; options TAB &gt; build &amp; run &gt; Qt versions &gt; add “/usr/bin/qmake-qt4”
 
It will then show up as a desktop project in the project wizard instead of embedded.

Latest revision as of 17:35, 3 March 2015