Can't build QT6 on Windows using MingWin54
-
Hello,
I've been trying to build the Qt6 on Windows using the MingWin but without sucess.
below the errors thrown.FAILED: src/3rdparty/libpng/PngPrivate_syncqt_timestamp C:/temp/qt6_min/qtbase/src/3rdparty/libpng/PngPrivate_syncqt_timestamp cmd.exe /C "cd /D C:\temp\qt6_min\qtbase\src\3rdparty\libpng && C:\temp\qt6_min\qtbase\bin\syncqt.exe @C:/temp/qt6_min/qtbase/src/3rdparty/libpng/PngPrivate_syncqt_args && C:\tools\CMake\bin\cmake.exe -E touch C:/temp/qt6_min/qtbase/src/3rdparty/libpng/PngPrivate_syncqt_timestamp" [5/1713] Running syncqt.cpp for module: QtZlib FAILED: src/3rdparty/zlib/ZlibPrivate_syncqt_timestamp C:/temp/qt6_min/qtbase/src/3rdparty/zlib/ZlibPrivate_syncqt_timestamp cmd.exe /C "cd /D C:\temp\qt6_min\qtbase\src\3rdparty\zlib && C:\temp\qt6_min\qtbase\bin\syncqt.exe @C:/temp/qt6_min/qtbase/src/3rdparty/zlib/ZlibPrivate_syncqt_args && C:\tools\CMake\bin\cmake.exe -E touch C:/temp/qt6_min/qtbase/src/3rdparty/zlib/ZlibPrivate_syncqt_timestamp" [6/1713] Running syncqt.cpp for module: QtHarfbuzz FAILED: src/3rdparty/harfbuzz-ng/HarfbuzzPrivate_syncqt_timestamp C:/temp/qt6_min/qtbase/src/3rdparty/harfbuzz-ng/HarfbuzzPrivate_syncqt_timestamp cmd.exe /C "cd /D C:\temp\qt6_min\qtbase\src\3rdparty\harfbuzz-ng && C:\temp\qt6_min\qtbase\bin\syncqt.exe @C:/temp/qt6_min/qtbase/src/3rdparty/harfbuzz-ng/HarfbuzzPrivate_syncqt_args && C:\tools\CMake\bin\cmake.exe -E copy_directory C:/temp/qt6_min/qtbase/src/3rdparty/harfbuzz-ng/include C:/temp/qt6_min/qtbase/include/QtHarfbuzz && C:\tools\CMake\bin\cmake.exe -E touch C:/temp/qt6_min/qtbase/src/3rdparty/harfbuzz-ng/HarfbuzzPrivate_syncqt_timestamp" [7/1713] Running syncqt.cpp for module: QtJpeg FAILED: src/3rdparty/libjpeg/JpegPrivate_syncqt_timestamp C:/temp/qt6_min/qtbase/src/3rdparty/libjpeg/JpegPrivate_syncqt_timestamp cmd.exe /C "cd /D C:\temp\qt6_min\qtbase\src\3rdparty\libjpeg && C:\temp\qt6_min\qtbase\bin\syncqt.exe @C:/temp/qt6_min/qtbase/src/3rdparty/libjpeg/JpegPrivate_syncqt_args && C:\tools\CMake\bin\cmake.exe -E touch C:/temp/qt6_min/qtbase/src/3rdparty/libjpeg/JpegPrivate_syncqt_timestamp" [8/1713] Running syncqt.cpp for module: QtExampleIcons FAILED: src/assets/icons/ExampleIconsPrivate_syncqt_timestamp include/QtExampleIcons/QtExampleIconsVersion include/QtExampleIcons/qtexampleiconsversion.h src/assets/icons/ExampleIconsPrivate.version.private_content include/QtExampleIcons/QtExampleIcons C:/temp/qt6_min/qtbase/src/assets/icons/ExampleIconsPrivate_syncqt_timestamp C:/temp/qt6_min/qtbase/include/QtExampleIcons/QtExampleIconsVersion C:/temp/qt6_min/qtbase/include/QtExampleIcons/qtexampleiconsversion.h C:/temp/qt6_min/qtbase/src/assets/icons/ExampleIconsPrivate.version.private_content C:/temp/qt6_min/qtbase/include/QtExampleIcons/QtExampleIcons cmd.exe /C "cd /D C:\temp\qt6_min\qtbase\src\assets\icons && C:\temp\qt6_min\qtbase\bin\syncqt.exe @C:/temp/qt6_min/qtbase/src/assets/icons/ExampleIconsPrivate_syncqt_args && C:\tools\CMake\bin\cmake.exe -E touch C:/temp/qt6_min/qtbase/src/assets/icons/ExampleIconsPrivate_syncqt_timestamp" [9/1713] Running syncqt.cpp for module: QtFreetype FAILED: src/3rdparty/freetype/FreetypePrivate_syncqt_timestamp C:/temp/qt6_min/qtbase/src/3rdparty/freetype/FreetypePrivate_syncqt_timestamp cmd.exe /C "cd /D C:\temp\qt6_min\qtbase\src\3rdparty\freetype && C:\temp\qt6_min\qtbase\bin\syncqt.exe @C:/temp/qt6_min/qtbase/src/3rdparty/freetype/FreetypePrivate_syncqt_args && C:\tools\CMake\bin\cmake.exe -E copy_directory C:/temp/qt6_min/qtbase/src/3rdparty/freetype/include C:/temp/qt6_min/qtbase/include/QtFreetype && C:\tools\CMake\bin\cmake.exe -E touch C:/temp/qt6_min/qtbase/src/3rdparty/freetype/FreetypePrivate_syncqt_timestamp" ninja: build stopped: subcommand failed.
any idea please?
thanks & regards.
haithem. -
Hi, do you have the suitable mingw32 version for qt6?Does it go with your Qt6 Version?
-
-
@Ronel_qtmaster
thanks for the prompt answer, below the config.summary, I can't see any issue there.Building for: win32-g++ (x86_64, CPU features: cx16 sse3) Compiler: gcc 13.2.0 Build options: Mode ................................... release Optimize release build for size ........ no Fully optimize release builds (-O3) .... no Building shared libraries .............. yes Unity Build ............................ no Relocatable ............................ yes Using precompiled headers .............. yes Using Link Time Optimization (LTCG) .... no Using Intel CET ........................ no Target compiler supports: x86 Intrinsics ....................... Basic VAES AVX512VBMI2 Sanitizers: Addresses ............................ no Threads .............................. no Memory ............................... no Fuzzer (instrumentation only) ........ no Undefined ............................ no Build parts ............................ libs tools Install examples sources ............... no App store compliance ................... no 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 PrintSupport ........................ yes Qt Sql ................................. yes Qt Testlib ............................. yes Qt Widgets ............................. yes Qt Xml ................................. yes Support enabled for: Using pkg-config ....................... no Using vcpkg ............................ no udev ................................... no OpenSSL ................................ no Qt directly linked to OpenSSL ........ no OpenSSL 1.1 ............................ no OpenSSL 3.0 ............................ no Using system zlib ...................... no Zstandard support ...................... no Thread support ......................... yes Common build options: Linker can resolve circular dependencies yes Qt Core: backtrace .............................. no DoubleConversion ....................... yes Using system DoubleConversion ........ no GLib ................................... no ICU .................................... no Using system libb2 ..................... no Built-in copy of the MIME database ..... yes Application permissions ................ yes Tracing backend ........................ <none> OpenSSL based cryptographic hash ....... no Logging backends: journald ............................. no syslog ............................... no slog2 ................................ no PCRE2 .................................. yes Using system PCRE2 ................... no Qt Sql: SQL item models ........................ yes Qt Network: getifaddrs() ........................... no IPv6 ifname ............................ no libproxy ............................... no Schannel ............................... yes DTLS ................................... no OCSP-stapling .......................... no SCTP ................................... no Use system proxies ..................... yes GSSAPI ................................. no Brotli Decompression Support ........... no qIsEffectiveTLD() ...................... yes Built-in publicsuffix database ....... yes System publicsuffix database ......... no Core tools: Android deployment tool ................ yes macOS deployment tool .................. no Windows deployment tool ................ yes qmake .................................. yes Qt Gui: Accessibility .......................... yes FreeType ............................... yes Using system FreeType ................ no HarfBuzz ............................... yes Using system HarfBuzz ................ no Fontconfig ............................. no 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 .................................... no OpenVG ................................. no OpenGL: Desktop OpenGL ....................... no Dynamic 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 .................................. no libinput ............................... no HiRes wheel support in libinput ........ no INTEGRITY HID .......................... no mtdev .................................. no tslib .................................. no xkbcommon .............................. no X11 specific: XLib ................................. no XCB Xlib ............................. no EGL on X11 ........................... no xkbcommon-x11 ........................ no xcb-sm ............................... no QPA backends: DirectFB ............................... no EGLFS .................................. no 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 ................................ no VNC .................................... no 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 ............................ yes Direct 2D 1.1 ........................ yes DirectWrite .......................... yes DirectWrite 3 ........................ yes Qt Widgets: GTK+ ................................... no Styles ................................. Fusion Windows WindowsVista Qt Testlib: Tester for item models ................. yes Batch tests ............................ no Qt PrintSupport: CUPS ................................... no Qt Sql Drivers: DB2 (IBM) .............................. no InterBase .............................. no MySql .................................. no OCI (Oracle) ........................... no ODBC ................................... yes PostgreSQL ............................. no SQLite ................................. yes Using system provided SQLite ......... no Mimer .................................. no Qt 5 Compatibility Libraries: iconv .................................. no Further Image Formats: JasPer ................................. no MNG .................................... no TIFF ................................... yes Using system libtiff ................. no WEBP ................................... yes Using system libwebp ................. no Qt Tools: Qt Assistant ........................... yes libclang found ......................... no Clang-based lupdate parser ............. no Qt Designer ............................ yes Qt Distance Field Generator ............ no Qt Linguist ............................ yes pixeltool .............................. yes qdbus .................................. yes QDoc ................................... no Qt Attributions Scanner ................ yes qtdiag ................................. yes qtplugininfo ........................... yes WARNING: Basic cpp/winrt support missing. Some features might not be available. WARNING: QDoc will not be compiled, probably because clang's C and C++ libraries could not be located. This means that you cannot build the Qt documentation. You may need to set CMAKE_PREFIX_PATH or LLVM_INSTALL_DIR to the location of your llvm installation. Other than clang's libraries, you may need to install another package, such as clang itself, to provide the ClangConfig.cmake file needed to detect your libraries. Once this file is in place, the configure script may be able to detect your system-installed libraries without further environment variables. On macOS, you can use Homebrew's llvm package. You will also need to set the FEATURE_clang CMake variable to ON to re-evaluate this check. WARNING: QDoc will not be compiled because the QmlPrivate library wasn't found. WARNING: Clang-based lupdate parser will not be available. LLVM and Clang C++ libraries have not been found. You will need to set the FEATURE_clangcpp CMake variable to ON to re-evaluate this check.
-
the 13.2.0 is the version of GCC not the MingWin.
anyway it seems to be O.K now:- download the mingwin from https://winlibs.com
- use PowerShell and not Git BASH to run the build command.
Qt is now configured for building. Just run 'cmake --build . --parallel' Once everything is built, you must run 'cmake --install .' Qt will be installed into 'C:/Qt/Qt-6.6.3' To configure and build other Qt modules, you can use the following convenience script: C:/Qt/Qt-6.6.3/bin/qt-configure-module.bat If reconfiguration fails for some reason, try removing 'CMakeCache.txt' from the build directory Alternatively, you can add the --fresh flag to your CMake flags. -- Configuring done -- Generating done -- Build files have been written to: C:/temp/qt6_min/qtbase PS C:\temp\qt6_min\qtbase> cmake --build . [441/1830] Building CXX object src/corelib/CMakeFiles/Core.dir/text/qbytearray.cpp.obj
-
@rahmanih said in Can't build QT6 on Windows using MingWin54:
Git BASH to run the build command.
You must not have any MSYS related stuff in your PATH - otherwise the build tools might pick them up (due to same name) and it will fail. You can see the problem already in your first output if I'm correct: "@C:/temp/qt6_min/qtbase/src/3rdparty/libjpeg/JpegPrivate_syncqt_args" - the forward slashes (but I might be wrong)