Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Beaglebone Cross compile setup
Qt 6.11 is out! See what's new in the release blog

Beaglebone Cross compile setup

Scheduled Pinned Locked Moved Solved Installation and Deployment
3 Posts 2 Posters 2.8k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    Grkan
    wrote on last edited by
    #1

    Hello,

    First of all, I want to mention I've never worked QT and Linux before. I'm quite new to this environment.

    I've been trying to develop a simple application for Beaglebone Black.

    After I've searched quite bit, I've seen there a lot of information on internet but most of them are out-ouf-date. I just need to some guidance to setup the environment if you anyone can help.

    In last 3 days, I've learned that;
    -Get an image for BBB (I've created with Debian 9.5 2018-10-07 4GB SD LXQT which has GCC 6.3.0)
    -Download Linaro Arm Toolchain ( https://releases.linaro.org/components/toolchain/binaries/6.3-2017.05/arm-linux-gnueabihf/)
    -Download QT (I've used binary file again from http://download.qt-project.org/official_releases/qt/5.9/5.9.0/)
    First I've used the online installer (qt-unified-linux-x64-4.0.1-online.run). I was able to build a demo application for linux but I couldnt create a kit for Beaglebone Black. As I understood I need to compile from source code with ./configure to be able to create qmake for BBB.

    I've tried to use this config

    ./configure -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
    

    But I'm getting this output in log file

    Command line: -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
    executing config test verifyspec
    + cd /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/config.tests/common/verifyspec && /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared console single_arch" "QMAKE_CFLAGS += --sysroot=home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf" "QMAKE_CXXFLAGS += --sysroot=home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf" "QMAKE_LFLAGS += --sysroot=home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf" -early "CONFIG += cross_compile" /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/config.tests/common/verifyspec
    > /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/mkspecs/features/toolchain.prf:129: Variable QMAKE_CXX.COMPILER_MACROS is not defined.
    > Project ERROR: Compiler home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ not found. Check the value of CROSS_COMPILE -device-option
    

    I can confirm that home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ is existing.

    I've tried installing qt5.15.2 (http://download.qt-project.org/official_releases/qt/5.15/5.15.2/single/)
    With ./configure I'm getting following error and nothing in log file

    + cd qtbase
    + /home/grkan/QtForBBB/qt-everywhere-src-5.15.2/qtbase/configure -top-level -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
    Creating qmake...
    make: Nothing to be done for 'first'.
    Command line: -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
    Project ERROR: Cannot run target compiler 'home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++'. Output:
    ===================
    ===================
    Maybe you forgot to setup the environment?
    
    

    Can someone please direct in a direction so I can build QT and start developing the application please?

    Thank you.
    Gurkan

    jsulmJ 1 Reply Last reply
    1
    • G Grkan

      Hello,

      First of all, I want to mention I've never worked QT and Linux before. I'm quite new to this environment.

      I've been trying to develop a simple application for Beaglebone Black.

      After I've searched quite bit, I've seen there a lot of information on internet but most of them are out-ouf-date. I just need to some guidance to setup the environment if you anyone can help.

      In last 3 days, I've learned that;
      -Get an image for BBB (I've created with Debian 9.5 2018-10-07 4GB SD LXQT which has GCC 6.3.0)
      -Download Linaro Arm Toolchain ( https://releases.linaro.org/components/toolchain/binaries/6.3-2017.05/arm-linux-gnueabihf/)
      -Download QT (I've used binary file again from http://download.qt-project.org/official_releases/qt/5.9/5.9.0/)
      First I've used the online installer (qt-unified-linux-x64-4.0.1-online.run). I was able to build a demo application for linux but I couldnt create a kit for Beaglebone Black. As I understood I need to compile from source code with ./configure to be able to create qmake for BBB.

      I've tried to use this config

      ./configure -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
      

      But I'm getting this output in log file

      Command line: -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
      executing config test verifyspec
      + cd /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/config.tests/common/verifyspec && /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/bin/qmake "CONFIG -= qt debug_and_release app_bundle lib_bundle" "CONFIG += shared console single_arch" "QMAKE_CFLAGS += --sysroot=home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf" "QMAKE_CXXFLAGS += --sysroot=home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf" "QMAKE_LFLAGS += --sysroot=home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf" -early "CONFIG += cross_compile" /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/config.tests/common/verifyspec
      > /home/grkan/QtForBBB/qt-everywhere-opensource-src-5.9.0/qtbase/mkspecs/features/toolchain.prf:129: Variable QMAKE_CXX.COMPILER_MACROS is not defined.
      > Project ERROR: Compiler home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ not found. Check the value of CROSS_COMPILE -device-option
      

      I can confirm that home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ is existing.

      I've tried installing qt5.15.2 (http://download.qt-project.org/official_releases/qt/5.15/5.15.2/single/)
      With ./configure I'm getting following error and nothing in log file

      + cd qtbase
      + /home/grkan/QtForBBB/qt-everywhere-src-5.15.2/qtbase/configure -top-level -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
      Creating qmake...
      make: Nothing to be done for 'first'.
      Command line: -device linux-beagleboard-g++ -device-option CROSS_COMPILE=home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf- -sysroot home/grkan/opt/arm-toolchain/sysroot-glibc-linaro-2.23-2017.05-arm-linux-gnueabihf -opensource -confirm-license -optimized-qmake -release -make libs -prefix /usr/local/qt5bbb -hostprefix /usr/local/qt5bbb -qt-zlib -qt-libpng -openssl -v
      Project ERROR: Cannot run target compiler 'home/grkan/opt/gcc-linaro-6.3.1-2017.05-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++'. Output:
      ===================
      ===================
      Maybe you forgot to setup the environment?
      
      

      Can someone please direct in a direction so I can build QT and start developing the application please?

      Thank you.
      Gurkan

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @Grkan said in Beaglebone Cross compile setup:

      CROSS_COMPILE=home/grk

      You're missing a / here:

      CROSS_COMPILE=/home/grk
      

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      4
      • G Offline
        G Offline
        Grkan
        wrote on last edited by
        #3

        Thank you @jsulm, I've missed that part. It has been compiled and I'm available to deploy and debug right now.

        1 Reply Last reply
        1

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved