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

Cannot find pkg-config



  • Hello
    I am trying to build Qt5.9.9 with qtwebengine. I compiled it on Ubantu 16.04 with arm-linux-gnueabihf and my target platform is I.MX6.
    I cross compiled Qt successfully but I found all of lib files releate to qtwebengine missed. So I used the following instruct:
    cd /qt-everywhere-opensource-src-5.9.9/qtwebengine
    sudo /opt/Qt5.9.9/bin/qmake
    and encountered the following message:
    pkg-config is required
    QtWebEngine will not be built.
    But I have confirmed that pkg-config was already installed on my host computer, which could be found in PATH. Is there any wrong during my complitation ?
    Besides, Is there any package shall be installed before I compile qtwebengine, such as ffmpeg, Opus?


  • Qt Champions 2019

    @Hupe Some notes:
    Why do you put Qt source code into a subdirectory in root?! Put it in your home directory.
    Then there will be no need for sudo.
    Also, you should use shadow builds: do not build inside the source code directory, but from a dedicated build directory.

    Is /opt/Qt5.9.9/bin/qmake you cross compiled Qt?
    Can't you use a more recent version of Qt?



  • @jsulm Thanks for attention
    I put Qt source in /matinal/Qt/qt-everywhere-opensource-src-5.9.9/qtwebengineuse, will the directory influcence complitation?
    I add -prefix to ./configure in Qt source code to install cross compiled Qt in /opt/Qt5.9.9.
    At first I am trying to run an executable program built with Qt5.6.3 which required qtwebengine. And it complained that libQt5webenginexxx.so cannot be found. So I attempt to cross compile qtwebengine5.6.3 but encountered many erros about including wrong header file directory . I am not sure whether the version of Qt will influence the performability of my executable program, and Qt5.9.9 is the the closest version I could find.


  • Qt Champions 2019

    @Hupe said in Cannot find pkg-config:

    I put Qt source in /matinal/Qt/qt-everywhere-opensource-src-5.9.9/qtwebengineuse

    Why not in your home directory?
    If you're the only one who uses Qt on that machine you can simply put sources in your home directory.

    It looks like you're cross compiling, right? In that case you should have a sysroot and you need to check whether pkg-config is there.



  • @jsulm Maybe some foible to create directory.
    Yes , I am cross compiling. I have no idea about the concept of sysroot. Do you mean that I should sync the filesystem on my ARM board to my host computer?Besides should pkg-config be installed in my ARM board instead of my host computer?(Host computer means the computer I used to cross compile, whose architecture is x86. I am not sure whether my expression about host computer is correct since it refers to compiling computer by somebody while to target computer by others. )


  • Qt Champions 2019

    @Hupe said in Cannot find pkg-config:

    Do you mean that I should sync the filesystem on my ARM board to my host computer?

    Yes

    "Besides should pkg-config be installed in my ARM board instead of my host computer?" - also yes.

    "I am not sure whether my expression about host computer is correct" - it is, it's the machine where you cross compile.


Log in to reply