Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Yocto Recipe for Building QT5 App



  • Is this something normally done with Yocto? I noticed that demo QT5 recipe apps contained in both the meta-qt5 layer and from my SOC vendor's bsp layer seem to simply pull tarballs/archives of the built application down from a remote repo rather than pulling any source and building it.

    Yocto actually has a wiki article regarding building qt4 apps but I haven't seen anything anywhere about building qt5 from source with Yocto/bitbake:
    https://wiki.yoctoproject.org/wiki/Creating_a_recipe_for_a_Qt_application



  • Actually after examining it closer, it looks like maybe I was mistaken that they are being built. The recipes are relying on inheriting the "qmake5" class via "inherit qmake5."





  • Using this demo application:
    https://github.com/b2open/simpleDemoQt5Quick

    I have this example recipe, which I use to validate Yocto Project images with Qt5.

    demo-b2clock_1.0.bb

    SUMMARY = "Application Qt5 demo using Qt5 with QtQuick2"
    AUTHOR = "Cleiton Bueno"
    DESCRIPTION = " \
                   Application development in Qt5 with QtQuick2 to simple test \
                   instalation framework Qt5 \
                   "
    HOMEPAGE = "http://www.b2open.com"
    
    LICENSE = "( Apache-2.0 & BSD )"
    LIC_FILES_CHKSUM = "file://LICENSE;md5=86d3f3a95c324c9479bd8986968f4327"
    
    DEPENDS += "qtbase qtquickcontrols2"
    
    SRC_URI = "\
               git://github.com/b2open/simpleDemoQt5Quick.git;branch=master \
        "
    SRCREV = "dc1af35cabe6e8efb302da338e22c64f38e639d3"
    
    S = "${WORKDIR}/git"
    
    COMPATIBLE_MACHINE = "mx6"
    
    do_install_append() {
      install -d ${D}/opt/b2open/bin/
    }
    
    FILES_${PN} += "/opt/b2open/bin"
    
    inherit qmake5
    

    Cleiton Bueno

    Blog | Linkedin | B2Open



  • Its working fine. Thanks


Log in to reply