This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

PROCESSOR-SDK-AM62X: Am62x cross compiling QT Application

Part Number: PROCESSOR-SDK-AM62X

Hi TI,

I am trying to build a simple QT application to run it on the Am62x platform. The steps,i followed to build the Qt application is mentioned below.

1. Download and install the Processor SDK for Am62x.

2. Download a simple Qt application.

3. Source the environment-setup in to the Qt application path.

But while sourcing the Environment-setup, i am facing below mentioned issue.

murali@Murali:~/Qt_Wrkspc/examples/gui/analogclock$ source /home/murali/Aurel_Wrkspc/Middleware/ti-processor-sdk-linux/linux-devkit/environment-setup

bash: /home/murali/Aurel_Wrkspc/Middleware/ti-processor-sdk-linux/linux-devkit/sysroots/x86_64-arago-linux/usr/bin/qmake: No such file or directory

I have gone through the forums, but can't able to find the solution. kindly let me know, how to solve the issue.

Regards,

Murali Chikkanna

  • Hello,

    What SDK are you using and do you see the qmake executable in your linux devkit?

    Regards,
    Krunal

  • Hi Krunal,

    Thanks for the quick reply..

    I am using the latest sdk for Am62x : Version : 08.05.00.21

    i can able to see the qmake file in the path mentioned below :

    $  ti-processor-sdk-linux/linux-devkit/sysroots/x86_64-arago-linux/usr/bin

    Regards,
    Murali Chikkanna
  • Hi Murali,

    I am not able to replicate the issue on my side. I downloaded the SDK 08.05.00.21 and I am able to compile the project. Here is an example:

    krunal@krunal:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21$ cd ./linux-devkit/
    krunal@krunal:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit$ source environment-setup
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit> qm
    qmake             qml1plugindump    qmlcachegen       qmlimportscanner  qmllint           qmlplugindump     qmlscene          qmlviewer         
    qml               qmlbundle         qmleasing         qmljs             qmlmin            qmlprofiler       qmltestrunner     
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit> qm
    qmake             qml1plugindump    qmlcachegen       qmlimportscanner  qmllint           qmlplugindump     qmlscene          qmlviewer         
    qml               qmlbundle         qmleasing         qmljs             qmlmin            qmlprofiler       qmltestrunner     
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit> qmake -v
    QMake version 3.1
    Using Qt version 5.14.2 in /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux/usr/lib
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit> 
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21> git clone git://git.ti.com/apps/am62x_hmi_demo.git
    Cloning into 'am62x_hmi_demo'...
    remote: Counting objects: 27, done.
    remote: Compressing objects: 100% (27/27), done.
    remote: Total 27 (delta 2), reused 0 (delta 0)
    Receiving objects: 100% (27/27), 295.60 KiB | 4.93 MiB/s, done.
    Resolving deltas: 100% (2/2), done.
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21> cd am62x_hmi_demo/
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/am62x_hmi_demo> ls
    hmi_demo.pro  images  LICENSE  main.cpp  main.qml  qml.qrc
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/am62x_hmi_demo> qmake
    Info: creating stash file /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/am62x_hmi_demo/.qmake.stash
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/am62x_hmi_demo> make
    aarch64-none-linux-gnu-g++ --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux -c -pipe  --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux -O2 -std=gnu++11 -Wall -Wextra -D_REENTRANT -fPIC -DQT_DEPRECATED_WARNINGS -DQT_NO_DEBUG -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QMLMODELS_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I. -I../linux-devkit/sysroots/aarch64-linux/usr/include -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtQuick -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtGui -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtQmlModels -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtQml -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtNetwork -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtCore -I. -I../linux-devkit/sysroots/aarch64-linux/usr/lib/mkspecs/linux-oe-g++ -o main.o main.cpp
    /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/x86_64-arago-linux/usr/bin//rcc -name qml qml.qrc -o qrc_qml.cpp
    aarch64-none-linux-gnu-g++ --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux -c -pipe  --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux -O2 -std=gnu++11 -Wall -Wextra -D_REENTRANT -fPIC -DQT_DEPRECATED_WARNINGS -DQT_NO_DEBUG -DQT_QUICK_LIB -DQT_GUI_LIB -DQT_QMLMODELS_LIB -DQT_QML_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I. -I../linux-devkit/sysroots/aarch64-linux/usr/include -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtQuick -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtGui -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtQmlModels -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtQml -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtNetwork -I../linux-devkit/sysroots/aarch64-linux/usr/include/QtCore -I. -I../linux-devkit/sysroots/aarch64-linux/usr/lib/mkspecs/linux-oe-g++ -o qrc_qml.o qrc_qml.cpp
    aarch64-none-linux-gnu-g++ --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux --sysroot=/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux -Wl,-O1 -o hmi_demo main.o qrc_qml.o   /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux/usr/lib/libQt5Quick.so /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux/usr/lib/libQt5Gui.so /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux/usr/lib/libQt5QmlModels.so /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux/usr/lib/libQt5Qml.so /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux/usr/lib/libQt5Network.so /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/aarch64-linux/usr/lib/libQt5Core.so -lGLESv2 -lpthread   
    [linux-devkit]:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/am62x_hmi_demo>

    Regards,
    Krunal

  • Hi Krunal,

    Thanks for the response..

    I can't able to find any solution for these. i am just tried installing the ti-processor sdk on another machine with Ubuntu 18.04.6 LTS and tried to solve the issue.but i couldn't. the same problem exist.

    i have attached the image file for your reference.kindly check and let me know your feedback.

    and also i have gone through one of your forum query which is under same issue, there also no solution found.

    https://e2e.ti.com/support/processors-group/processors/f/processors-forum/872645/processor-sdk-am335x-qmake-not-accessible

    Regards,

    Murali Chikkanna

  • Hello,

    Could you try the following commands:

    krunal@krunal:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/x86_64-arago-linux/usr/bin$ file ./qmake
    ./qmake: ELF 64-bit LSB executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/x86_64-arago-linux/lib/ld-linux-x86-64.so.2, BuildID[sha1]=8ed0b982140ace906288ff45ae359f5fcc760b31, for GNU/Linux 3.2.0, stripped
    krunal@krunal:~/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/x86_64-arago-linux/usr/bin$ ldd ./qmake
    ./qmake: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.29' not found (required by ./qmake)
    ./qmake: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.28' not found (required by ./qmake)
    	linux-vdso.so.1 (0x00007ffd74fb6000)
    	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f2f41de8000)
    	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f2f41a4a000)
    	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f2f41832000)
    	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f2f41441000)
    	/home/krunal/work/container_project/ti-processor-sdk-linux-am62xx-evm-08.05.00.21/linux-devkit/sysroots/x86_64-arago-linux/lib/ld-linux-x86-64.so.2 => /lib64/ld-linux-x86-64.so.2 (0x00007f2f42171000)
    

    I have only seen the bash errors when you try running a 32bit binary on a 64bit platform and you are missing certain libraries. I do not think that's the case here but worth checking. On my setup, I have tried various machines and cannot replicate the above issue. 

    Regards,
    Krunal

  • Hi krunal,

    kindly find the output of the listed commands.

    murali@Murali:~/Aurel_Wrkspc/Middleware/ti-processor-sdk-linux/linux-devkit/sysroots/x86_64-arago-linux/usr/bin$ file ./qmake

    ./qmake: ELF 64-bit LSB executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /home/murali/Aurel_Wrkspc/Middleware/linux-devkit/sysroots/x86_64-arago-linux/lib/ld-linux-x86-64.so.2, BuildID[sha1]=8ed0b982140ace906288ff45ae359f5fcc760b31, for GNU/Linux 3.2.0, stripped

    murali@Murali:~/Aurel_Wrkspc/Middleware/ti-processor-sdk-linux/linux-devkit/sysroots/x86_64-arago-linux/usr/bin$ ldd ./qmake

    ./qmake: /lib/x86_64-linux-gnu/libm.so.6: version `GLIBC_2.29' not found (required by ./qmake)
    ./qmake: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.28' not found (required by ./qmake)
    linux-vdso.so.1 (0x00007ffed6feb000)
    libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f8ea9a36000)
    libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f8ea9698000)
    libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f8ea9480000)
    libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f8ea908f000)
    /home/murali/Aurel_Wrkspc/Middleware/linux-devkit/sysroots/x86_64-arago-linux/lib/ld-linux-x86-64.so.2 => /lib64/ld-linux-x86-64.so.2 (0x00007f8ea9dbf000)

    and also the output of my uname -a

    murali@Murali:~/Aurel_Wrkspc/Middleware/ti-processor-sdk-linux/linux-devkit/sysroots/x86_64-arago-linux/usr/bin$ uname -a
    Linux Murali 5.4.0-84-generic #94~18.04.1-Ubuntu SMP Thu Aug 26 23:17:46 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux

    I don't know why this is happening, i tried it on 3 different systems, with ubuntu 18.04 installation. same issues persists on all the 3 machines. i don't know how to proceed on this.

    Regards,

    Murali Chikkanna

    Regards,

    Murali C

  • Hello,

    There is a linux-devkit.sh file and I am wondering if you could try running that to see if it helps with the issue.

    Regards,
    Krunal

  • Hi krunal,

    Thanks that helped.

    The linux-devkit.sh file creates one more setup file inside /usr/local/arago-2021.09/environment-setup.

    Sourcing this path, helped me to build the Qt Applications.

    source /usr/local/arago-2021.09/environment-setup

    Thanks&Regards,

    Murali C

  • Hi krunal,

    I have just built the hello_world QT application is as follows.

    murali@Murali:~/Qt_Wrkspc/hello_world$ source /usr/local/arago-2021.09/environment-setup

    [linux-devkit]:~/Qt_Wrkspc/hello_world> qmake hello_world.pro

    [linux-devkit]:~/Qt_Wrkspc/hello_world> make

    The Output of the file is:

    [linux-devkit]:~/Qt_Wrkspc/hello_world> file hello_world
    hello_world: ELF 64-bit LSB executable, ARM aarch64, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux-aarch64.so.1, for GNU/Linux 3.7.0, with debug_info, not stripped

    After that i copied the file to the file system, then i tried to run the following file inside filesystem.

    root@am62xx-evm:/home# ./hello_world --platform wayland                                                                                       
    qt.qpa.wayland: "wl-shell" is a deprecated shell extension, prefer using "xdg-shell-v6" or "xdg-shell" if supported by the compositor by settN

    root@am62xx-evm:/home# sudo ./hello_world --platform eglfs                                                                          
    QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-root'
    Failed to move cursor on screen HDMI1: -13
    qt.qpa.input: xkbcommon not available, not performing key mapping
    Could not set DRM mode for screen HDMI1 (Permission denied)
    Could not queue DRM page flip on screen HDMI1 (Permission denied)

    I cant able to see the expected output on the HDMI Display. can you please review if anything is missing from side,to display the simple Qt application on HDMI Display.

    And also is there any document, how exactly the QT framework works on the SDK. if yes kindly guide me through the exact DOCUMENTATION.

    Regards,

    Murali C

  • Hello Murali,

    Glad to know that the linux-devkit solved your problem. With regards to running Qt apps, you have the following options:

    1. Using Wayland/Weston: By default, our SDK runs the following Qt demo: https://software-dl.ti.com/processor-sdk-linux/esd/AM62X/08_05_00_21/exports/docs/system/Demo_User_Guides/HMI_and_3D_Demo_User_Guide.html?highlight=hmi. The demo is running on top of a window compositor. If you would like to close the hmi demo, simply run the command "systemctl stop hmi_demo". Next, you will see a grey screen and that's your Weston screen. At that point, you can run any Qt app without specifying "--platform wayland".

    2. Using NullDRM: If you do not want a window compositor, run the command "/etc/init.d/weston stop". At this point, you will see a black screen and now you can run any Qt demo but please specific "--platform eglfs". If the window compositor is running and you run an app with eglfs flag, you will notice permission denied errors.

    We have the graphics stack defined in the following link: https://dev.ti.com/tirex/content/linux-academy-AM62X-8.4.1.3.v2/ch-develop/dev-gpu-porting-guide.html. We do not modify the Qt framework and we simply inherit the meta-qt5 layer and it has the necessary hooks to work with the foundational SW that we provide.  

    Regards,
    Krunal