From 0819e093d03966df225ebee95f2b11ce70013036 Mon Sep 17 00:00:00 2001 From: Daria Kolodkina Date: Wed, 4 Mar 2026 19:23:45 +0100 Subject: [PATCH 1/6] native: linux: make conversion for logs more transparent Qt build was having a problem with it. --- devlib/native/linux_native.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devlib/native/linux_native.cpp b/devlib/native/linux_native.cpp index 979ec75..72913a8 100644 --- a/devlib/native/linux_native.cpp +++ b/devlib/native/linux_native.cpp @@ -51,7 +51,7 @@ namespace linutil { if (::close(fd) == -1) { auto errnoCache = errno; linutil::errnoWarning(__PRETTY_FUNCTION__, - QString("can not close handle ").append(fd), + QString("can not close handle ").append(QString::number(fd)), errnoCache); } } From 8af689908f6bf779ca77c622e717444970cca11c Mon Sep 17 00:00:00 2001 From: Daria Kolodkina Date: Wed, 4 Mar 2026 19:27:19 +0100 Subject: [PATCH 2/6] native: win: QRegExp -> QRegularExpression --- devlib/native/win_native.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/devlib/native/win_native.cpp b/devlib/native/win_native.cpp index f865858..157188b 100644 --- a/devlib/native/win_native.cpp +++ b/devlib/native/win_native.cpp @@ -14,6 +14,7 @@ #include #include +#include namespace winutil { Q_LOGGING_CATEGORY(winlog, "windows_native"); @@ -161,7 +162,7 @@ namespace winutil { static auto extractUSBPorts(QString const& locationPath) { QString ports = ""; - QRegExp usbPort("USB\\((\\d+)"); + QRegularExpression usbPort("USB\\((\\d+)"); int pos = 0; while ((pos = usbPort.indexIn(locationPath, pos)) != -1) { ports += QString(".") + usbPort.cap(1); From 18d0aa77063b42070cd635df9c9d2f290dbaff9a Mon Sep 17 00:00:00 2001 From: Daria Kolodkina Date: Wed, 4 Mar 2026 19:28:15 +0100 Subject: [PATCH 3/6] native: win: change extractUsbPort match cycle This is more clear and proper approach. --- devlib/native/win_native.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/devlib/native/win_native.cpp b/devlib/native/win_native.cpp index 157188b..f3791ee 100644 --- a/devlib/native/win_native.cpp +++ b/devlib/native/win_native.cpp @@ -163,10 +163,10 @@ namespace winutil { static auto extractUSBPorts(QString const& locationPath) { QString ports = ""; QRegularExpression usbPort("USB\\((\\d+)"); - int pos = 0; - while ((pos = usbPort.indexIn(locationPath, pos)) != -1) { - ports += QString(".") + usbPort.cap(1); - pos += usbPort.matchedLength(); + auto it = usbPort.globalMatch(locationPath); + while (it.hasNext()) { + auto match = it.next(); + ports += QString(".") + match.captured(1); } return ports; } From e125f35597d17fbe4b0952d84df6f9daaa90e950 Mon Sep 17 00:00:00 2001 From: Daria Kolodkina Date: Mon, 8 Jun 2026 16:07:04 +0200 Subject: [PATCH 4/6] devlib.pro: add fix for qt6.10.2 on macOs --- devlib/devlib.pro | 3 +++ 1 file changed, 3 insertions(+) diff --git a/devlib/devlib.pro b/devlib/devlib.pro index e5503fb..5c90655 100644 --- a/devlib/devlib.pro +++ b/devlib/devlib.pro @@ -10,6 +10,9 @@ TARGET = devlib TEMPLATE = lib CONFIG += c++14 staticlib +# Qt 6.10.2 bug: qyieldcpu.h calls __yield() on ARM64 without including +macx: QMAKE_CXXFLAGS += "-include arm_acle.h" + # The following define makes your compiler emit warnings if you use # any feature of Qt which has been marked as deprecated (the exact warnings # depend on your compiler). Please consult the documentation of the From 52c6717940c59305bcba39be202a0659e91f28e3 Mon Sep 17 00:00:00 2001 From: Daria Kolodkina Date: Mon, 8 Jun 2026 16:58:27 +0200 Subject: [PATCH 5/6] devlib: native: macos: fix QProcess start command --- devlib/native/macosx_native.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/devlib/native/macosx_native.cpp b/devlib/native/macosx_native.cpp index 614231e..75965a8 100644 --- a/devlib/native/macosx_native.cpp +++ b/devlib/native/macosx_native.cpp @@ -15,7 +15,7 @@ auto devlib::native::devicePartitions(QString const& devicePath) qCDebug(macos_utils::macxlog()) << "Run 'diskutil list -plist'"; QProcess diskutil; - diskutil.start("diskutil list -plist", QIODevice::ReadOnly); + diskutil.start("diskutil", {"list", "-plist"}, QIODevice::ReadOnly); diskutil.waitForFinished(); if (diskutil.error() != QProcess::ProcessError::UnknownError) { @@ -173,7 +173,7 @@ bool devlib::native::umountDisk(QString const & devicePath) bool devlib::native::mount(const QString &dev, const QString &path) { QProcess mount; - mount.start(QString("mount -t msdos %1 %2").arg(dev).arg(path)); + mount.start("mount", {"-t", "msdos", dev, path}); mount.waitForFinished(); return mount.exitCode() == 0; } From d491b7c7deec3db96051bfff6099bed8914ae46a Mon Sep 17 00:00:00 2001 From: Daria Kolodkina Date: Mon, 8 Jun 2026 17:15:15 +0200 Subject: [PATCH 6/6] devlib: native: macos: utils: fix QString for Qt6 --- devlib/native/macos_utils/macos_utils.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/devlib/native/macos_utils/macos_utils.cpp b/devlib/native/macos_utils/macos_utils.cpp index e408a10..7669bcd 100644 --- a/devlib/native/macos_utils/macos_utils.cpp +++ b/devlib/native/macos_utils/macos_utils.cpp @@ -114,7 +114,7 @@ namespace macos_utils { { auto usbPortsInHex = QString{locationID}.remove(0,2) // remove leading bus number .remove("0") // remove trailing zeros - .split("", QString::SkipEmptyParts); + .split("", Qt::SkipEmptyParts); auto usbPorts = QStringList{}; std::transform(usbPortsInHex.cbegin(), usbPortsInHex.cend(),