Build Qt6 from Source, xcb issue
-
Re: [Built Qt6 from sources](problem with xcb plugin)
I have built Qt6.2 from source on CentOS 7.6 with gcc 10.2.1 (devtoolset-10) with the following configure options
./configure -developer-build -nomake tests -nomake examples -qt-zlib -qt-libpng -qt-libjpeg -opengl -bundled-xcb-xinputThe config summary is as follows
Building for: linux-g++ (x86_64, CPU features: mmx sse sse2) Compiler: gcc 10.2.1 Build options: Mode ................................... debug Optimize debug build ................... no Fully optimize release builds (-O3) .... no Building shared libraries .............. yes Using C standard ....................... C11 Using C++ standard ..................... C++17 Using ccache ........................... no Using new DTAGS ........................ yes Generating GDB index ................... no Relocatable ............................ yes Using precompiled headers .............. yes Using LTCG ............................. no Target compiler supports: SSE .................................. SSE2 SSE3 SSSE3 SSE4.1 SSE4.2 AVX .................................. AVX AVX2 AVX512 ............................... F ER CD PF DQ BW VL IFMA VBMI Other x86 ............................ AES F16C RDRAND SHA Intrinsics without compiler architecture option yes Sanitizers: Addresses ............................ no Threads .............................. no Memory ............................... no Fuzzer (instrumentation only) ........ no Undefined ............................ no Build parts ............................ libs tools Qt modules and options: Qt Concurrent .......................... yes Qt D-Bus ............................... yes Qt D-Bus directly linked to libdbus .... no Qt Gui ................................. yes Qt Network ............................. yes Qt Sql ................................. yes Qt Testlib ............................. yes Qt Widgets ............................. yes Qt Xml ................................. yes Support enabled for: Using pkg-config ....................... yes udev ................................... yes Using system zlib ...................... no Zstandard support ...................... no Thread support ......................... yes Common build options: Linker can resolve circular dependencies yes Qt Core: backtrace .............................. yes DoubleConversion ....................... yes Using system DoubleConversion ........ no GLib ................................... yes ICU .................................... yes Using system libb2 ..................... no Built-in copy of the MIME database ..... yes Tracing backend ........................ <none> Logging backends: journald ............................. no syslog ............................... no slog2 ................................ no PCRE2 .................................. yes Using system PCRE2 ................... no CLONE_PIDFD support in forkfd .......... yes Qt Sql: SQL item models ........................ yes Qt Network: getifaddrs() ........................... yes IPv6 ifname ............................ yes libproxy ............................... no Linux AF_NETLINK ....................... yes OpenSSL ................................ yes Qt directly linked to OpenSSL ........ yes OpenSSL 1.1 ............................ yes DTLS ................................... yes OCSP-stapling .......................... yes SCTP ................................... no Use system proxies ..................... yes GSSAPI ................................. yes Brotli Decompression Support ........... no Qt Gui: Accessibility .......................... yes FreeType ............................... yes Using system FreeType ................ yes HarfBuzz ............................... yes Using system HarfBuzz ................ no Fontconfig ............................. yes Image formats: GIF .................................. yes ICO .................................. yes JPEG ................................. yes Using system libjpeg ............... no PNG .................................. yes Using system libpng ................ no Text formats: HtmlParser ........................... yes CssParser ............................ yes OdfWriter ............................ yes MarkdownReader ....................... yes Using system libmd4c ............... no MarkdownWriter ....................... yes EGL .................................... yes OpenVG ................................. no OpenGL: Desktop OpenGL ....................... yes OpenGL ES 2.0 ........................ no OpenGL ES 3.0 ........................ no OpenGL ES 3.1 ........................ no OpenGL ES 3.2 ........................ no Vulkan ................................. no Session Management ..................... yes Features used by QPA backends: evdev .................................. yes libinput ............................... no INTEGRITY HID .......................... no mtdev .................................. no tslib .................................. no xkbcommon .............................. yes X11 specific: XLib ................................. yes XCB Xlib ............................. yes EGL on X11 ........................... yes xkbcommon-x11 ........................ yes xcb-sm ............................... no 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 ...................... yes EGLFS GBM ............................ yes EGLFS VSP2 ........................... no EGLFS Mali ........................... no EGLFS Raspberry Pi ................... no EGLFS X11 ............................ yes LinuxFB ................................ yes VNC .................................... yes VK_KHR_display ......................... no QNX: lgmon ................................ no IMF .................................. no XCB: Using system-provided xcb-xinput ..... no GL integrations: GLX Plugin ......................... no XCB GLX .......................... no EGL-X11 Plugin ..................... no Windows: Direct 2D ............................ no Direct 2D 1.1 ........................ no DirectWrite .......................... no DirectWrite 3 ........................ no Qt Widgets: GTK+ ................................... yes Styles ................................. Fusion Windows Qt Testlib: Tester for item models ................. yes Qt PrintSupport: CUPS ................................... yes Qt Sql Drivers: DB2 (IBM) .............................. no InterBase .............................. no MySql .................................. no OCI (Oracle) ........................... no ODBC ................................... yes PostgreSQL ............................. yes SQLite ................................. yes Using system provided SQLite ......... no Core tools: qmake tool ............................. yes Qt QML: QML network support .................... yes QML debugging and profiling support .... yes QML just-in-time compiler .............. yes QML sequence object .................... yes QML XML http request ................... yes QML Locale ............................. yes Qt QML Models: QML list model ......................... yes QML delegate model ..................... yes Qt Quick: AnimatedImage item ..................... yes Canvas item ............................ yes Support for Qt Quick Designer .......... yes Flipable item .......................... yes GridView item .......................... yes ListView item .......................... yes TableView item ......................... yes Path support ........................... yes PathView item .......................... yes Positioner items ....................... yes Repeater item .......................... yes ShaderEffect item ...................... yes Sprite item ............................ yes Qt 3D: Assimp ................................. yes System Assimp .......................... no Use SSE2 instructions .................. yes Use AVX2 instructions .................. no Aspects: Render aspect ........................ yes Input aspect ......................... yes Logic aspect ......................... yes Animation aspect ..................... yes Extras aspect ........................ yes Qt 3D APIs: Vulkan ................................. no Qt 3D Renderers: OpenGL Renderer ........................ yes RHI Renderer ........................... yes Qt3D Geometry Loaders: Autodesk FBX ........................... no Qt 5 Compatibility Libraries: iconv .................................. no Further Image Formats: JasPer ................................. no MNG .................................... yes TIFF ................................... yes Using system libtiff ................. yes WEBP ................................... yes Using system libwebp ................. no Qt Quick Templates 2: Hover support .......................... yes Multi-touch support .................... yes Qt Quick Controls 2: Styles ................................. Basic Fusion Imagine Material Universal macOS Windows Qt Multimedia: ALSA ................................... no GStreamer 1.0 .......................... yes Video for Linux ........................ yes PulseAudio ............................. no MMRenderer ............................. no AVFoundation ........................... no Windows Media Foundation ............... no Qt Charts Types: Area Chart ............................. yes Line Chart ............................. yes Spline Chart ........................... yes Scatter Chart .......................... yes Bar Chart .............................. yes Pie Chart .............................. yes Boxplot Chart .......................... yes Candlestick Chart ...................... yes Qt Axis Types: DateTime Axis .......................... yes Qt Tools: Qt Assistant ........................... yes QDoc ................................... no Clang-based lupdate parser ............. no Qt Designer ............................ yes Qt Distance Field Generator ............ yes Qt Linguist ............................ yes Mac Deployment Tool .................... no pixeltool .............................. yes qdbus .................................. yes Qt Attributions Scanner ................ yes qtdiag ................................. yes qtplugininfo ........................... yes Windows deployment tool ................ no Serial Port: ntddmodm ............................... no Qt Opcua: Open62541 .............................. yes Unified Automation C++ SDK ............. no Support for namespace 0 NodeId names ... yes Namespace 0 NodeIds generator .......... no Open62541 security support ............. yes Support for global discovery server .... yes QtQuick3D: Assimp ................................. yes System Assimp .......................... no Qt Remote Objects: High Availability Manager (ham) ........ no Qt Scxml: ECMAScript data model for QtScxml ...... yes Qt Sensors: sensorfw ............................... no sensorfw_enabled_with_cmake ............ no Qt SerialBus: Socket CAN ............................. yes Socket CAN FD .......................... yes SerialPort Support ..................... yes Qt Virtualkeyboard: Desktop integration .................... yes Built-in layouts ....................... yes Key navigation ......................... no Retro style as default ................. no Sensitive Debug ........................ no Cerence ................................ no Static Linking ....................... no Handwriting .......................... no Alphabetic ......................... no CJK ................................ no XT9 .................................. no XT9 Debug .......................... no XT9 9-key layouts .................. no Bundle resources ..................... no Handwriting ........................ no XT9 ................................ no Hunspell ............................... yes Using Hunspell copy from 3rdparty/ ... no OpenWnn ................................ yes MyScript ............................... no Qt Wayland Drivers: EGL .................................... yes Raspberry Pi ........................... no XComposite EGL ......................... yes XComposite GLX ......................... yes DRM EGL ................................ yes libhybris EGL .......................... no Linux dma-buf server buffer integration yes Vulkan-based server buffer integration . no Shm emulation server buffer integration yes Qt Wayland Client Shell Integrations: xdg-shell .............................. yes wayland_client_xdg_shell_v5 ............ no wayland_client_xdg_shell_v6 ............ no ivi-shell .............................. yes wl-shell (deprecated) .................. yes Qt Wayland Client ........................ yes Qt Wayland Compositor .................... yes Qt Wayland Compositor Layer Plugins: VSP2 hardware layer integration ........ no Qt Wayland Drivers: EGL .................................... yes Raspberry Pi ........................... no XComposite EGL ......................... yes XComposite GLX ......................... yes DRM EGL ................................ yes libhybris EGL .......................... no Linux dma-buf server buffer integration yes Vulkan-based server buffer integration . no Shm emulation server buffer integration yes Qt Wayland Client Shell Integrations: xdg-shell .............................. yes wayland_client_xdg_shell_v5 ............ no wayland_client_xdg_shell_v6 ............ no ivi-shell .............................. yes wl-shell (deprecated) .................. yes Qt Wayland Client ........................ yes Qt Wayland Compositor .................... yes Qt Wayland Compositor Layer Plugins: VSP2 hardware layer integration ........ no Build Features: Use system ninja ....................... yes Use system gn .......................... no Developer build ........................ yes Optional system libraries: re2 .................................. no icu .................................. no libwebp, libwebpmux and libwebpdemux . no opus ................................. no ffmpeg ............................... no libvpx ............................... no snappy ............................... no glib ................................. yes zlib ................................. no minizip .............................. no libevent ............................. no protobuf ............................. no libxml2 and libxslt .................. no lcms2 ................................ no png .................................. no jpeg ................................. no harfbuzz ............................. no freetype ............................. yes libpci ............................... no
I am getting this error whenever I am trying to run any widgets application
qt.qpa.plugin: Could not find the Qt platform plugin "xcb" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.There is not libqxcb.so present in qtbase/plugins/platforms
Do I need to specifically include any configuration option? -
Hi and welcome to devnet,
@nitingera said in Build Qt6 from Source, xcb issue:
xcb-sm ............................... no
I would say you are missing a development library here.
You can check the tests logs to see what has failed exactly.
-
@SGaist said in Build Qt6 from Source, xcb issue:
@nitingera said in Build Qt6 from Source, xcb issue:
xcb-sm ............................... no
I would say you are missing a development library here.
I think so too.
Please ensure you've installed all the dependencies listed at https://doc.qt.io/qt-6/linux-requirements.html
Then, delete all the files generated through the configure/build process and try again.
-
Thanks @SGaist and @JKSH
It worked after I installed the following packages- Xcb-util-keysyms-devel.x86_64
- Xcb-util-renderutil-devel.x86_64
- Xcb-util-image-devel.x86_64
- Xcb-util-wm-devel.x86_64
- Xcb-util-cursor-devel.x86_64
- yum install libxcb libxcb-devel xcb-util xcb-util-devel
Listing the packages for future references :)
-
I have a similar problem to this (on RHEL 7.6 amd64) but without root access (and a very corporate IT that only does corporate IT things).
I've started building some dependencies that are too old/don't have dev packages installed (xcb, xcb-wm proto etc.).
Roughly what I've done is build these packages and then run configure with PKG_CONFIG_PATH pointing to their pkg-config directories.
However I still get
config.summary: xcb-sm ............................... no
I'm no expert in CMake. Can someone point out where this feature test gets logged?
-
configure -- --trace-expand seems to be what I need. Finding the failing test might be a bit of a challenge though as there is a huge amount of output.
So far I've built gperf, libxcb- x7 xorg- x4. If I have to build libxkbcommon then that will need meson and ninja.