Russian Qt Forum
Ноябрь 25, 2024, 06:19 *
Добро пожаловать, Гость. Пожалуйста, войдите или зарегистрируйтесь.
Вам не пришло письмо с кодом активации?

Войти
 
  Начало   Форум  WIKI (Вики)FAQ Помощь Поиск Войти Регистрация  

Страниц: [1]   Вниз
  Печать  
Автор Тема: Could not load the Qt platform plugin "eglfs"  (Прочитано 7925 раз)
juvf
Программист
*****
Offline Offline

Сообщений: 570


Просмотр профиля
« : Декабрь 20, 2021, 09:33 »

Есть железка на базе imx6 (таргет) + linux.

На хосте с помощью кросскомпилятора для этой железки собрал Qt5.15.
с помощью полученного qmake собрал хеловорд на qml (testQml).
залил  testQml на таргет - запустил.

немного поругалась, на библиотеки Qt. Положил рядом с бинарем недостающие бибиотеки/плагины, добавил переменные

Цитировать
export LD_LIBRARY_PATH=/home/root/work/testQml
export QT_QPA_PLATFORM_PLUGIN_PATH=/home/root/work/testQml/plugins/platforms
export QT_PLUGIN_PATH=/home/root/work/testQml/plugins

запускаю приложение, получаю вот такой выхлоп

Цитировать
root@imx6qsabresd:~/work/testQml# ./testQml
qt.qpa.plugin: Could not load the Qt platform plugin "eglfs" in "/home/root/work/testQml/plugins/platforms" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs (from /home/root/work/testQml/plugins/platforms), linuxfb (from /home/root/work/testQml/plugins/platforms), minimal (from /home/root/work/testQml/plugins/platforms), minimalegl (from /home/root/work/testQml/plugins/platforms), offscreen (from /home/root/work/testQml/plugins/platforms), vnc (from /home/root/work/testQml/plugins/platforms), webgl (from /home/root/work/testQml/plugins/platforms), xcb (from /home/root/work/testQml/plugins/platforms), eglfs, linuxfb, minimal, minimalegl, offscreen, vnc, webgl, xcb.

Aborted
root@imx6qsabresd:~/work/testQml#
Как это исправить?




Записан
Old
Джедай : наставник для всех
*******
Offline Offline

Сообщений: 4350



Просмотр профиля
« Ответ #1 : Декабрь 20, 2021, 09:56 »

А что показывает на железке ldd libqeglfs.so?
Записан
juvf
Программист
*****
Offline Offline

Сообщений: 570


Просмотр профиля
« Ответ #2 : Декабрь 20, 2021, 09:58 »

А что показывает на железке ldd libqeglfs.so?

