Setup QT Creator with Yocto Build

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Setup QT Creator with Yocto Build

Setup QT Creator with Yocto Build

bitbaked meta-toolchain-qt

Install it  with

~/yocto/build/tmp/deploy/sdk$ poky-eglibc-x86_64-arm-toolchain-qt-1.4.1.sh

Download Qtcreator from here http://qt-project.org/downloads

and Install it to Your home directory

edit the bin/qtcreator.sh

source /opt/poky/1.4.1/environment-setup-armv7a-vfp-neon-poky-linux-gnueabi
#! /bin/sh

makeAbsolute() {
    case $1 in
        /*)
            # already absolute, return it
            echo "$1"
            ;;
        *)
            # relative, prepend $2 made absolute
            echo `makeAbsolute "$2" "$PWD"`/"$1" | sed 's,/\.$,,'
            ;;
    esac
}

....

To do it before "#! /bin/sh" is IMPORTANT!!!!

In QtCreator i set

Compiler as

               /opt/poky/1.4.1/sysroots/x86_64-pokysdk-linux/usr/bin/armv7a-vfp-neon-poky-linux-gnueabi/arm-poky-linux-gnueabi-g++

Qt version as

        

                     /opt/poky/1.4.1/sysroots/x86_64-pokysdk-linux/usr/bin/qmake

sysroot as

                    /opt/poky/1.4.1/sysroots/armv7a-vfp-neon-poky-linux-gnueabi

Put them in a Kit

For connection to Your Board click on  Device  --->    Manage

Build a new project

and add some to the .pro file

Building the image for Your Board:

add        

EXTRA_IMAGE_FEATURES = "debug-tweaks ssh-server-openssh" to Your localconfig

bitbake core-image-sato-sdk

set a password to root  via

ssh root@[boardip]

passwd

test connection via

sftp  root@[boardip]

start qtcreator

./qtcreator.sh

Message was edited by: Joerg Boge

Good Video to get more Information about Programming are this

Beaglebone: LCD Touchscreen GUI Applications for Embedded Linux - YouTube

Beaglebone: Qt Creator for C++ ARM Embedded Linux Development - YouTube

Beaglebone: Example Qt Embedded Linux Application - YouTube

It is for Beagelbone but for programming Qt it is a good start.

Dieses Dokument wurde aus folgender Diskussion erzeugt: Setup QT Creator with Yocto Build

Comments

Hi there!

Starting the ./qtcreator.sh from the Terminal works fine for me but isn't very convenient I think.

Why isn't it possible to set all the env-Variables directly in the build settings of Qt Creator?

Setting the environment variables (which is everyhing what the environment-setup-... does at the moment) directly in Qt Creator (Projects->Build Settings->Build Environment) doesn't work - does anyone know why?

The other way around for me would be to create a .desktop for a quick execution of the .sh from the Desktop/Starter Menu.

But there is another problem with creating a .desktop file on Ubuntu: It doesn't find the environment-setup-... (1: /mypath/qtcreator.sh: source: not found) on starting with the .desktop-file - is there something wrong? As already set: Executing it directly from the terminal works flawlessly.

qtcreator.desktop (in same directory as qtcreator.sh)

[Desktop Entry]

Version=2.8.1

Name=Qt Creator

Exec=/mypath/qtcreator.sh

Icon=QtProject-qtcreator

Terminal=true

Type=Application

Categories=Development;IDE;Qt;

MimeType=text/x-c++src;text/x-c++hdr;text/x-xsrc;application/x-designer;application/vnd.nokia.qt.qmakeprofile;application/vnd.nokia.xml.qt.resource;text/x-qml;

Any other ideas in improving this step and working around the "problem" of starting the qtcreator from the terminal?

Me again :smileywink:

Maybe we should also mention to use bitbaked meta-toolchain-qte to use e.g. the QWS Qt Window Server without the need for X11.

What do you think?

Best regards

Florian

Hello Florin,

You should give it a try. I build fsl-image-gui with that local.conf features:

MACHINE ??= 'YOURBAORD'

DISTRO ?= 'poky'

PACKAGE_CLASSES ?= "package_rpm"

EXTRA_IMAGE_FEATURES = "debug-tweaks ssh-server-openssh"

CORE_IMAGE_EXTRA_INSTALL_append = "openssh-sftp-server "

TOOLCHAIN_HOST_TASK_append = " nativesdk-python-subprocess" 

works fine. debugging i did'nt test till now

So with this setup you were able use QWS without X11? Because I also tried successfully the fsl-image-gui. But then it uses X11 instead of directfb for rendering the Qt-Application.

For performance and faster boot I wanted to get rid of X11.

And what I thought is, that I have to use the meta-toolchain-qte instead of meta-toolchain-qt to compile my Qt-App the right way - if that is the case we should mention it in this DOC.

I am following all the steps mentioned above, however after I  boot the Nitrogen 6x  board, I am unable to connect through sftp.

It has the following error, can someone please help me out

sftp root@192.168.2.26

root@192.168.2.26's password:

sh: /usr/lib/openssh/sftp-server: No such file or directory

Connection closed

Thanks

When I run "bitbaked meta-toolchain-qt", I meet a problem.

Missing or unbuildable dependency chain was ["meta-toolchain-qt","packagegroup-qt-toolchain-target","qt4-mkspecs","virtual/libx11"]

Why it is?

No ratings
Version history
Last update:
‎07-30-2013 07:33 AM
Updated by: