Build QtCreator on Raspberry Pi

01/02/2018 - 12:10
Average: 2.5 (2 votes)

This tutorial will explain how to build a native QtCreator to run on a Raspberry Pi using Qt 5.10.

First steps

Remove installed Qt packages

For some reason installed Qt libraries might cause link failures, so we need to get rid of them first. So if you have Qt 5.7 already installed from Debian Stretch packages, remove them first with apt-get:

apt-get remove <list-all-installed-qt-packages-here>

Build Qt 5.10

First you need to various build tool and of course a build Qt 5.10 on your Raspberry Pi, follow this tutorial for instructions on how to install required packages and building of Qt 5.10.

When you have done that succesfully, come back here.

Install required packages

We need to install botan a C++ crypto library, as we will build QtCreator against it.

apt-get install libbotan1.10-dev

Build QtCreator

Download QtCreator sources


Unpack the source

tar xf qt-creator-opensource-src-4.5.0.tar.xz

Configure the build

Run qmake against the sources. We will assume that Qt 5.10 is installed in /opt/Qt5.10 (and if not, adjust the path for your installation)

We need to set "USE_SYSTEM_BOTAN=1" so that the integrated botan will not be used as it does not check properly the build architecture and will assume x86 and therefor tries to use features that are not available on ARM.

/opt/Qt5.10/qmake USE_SYSTEM_BOTAN=1

Compile QtCreator

Next start the compilation. This will take a while.


Install QtCreator

Next install the just built QtCreator, you can use whatever path you like, I prefer installing custom software under /opt.

make install INSTALL_ROOT=/opt/QtCreator4.5

Run QtCreator

You should now be able to start QtCreator with (running under X11):

/opt/QtCreator4.5/bin/qtcreator -platform xcb

You can also run it without X11, in that case just run without the platform parameter:

Qt, QtCreator, Raspberry Pi