Цитировать
root@imx6qsabresd:~/work/testQml# ldd libqeglfs.so
ldd: ./libqeglfs.so: No such file or directory
root@imx6qsabresd:~/work/testQml# ldd testQml
        linux-vdso.so.1 (0x7eaf8000)
        libQt5Quick.so.5 => /home/root/work/testQml/libQt5Quick.so.5 (0x76ab3000)
        libQt5Gui.so.5 => /home/root/work/testQml/libQt5Gui.so.5 (0x76563000)
        libQt5QmlModels.so.5 => /home/root/work/testQml/libQt5QmlModels.so.5 (0x764ed000)
        libQt5Qml.so.5 => /home/root/work/testQml/libQt5Qml.so.5 (0x76112000)
        libQt5Network.so.5 => /home/root/work/testQml/libQt5Network.so.5 (0x75fcf000)
        libQt5Core.so.5 => /home/root/work/testQml/libQt5Core.so.5 (0x75a4c000)
        libGLESv2.so.2 => /usr/lib/libGLESv2.so.2 (0x75953000)
        libEGL.so.1 => /usr/lib/libEGL.so.1 (0x75934000)
        libpthread.so.0 => /lib/libpthread.so.0 (0x7590a000)
        libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x757c9000)
        libm.so.6 => /lib/libm.so.6 (0x7574b000)
        libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x7571f000)
        libc.so.6 => /lib/libc.so.6 (0x755e5000)
        libpng16.so.16 => /usr/lib/libpng16.so.16 (0x755ac000)
        libz.so.1 => /lib/libz.so.1 (0x7558a000)
        librt.so.1 => /lib/librt.so.1 (0x75573000)
        libdl.so.2 => /lib/libdl.so.2 (0x75560000)
        libicui18n.so.56 => /usr/lib/libicui18n.so.56 (0x75364000)
        libicuuc.so.56 => /usr/lib/libicuuc.so.56 (0x75211000)
        libicudata.so.56 => /usr/lib/libicudata.so.56 (0x73a1e000)
        libgthread-2.0.so.0 => /usr/lib/libgthread-2.0.so.0 (0x73a0d000)
        libglib-2.0.so.0 => /usr/lib/libglib-2.0.so.0 (0x7390f000)
        /lib/ld-linux-armhf.so.3 (0x76ed5000)
        libGAL.so => /usr/lib/libGAL.so (0x7380b000)
        libVSC.so => /usr/lib/libVSC.so (0x73748000)
        libX11.so.6 => /usr/lib/libX11.so.6 (0x7362d000)
        libpcre.so.1 => /usr/lib/libpcre.so.1 (0x735df000)
        libXdamage.so.1 => /usr/lib/libXdamage.so.1 (0x735cd000)
        libXfixes.so.3 => /usr/lib/libXfixes.so.3 (0x735b9000)
        libXext.so.6 => /usr/lib/libXext.so.6 (0x7359a000)
        libxcb.so.1 => /usr/lib/libxcb.so.1 (0x73574000)
        libXau.so.6 => /usr/lib/libXau.so.6 (0x73562000)
        libXdmcp.so.6 => /usr/lib/libXdmcp.so.6 (0x7354e000)
root@imx6qsabresd:~/work/testQml#
Записан
juvf
Программист
*****
Offline Offline

Сообщений: 570


Просмотр профиля
« Ответ #3 : Декабрь 20, 2021, 10:36 »

вот ещё.... убрал лишние плагины, добавил export QT_DEBUG_PLUGINS=1, получил...



Цитировать
root@imx6qsabresd:~/work/testQml# ./testQml
QFactoryLoader::QFactoryLoader() checking directory path "/home/root/work/testQml/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/plugins/platforms/libqeglfs.so"
Found metadata in lib /home/root/work/testQml/plugins/platforms/libqeglfs.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "eglfs"
        ]
    },
    "archreq": 0,
    "className": "QEglFSIntegrationPlugin",
    "debug": false,
    "version": 331520
}


