Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Qt Cross Raspi - How to add support for libinput and fontconfig?
Forum Updated to NodeBB v4.3 + New Features

Qt Cross Raspi - How to add support for libinput and fontconfig?

Scheduled Pinned Locked Moved Solved Mobile and Embedded
2 Posts 1 Posters 1.0k 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.
  • R Offline
    R Offline
    rrd0
    wrote on last edited by rrd0
    #1

    I'm trying to cross compile Qt for Raspberry Pi.

    I'm in the step of running ./configure to prepare the files for build:

    ./configure -release -opengl es2 -device linux-rasp-pi3-g++ \
    -device-option CROSS_COMPILE=~/qt-cross-raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- \
    -sysroot ~/qt-cross-raspi/sysroot -opensource -confirm-license -make libs \
    -prefix /usr/local/qt5 -extprefix ~/qt-cross-raspi/qt5raspi \
    -hostprefix ~/qt-cross-raspi/qt5 -v -no-use-gold-linker
    

    But, as you can see in the excerpt of configure.summary below, libinput and fontconfig are disabled.

    Build options:
    Qt Gui:
      ...
      FreeType ............................... yes
        Using system FreeType ................ no
      ...
      Fontconfig ............................. no
    Features used by QPA backends:
      ...
      libinput ............................... no
      ...
    

    If I add the options -fontconfig -libinput to configure, then it adds the following to the summary:

    ERROR: Feature 'fontconfig' was enabled, but the pre-condition '!config.win32 && features.system-freetype && libs.fontconfig' failed.
    
    ERROR: Feature 'libinput' was enabled, but the pre-condition 'features.libudev && libs.libinput' failed.
    

    Rasbian already have the following freetype, fontconfig and libinput packages installed:

    libfreetype6-dev is already the newest version (2.9.1-3).
    fontconfig is already the newest version (2.13.1-2).
    libinput-bin is already the newest version (1.12.6-2).
    libinput-dev is already the newest version (1.12.6-2).
    libinput10 is already the newest version (1.12.6-2).
    

    So, I don't know what I'm doing wrong. Are there dependencies I'm missing? I misconfigured something?

    1 Reply Last reply
    0
    • R Offline
      R Offline
      rrd0
      wrote on last edited by
      #2

      The option -force-pkg-config solved my problem.

      First I've needed to unset PKG_CONFIG_PATH, as described in this page.

      Then just ran:

      ./configure -release -opengl es2 -device linux-rasp-pi3-g++ \
      -device-option CROSS_COMPILE=~/qt-cross-raspi/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/arm-linux-gnueabihf- \
      -sysroot ~/qt-cross-raspi/sysroot -opensource -confirm-license -make libs \
      -prefix /usr/local/qt5 -extprefix ~/qt-cross-raspi/qt5raspi \
      -hostprefix ~/qt-cross-raspi/qt5 -v -no-use-gold-linker -force-pkg-config
      

      And configure.summary now shows fontconfig and libinput enabled:

      Build options:
      Qt Gui:
        ...
        FreeType ............................... yes
          Using system FreeType ................ yes
        ...
        Fontconfig ............................. yes
      Features used by QPA backends:
        ...
        libinput ............................... yes
        ...
      
      1 Reply Last reply
      0

      • Login

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