libqxcb.so not able to find Qt libraries
-
I have deployed a Qt6 based application on Linux (CentOS7). My application executable is in linux/bin directory and libraries are in linux/lib/qt directory
Trying to run this exe gives me the following errorqt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" 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: xcb.
I investigated and found that libqxcb.so is not able to find Qt libraries. ldd libqxcb.so gives the following result
linux-vdso.so.1 => (0x00007ffe86c7e000) libQt6XcbQpa.so.6 => not found libxkbcommon-x11.so.0 => /lib64/libxkbcommon-x11.so.0 (0x00007f17002ee000) libxkbcommon.so.0 => /lib64/libxkbcommon.so.0 (0x00007f17000ae000) libxcb-icccm.so.4 => /lib64/libxcb-icccm.so.4 (0x00007f16ffea9000) libxcb-image.so.0 => /lib64/libxcb-image.so.0 (0x00007f16ffca4000) libxcb-keysyms.so.1 => /lib64/libxcb-keysyms.so.1 (0x00007f16ffaa1000) libxcb-randr.so.0 => /lib64/libxcb-randr.so.0 (0x00007f16ff891000) libxcb-render-util.so.0 => /lib64/libxcb-render-util.so.0 (0x00007f16ff68d000) libxcb-shm.so.0 => /lib64/libxcb-shm.so.0 (0x00007f16ff489000) libxcb-sync.so.1 => /lib64/libxcb-sync.so.1 (0x00007f16ff282000) libxcb-xfixes.so.0 => /lib64/libxcb-xfixes.so.0 (0x00007f16ff07a000) libxcb-render.so.0 => /lib64/libxcb-render.so.0 (0x00007f16fee6c000) libxcb-shape.so.0 => /lib64/libxcb-shape.so.0 (0x00007f16fec68000) libxcb-xkb.so.1 => /lib64/libxcb-xkb.so.1 (0x00007f16fea4c000) libxcb.so.1 => /lib64/libxcb.so.1 (0x00007f16fe824000) libQt6OpenGL.so.6 => not found libQt6Gui.so.6 => not found libGLX.so.0 => /lib64/libGLX.so.0 (0x00007f16fe5f2000) libOpenGL.so.0 => /lib64/libOpenGL.so.0 (0x00007f16fe3c4000) libQt6Core.so.6 => not found libX11-xcb.so.1 => /lib64/libX11-xcb.so.1 (0x00007f16fe1c2000) libX11.so.6 => /lib64/libX11.so.6 (0x00007f16fde84000) libSM.so.6 => /lib64/libSM.so.6 (0x00007f16fdc7c000) libICE.so.6 => /lib64/libICE.so.6 (0x00007f16fda60000) libdl.so.2 => /lib64/libdl.so.2 (0x00007f16fd85c000) libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f16fd640000) libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007f16fd336000) libm.so.6 => /lib64/libm.so.6 (0x00007f16fd034000) libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f16fce1e000) libc.so.6 => /lib64/libc.so.6 (0x00007f16fca50000) libxcb-util.so.1 => /lib64/libxcb-util.so.1 (0x00007f16fc84a000) libXau.so.6 => /lib64/libXau.so.6 (0x00007f16fc646000) libXext.so.6 => /lib64/libXext.so.6 (0x00007f16fc434000) libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007f16fc17e000) libuuid.so.1 => /lib64/libuuid.so.1 (0x00007f16fbf79000) /lib64/ld-linux-x86-64.so.2 (0x00007f17004f6000)Running export LD_LIBRARY_PATH solves the issue but is there any way to include this information in .pro file itself.
I tried including the following in .pro but it doesn't seem to work
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib/qt'"Am I missing something?
-
I have deployed a Qt6 based application on Linux (CentOS7). My application executable is in linux/bin directory and libraries are in linux/lib/qt directory
Trying to run this exe gives me the following errorqt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" 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: xcb.
I investigated and found that libqxcb.so is not able to find Qt libraries. ldd libqxcb.so gives the following result
linux-vdso.so.1 => (0x00007ffe86c7e000) libQt6XcbQpa.so.6 => not found libxkbcommon-x11.so.0 => /lib64/libxkbcommon-x11.so.0 (0x00007f17002ee000) libxkbcommon.so.0 => /lib64/libxkbcommon.so.0 (0x00007f17000ae000) libxcb-icccm.so.4 => /lib64/libxcb-icccm.so.4 (0x00007f16ffea9000) libxcb-image.so.0 => /lib64/libxcb-image.so.0 (0x00007f16ffca4000) libxcb-keysyms.so.1 => /lib64/libxcb-keysyms.so.1 (0x00007f16ffaa1000) libxcb-randr.so.0 => /lib64/libxcb-randr.so.0 (0x00007f16ff891000) libxcb-render-util.so.0 => /lib64/libxcb-render-util.so.0 (0x00007f16ff68d000) libxcb-shm.so.0 => /lib64/libxcb-shm.so.0 (0x00007f16ff489000) libxcb-sync.so.1 => /lib64/libxcb-sync.so.1 (0x00007f16ff282000) libxcb-xfixes.so.0 => /lib64/libxcb-xfixes.so.0 (0x00007f16ff07a000) libxcb-render.so.0 => /lib64/libxcb-render.so.0 (0x00007f16fee6c000) libxcb-shape.so.0 => /lib64/libxcb-shape.so.0 (0x00007f16fec68000) libxcb-xkb.so.1 => /lib64/libxcb-xkb.so.1 (0x00007f16fea4c000) libxcb.so.1 => /lib64/libxcb.so.1 (0x00007f16fe824000) libQt6OpenGL.so.6 => not found libQt6Gui.so.6 => not found libGLX.so.0 => /lib64/libGLX.so.0 (0x00007f16fe5f2000) libOpenGL.so.0 => /lib64/libOpenGL.so.0 (0x00007f16fe3c4000) libQt6Core.so.6 => not found libX11-xcb.so.1 => /lib64/libX11-xcb.so.1 (0x00007f16fe1c2000) libX11.so.6 => /lib64/libX11.so.6 (0x00007f16fde84000) libSM.so.6 => /lib64/libSM.so.6 (0x00007f16fdc7c000) libICE.so.6 => /lib64/libICE.so.6 (0x00007f16fda60000) libdl.so.2 => /lib64/libdl.so.2 (0x00007f16fd85c000) libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f16fd640000) libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007f16fd336000) libm.so.6 => /lib64/libm.so.6 (0x00007f16fd034000) libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f16fce1e000) libc.so.6 => /lib64/libc.so.6 (0x00007f16fca50000) libxcb-util.so.1 => /lib64/libxcb-util.so.1 (0x00007f16fc84a000) libXau.so.6 => /lib64/libXau.so.6 (0x00007f16fc646000) libXext.so.6 => /lib64/libXext.so.6 (0x00007f16fc434000) libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007f16fc17e000) libuuid.so.1 => /lib64/libuuid.so.1 (0x00007f16fbf79000) /lib64/ld-linux-x86-64.so.2 (0x00007f17004f6000)Running export LD_LIBRARY_PATH solves the issue but is there any way to include this information in .pro file itself.
I tried including the following in .pro but it doesn't seem to work
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib/qt'"Am I missing something?
@nitingera said in libqxcb.so not able to find Qt libraries:
I tried including the following in .pro but it doesn't seem to work
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib/qt'"Those flags set the RUNPATH/RPATH of your executable.
You want to set the RUNPATH/RPATH of libqxcb.so instead. Use
chrpathon libqxcb.so. -
I have deployed a Qt6 based application on Linux (CentOS7). My application executable is in linux/bin directory and libraries are in linux/lib/qt directory
Trying to run this exe gives me the following errorqt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" 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: xcb.
I investigated and found that libqxcb.so is not able to find Qt libraries. ldd libqxcb.so gives the following result
linux-vdso.so.1 => (0x00007ffe86c7e000) libQt6XcbQpa.so.6 => not found libxkbcommon-x11.so.0 => /lib64/libxkbcommon-x11.so.0 (0x00007f17002ee000) libxkbcommon.so.0 => /lib64/libxkbcommon.so.0 (0x00007f17000ae000) libxcb-icccm.so.4 => /lib64/libxcb-icccm.so.4 (0x00007f16ffea9000) libxcb-image.so.0 => /lib64/libxcb-image.so.0 (0x00007f16ffca4000) libxcb-keysyms.so.1 => /lib64/libxcb-keysyms.so.1 (0x00007f16ffaa1000) libxcb-randr.so.0 => /lib64/libxcb-randr.so.0 (0x00007f16ff891000) libxcb-render-util.so.0 => /lib64/libxcb-render-util.so.0 (0x00007f16ff68d000) libxcb-shm.so.0 => /lib64/libxcb-shm.so.0 (0x00007f16ff489000) libxcb-sync.so.1 => /lib64/libxcb-sync.so.1 (0x00007f16ff282000) libxcb-xfixes.so.0 => /lib64/libxcb-xfixes.so.0 (0x00007f16ff07a000) libxcb-render.so.0 => /lib64/libxcb-render.so.0 (0x00007f16fee6c000) libxcb-shape.so.0 => /lib64/libxcb-shape.so.0 (0x00007f16fec68000) libxcb-xkb.so.1 => /lib64/libxcb-xkb.so.1 (0x00007f16fea4c000) libxcb.so.1 => /lib64/libxcb.so.1 (0x00007f16fe824000) libQt6OpenGL.so.6 => not found libQt6Gui.so.6 => not found libGLX.so.0 => /lib64/libGLX.so.0 (0x00007f16fe5f2000) libOpenGL.so.0 => /lib64/libOpenGL.so.0 (0x00007f16fe3c4000) libQt6Core.so.6 => not found libX11-xcb.so.1 => /lib64/libX11-xcb.so.1 (0x00007f16fe1c2000) libX11.so.6 => /lib64/libX11.so.6 (0x00007f16fde84000) libSM.so.6 => /lib64/libSM.so.6 (0x00007f16fdc7c000) libICE.so.6 => /lib64/libICE.so.6 (0x00007f16fda60000) libdl.so.2 => /lib64/libdl.so.2 (0x00007f16fd85c000) libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f16fd640000) libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007f16fd336000) libm.so.6 => /lib64/libm.so.6 (0x00007f16fd034000) libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f16fce1e000) libc.so.6 => /lib64/libc.so.6 (0x00007f16fca50000) libxcb-util.so.1 => /lib64/libxcb-util.so.1 (0x00007f16fc84a000) libXau.so.6 => /lib64/libXau.so.6 (0x00007f16fc646000) libXext.so.6 => /lib64/libXext.so.6 (0x00007f16fc434000) libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007f16fc17e000) libuuid.so.1 => /lib64/libuuid.so.1 (0x00007f16fbf79000) /lib64/ld-linux-x86-64.so.2 (0x00007f17004f6000)Running export LD_LIBRARY_PATH solves the issue but is there any way to include this information in .pro file itself.
I tried including the following in .pro but it doesn't seem to work
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib/qt'"Am I missing something?
This post is deleted! -
I have deployed a Qt6 based application on Linux (CentOS7). My application executable is in linux/bin directory and libraries are in linux/lib/qt directory
Trying to run this exe gives me the following errorqt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" 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: xcb.
I investigated and found that libqxcb.so is not able to find Qt libraries. ldd libqxcb.so gives the following result
linux-vdso.so.1 => (0x00007ffe86c7e000) libQt6XcbQpa.so.6 => not found libxkbcommon-x11.so.0 => /lib64/libxkbcommon-x11.so.0 (0x00007f17002ee000) libxkbcommon.so.0 => /lib64/libxkbcommon.so.0 (0x00007f17000ae000) libxcb-icccm.so.4 => /lib64/libxcb-icccm.so.4 (0x00007f16ffea9000) libxcb-image.so.0 => /lib64/libxcb-image.so.0 (0x00007f16ffca4000) libxcb-keysyms.so.1 => /lib64/libxcb-keysyms.so.1 (0x00007f16ffaa1000) libxcb-randr.so.0 => /lib64/libxcb-randr.so.0 (0x00007f16ff891000) libxcb-render-util.so.0 => /lib64/libxcb-render-util.so.0 (0x00007f16ff68d000) libxcb-shm.so.0 => /lib64/libxcb-shm.so.0 (0x00007f16ff489000) libxcb-sync.so.1 => /lib64/libxcb-sync.so.1 (0x00007f16ff282000) libxcb-xfixes.so.0 => /lib64/libxcb-xfixes.so.0 (0x00007f16ff07a000) libxcb-render.so.0 => /lib64/libxcb-render.so.0 (0x00007f16fee6c000) libxcb-shape.so.0 => /lib64/libxcb-shape.so.0 (0x00007f16fec68000) libxcb-xkb.so.1 => /lib64/libxcb-xkb.so.1 (0x00007f16fea4c000) libxcb.so.1 => /lib64/libxcb.so.1 (0x00007f16fe824000) libQt6OpenGL.so.6 => not found libQt6Gui.so.6 => not found libGLX.so.0 => /lib64/libGLX.so.0 (0x00007f16fe5f2000) libOpenGL.so.0 => /lib64/libOpenGL.so.0 (0x00007f16fe3c4000) libQt6Core.so.6 => not found libX11-xcb.so.1 => /lib64/libX11-xcb.so.1 (0x00007f16fe1c2000) libX11.so.6 => /lib64/libX11.so.6 (0x00007f16fde84000) libSM.so.6 => /lib64/libSM.so.6 (0x00007f16fdc7c000) libICE.so.6 => /lib64/libICE.so.6 (0x00007f16fda60000) libdl.so.2 => /lib64/libdl.so.2 (0x00007f16fd85c000) libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f16fd640000) libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007f16fd336000) libm.so.6 => /lib64/libm.so.6 (0x00007f16fd034000) libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f16fce1e000) libc.so.6 => /lib64/libc.so.6 (0x00007f16fca50000) libxcb-util.so.1 => /lib64/libxcb-util.so.1 (0x00007f16fc84a000) libXau.so.6 => /lib64/libXau.so.6 (0x00007f16fc646000) libXext.so.6 => /lib64/libXext.so.6 (0x00007f16fc434000) libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007f16fc17e000) libuuid.so.1 => /lib64/libuuid.so.1 (0x00007f16fbf79000) /lib64/ld-linux-x86-64.so.2 (0x00007f17004f6000)Running export LD_LIBRARY_PATH solves the issue but is there any way to include this information in .pro file itself.
I tried including the following in .pro but it doesn't seem to work
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib/qt'"Am I missing something?
@nitingera said in libqxcb.so not able to find Qt libraries:
I tried including the following in .pro but it doesn't seem to work
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib/qt'"Those flags set the RUNPATH/RPATH of your executable.
You want to set the RUNPATH/RPATH of libqxcb.so instead. Use
chrpathon libqxcb.so. -
@nitingera said in libqxcb.so not able to find Qt libraries:
I tried including the following in .pro but it doesn't seem to work
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib'"
QMAKE_LFLAGS += -Wl,-rpath,"'$$ORIGIN/../lib/qt'"Those flags set the RUNPATH/RPATH of your executable.
You want to set the RUNPATH/RPATH of libqxcb.so instead. Use
chrpathon libqxcb.so. -
@JKSH chrpath is a separate package that needs to be installed. Will I need it on the client system as well?
@nitingera said in libqxcb.so not able to find Qt libraries:
chrpath is a separate package that needs to be installed. Will I need it on the client system as well?
Install chrpath on your development PC to modify the library, then give your clients the modified library.
Your clients don't need chrpath.
-
@nitingera said in libqxcb.so not able to find Qt libraries:
chrpath is a separate package that needs to be installed. Will I need it on the client system as well?
Install chrpath on your development PC to modify the library, then give your clients the modified library.
Your clients don't need chrpath.
-
@nitingera said in libqxcb.so not able to find Qt libraries:
chrpath is a separate package that needs to be installed. Will I need it on the client system as well?
Install chrpath on your development PC to modify the library, then give your clients the modified library.
Your clients don't need chrpath.