Nominate our 2022 Qt Champions!

Broken applications after Qt Cross-compilation for Raspberry Pi

  • I cross-compiled Qt 5.10.1 for my Raspberry Pi 3 B+, but I've noticed that some applications no longer open from the applications menu. For instance, when I try to open VLC Media Player, I see a tab for it appear and immediately disappear. Another application that won't open is qpdfview. When I attempt to open it from the terminal, I get the following message:

    This application failed to start because it could not find or load the Qt platform plugin "xcb"
    in "".

    I can execute my own Qt applications using xcb, so I'm not sure what's going on here. I'm wondering if something is wrong with EGL and GLES libraries. When I run the configure script for Qt, it says "no" to "EGL on X11".

  • Lifetime Qt Champion

    @Lashc Where did you install your cross compiled Qt on Raspberry Pi?
    It sounds like you overwritten your existing Qt there, or installed the cross compiled Qt in some location which is searched by default by the system when looking for libraries.

  • @jsulm I installed it in /usr/local/qt5pi. I did run the following commands, which may have caused the issue: “echo /usr/local/qt5pi/lib | sudo tee /etc/” and “sudo ldconfig” (following a tutorial).

  • Lifetime Qt Champion

    @Lashc Is there a reason why you did that?

  • @jsulm No, not particularly. I’ve mainly been following some tutorials, and that’s where those steps came from. Is the installation folder fine? Do I need to omit those two commands from my cross-compilation process? I don’t need to replace the existing Qt files on my Raspberry Pi. I just need them for the particular Qt application I’m developing. I don’t care if existing applications use the Qt version that comes with Raspbian.

  • Lifetime Qt Champion

    @Lashc The folder is fine. You should not do this "hack".

  • @jsulm I flashed my Raspberry Pi’s SD card and cross-compiled Qt again for it without the “hack”, and everything works fine! Thanks for finding that mistake!

Log in to reply