在 imx6ull Pro 开发板上运行 Qt 程序报 “没找到平台插件 eglfs”

具体报错信息如下:
qt.qpa.plugin: Could not find the Qt platform plugin “eglfs” in “”
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: linuxfb, minimal, offscreen, vnc.

Aborted

我已经重新编译了 Buildroot_2020.02.x,并将生成的镜像烧录到了开发板。
然后我这边查了一下 /usr/lib/qt/plugins/platforms 路径,确实没有 eglfs。

先执行:
export QT_QPA_GENERIC_PLUGINS=tslib:/dev/input/event1
export QT_QPA_PLATFORM=linuxfb:fb=/dev/fb0
export QT_QPA_FONTDIR=/usr/lib/fonts/

再运行你的QT程序