Got keys from plugin meta data ("eglfs")
QFactoryLoader::QFactoryLoader() checking directory path "/home/root/work/testQml/plugins" ...
QFactoryLoader::QFactoryLoader() checking directory path "/home/root/work/testQml" ...
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Core.la"
QElfParser: '/home/root/work/testQml/libQt5Core.la' is not an ELF object
"'/home/root/work/testQml/libQt5Core.la' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Core.prl"
QElfParser: '/home/root/work/testQml/libQt5Core.prl' is not an ELF object
"'/home/root/work/testQml/libQt5Core.prl' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Core.so"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Core.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Core.so.5"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Core.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Core.so.5.15"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Core.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Core.so.5.15.2"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Core.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Gui.la"
QElfParser: '/home/root/work/testQml/libQt5Gui.la' is not an ELF object
"'/home/root/work/testQml/libQt5Gui.la' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Gui.prl"
QElfParser: '/home/root/work/testQml/libQt5Gui.prl' is not an ELF object
"'/home/root/work/testQml/libQt5Gui.prl' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Gui.so"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Gui.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Gui.so.5"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Gui.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Gui.so.5.15"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Gui.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Gui.so.5.15.2"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Gui.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Network.la"
QElfParser: '/home/root/work/testQml/libQt5Network.la' is not an ELF object
"'/home/root/work/testQml/libQt5Network.la' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Network.prl"
QElfParser: '/home/root/work/testQml/libQt5Network.prl' is not an ELF object
"'/home/root/work/testQml/libQt5Network.prl' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Network.so"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Network.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Network.so.5"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Network.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Network.so.5.15"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Network.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Network.so.5.15.2"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Network.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Qml.la"
QElfParser: '/home/root/work/testQml/libQt5Qml.la' is not an ELF object
"'/home/root/work/testQml/libQt5Qml.la' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Qml.prl"
QElfParser: '/home/root/work/testQml/libQt5Qml.prl' is not an ELF object
"'/home/root/work/testQml/libQt5Qml.prl' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Qml.so"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Qml.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Qml.so.5"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Qml.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Qml.so.5.15"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Qml.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Qml.so.5.15.2"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Qml.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5QmlModels.la"
QElfParser: '/home/root/work/testQml/libQt5QmlModels.la' is not an ELF object
"'/home/root/work/testQml/libQt5QmlModels.la' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5QmlModels.prl"
QElfParser: '/home/root/work/testQml/libQt5QmlModels.prl' is not an ELF object
"'/home/root/work/testQml/libQt5QmlModels.prl' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5QmlModels.so"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5QmlModels.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5QmlModels.so.5"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5QmlModels.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5QmlModels.so.5.15"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5QmlModels.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5QmlModels.so.5.15.2"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5QmlModels.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Quick.la"
QElfParser: '/home/root/work/testQml/libQt5Quick.la' is not an ELF object
"'/home/root/work/testQml/libQt5Quick.la' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Quick.prl"
QElfParser: '/home/root/work/testQml/libQt5Quick.prl' is not an ELF object
"'/home/root/work/testQml/libQt5Quick.prl' is not an ELF object"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Quick.so"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Quick.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Quick.so.5"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Quick.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Quick.so.5.15"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Quick.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/libQt5Quick.so.5.15.2"
"Failed to extract plugin meta data from '/home/root/work/testQml/libQt5Quick.so.5.15.2'"
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/testQml"
"Failed to extract plugin meta data from '/home/root/work/testQml/testQml'"
         not a plugin
QFactoryLoader::QFactoryLoader() checking directory path "/home/root/work/testQml/plugins/platforms/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/home/root/work/testQml/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/home/root/work/testQml/plugins/platforms/libqeglfs.so"
Got keys from plugin meta data ("eglfs")
QFactoryLoader::QFactoryLoader() checking directory path "/home/root/work/testQml/platforms" ...
Cannot load library /home/root/work/testQml/plugins/platforms/libqeglfs.so: (libQt5EglFSDeviceIntegration.so.5: cannot open shared object file: No such file or directory)
QLibraryPrivate::loadPlugin failed on "/home/root/work/testQml/plugins/platforms/libqeglfs.so" : "Cannot load library /home/root/work/testQml/plugins/platforms/libqeglfs.so: (libQt5EglFSDeviceIntegration.so.5: cannot open shared object file: No such file or directory)"
qt.qpa.plugin: Could not load the Qt platform plugin "eglfs" in "/home/root/work/testQml/plugins/platforms" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs (from /home/root/work/testQml/plugins/platforms), eglfs.

Aborted
Не могу понять что пошло не так и как это исправить?
Записан
Old
Джедай : наставник для всех
*******
Offline Offline

Сообщений: 4350



Просмотр профиля
« Ответ #4 : Декабрь 20, 2021, 11:52 »

Cannot load library /home/root/work/testQml/plugins/platforms/libqeglfs.so: (libQt5EglFSDeviceIntegration.so.5: cannot open shared object file: No such file or directory)

Записан
kuzulis
Джедай : наставник для всех
*******
Offline Offline

Сообщений: 2812


Просмотр профиля
« Ответ #5 : Декабрь 20, 2021, 13:50 »

Могу дать совет - собирать BSP через Yocto. Иначе - все тлен. ))
Записан

ArchLinux x86_64 / Win10 64 bit
juvf
Программист
*****
Offline Offline

Сообщений: 570


Просмотр профиля
« Ответ #6 : Декабрь 20, 2021, 15:27 »

Могу дать совет - собирать BSP через Yocto. Иначе - все тлен. ))
слишком высокий порог вхождения в Yocto. Попробовал buildroot, но готового конфига под мой таргет нет. Собрал своё ядро/дерево/рутфс - частично работает. Надо ядро патчить.... драйвера править.... есть уже собранная пропатченая рабочая сборка линукса с кросстулчейном.... пробую к ней Qt свежий прикрутить. 

Записан
juvf
Программист
*****
Offline Offline

Сообщений: 570


Просмотр профиля
« Ответ #7 : Декабрь 21, 2021, 08:09 »

добавил все либы/плуги.... получаю такой вывод при запуске приложения

Цитировать
QFactoryLoader::QFactoryLoader() checking directory path "/home/root/work/testQml/egldeviceintegrations" ...
loaded library "/home/root/work/testQml/plugins/egldeviceintegrations/libqeglfs-emu-integration.so"
EGL library doesn't support Emulator extensions
./start: line 6:  2405 Aborted                 ./testQml

Ну хорошо.... ещё раз запускаю c0nfigure на хосте, которым собирал Qt

Цитировать
./configure -confirm-license -v -release \
-prefix ~/tools/imx6/qt5_15_J \
-nomake examples -opensource \
-no-pch -opengl es2 -egl -eglfs \
-device imx6-g++ -no-harfbuzz -no-gstreamer \
-device-option CROSS_COMPILE=~/toolchainChine/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi- \
       -sysroot ~/toolchainChine/sysroots/cortexa9hf-neon-poky-linux-gnueabi

получаю это

Цитировать
Qt Gui:
...
  EGL .................................... yes
  OpenVG ................................. no
  OpenGL:
    Desktop OpenGL ....................... no
    OpenGL ES 2.0 ........................ yes
    OpenGL ES 3.0 ........................ yes
    OpenGL ES 3.1 ........................ no
    OpenGL ES 3.2 ........................ no
  Vulkan ................................. no
  Session Management ..................... yes
QPA backends:
  DirectFB ............................... no
  EGLFS .................................. yes
  EGLFS details:
    EGLFS OpenWFD ........................ no
    EGLFS i.Mx6 .......................... no
    EGLFS i.Mx6 Wayland .................. no
    EGLFS RCAR ........................... no
    EGLFS EGLDevice ...................... no
    EGLFS GBM ............................ no
    EGLFS VSP2 ........................... no
    EGLFS Mali ........................... no
    EGLFS Raspberry Pi ................... no
    EGLFS X11 ............................ no
  LinuxFB ................................ yes
  VNC .................................... yes
  XCB:
    Using system-provided xcb-xinput ..... no
    Native painting (experimental) ....... no
    GL integrations:
      GLX Plugin ......................... no
      EGL-X11 Plugin ..................... no
Вроде EGLFS yes, но моя платформа imx6, почему-то для неё EGLFS i.Mx6 no. От куда берётся QPA backends? Из sysroot?

ps Приложения на виджетах кросскомпилированное с новым Qt5.15 запускаются на таргете нормально,  а QML-ые приложения не хотят.

« Последнее редактирование: Декабрь 21, 2021, 08:50 от juvf » Записан
Страниц: [1]   Вверх
  Печать  
 
Перейти в:  


Страница сгенерирована за 0.057 секунд. Запросов: 22.