From e8a33a326327f50f82c0971bc2da9b11bd747804 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D9=85=D9=87=D8=AF=D9=8A=20=D8=B4=D9=8A=D9=86=D9=88=D9=86?= =?UTF-8?q?=20=28Mehdi=20Chinoune=29?= Date: Mon, 12 Jan 2026 10:04:15 +0100 Subject: [PATCH] flameshot: update to 13.3.0 --- .../0004-install-all-files.patch | 16 ++++---- .../0005-enable-command-line-options.patch | 11 ----- .../0005-remove-MSVC-flag.patch | 15 +++++++ mingw-w64-flameshot/PKGBUILD | 41 ++++++++++--------- 4 files changed, 45 insertions(+), 38 deletions(-) delete mode 100644 mingw-w64-flameshot/0005-enable-command-line-options.patch create mode 100644 mingw-w64-flameshot/0005-remove-MSVC-flag.patch diff --git a/mingw-w64-flameshot/0004-install-all-files.patch b/mingw-w64-flameshot/0004-install-all-files.patch index fee8720c2c..865e1c8e39 100644 --- a/mingw-w64-flameshot/0004-install-all-files.patch +++ b/mingw-w64-flameshot/0004-install-all-files.patch @@ -1,20 +1,20 @@ --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt -@@ -300,7 +303,7 @@ - BUNDLE DESTINATION ${CMAKE_INSTALL_BINDIR} - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) +@@ -371,7 +371,7 @@ + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) + endif () -if (UNIX) +if (UNIX OR MINGW) # Install desktop files, completion and dbus files configure_file(${CMAKE_SOURCE_DIR}/data/desktopEntry/package/org.flameshot.Flameshot.desktop ${CMAKE_CURRENT_BINARY_DIR}/share/applications/org.flameshot.Flameshot.desktop @ONLY) -@@ -355,7 +358,7 @@ +@@ -426,7 +426,7 @@ endif () # windeployqt -if (WIN32) -+if (WIN32 AND NOT MINGW) - if (EXISTS $ENV{QTDIR}/bin/windeployqt.exe) - if (CMAKE_BUILD_TYPE MATCHES Release) - set(BINARIES_TYPE --release) ++if (MSVC) + # Add CMAKE_PREFIX_PATH to search paths + foreach(prefix ${CMAKE_PREFIX_PATH}) + list(APPEND WINDEPLOYQT_SEARCH_PATHS "${prefix}/bin") diff --git a/mingw-w64-flameshot/0005-enable-command-line-options.patch b/mingw-w64-flameshot/0005-enable-command-line-options.patch deleted file mode 100644 index 5eba506fa8..0000000000 --- a/mingw-w64-flameshot/0005-enable-command-line-options.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/src/main.cpp -+++ b/src/main.cpp -@@ -146,7 +146,7 @@ - return qApp->exec(); - } - --#if !defined(Q_OS_WIN) -+#if defined(Q_OS_WIN) - /*--------------| - * CLI parsing | - * ------------*/ diff --git a/mingw-w64-flameshot/0005-remove-MSVC-flag.patch b/mingw-w64-flameshot/0005-remove-MSVC-flag.patch new file mode 100644 index 0000000000..9f2900c66d --- /dev/null +++ b/mingw-w64-flameshot/0005-remove-MSVC-flag.patch @@ -0,0 +1,15 @@ +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -91,7 +91,11 @@ + PRIVATE + windows-cli.cpp) + set_target_properties(flameshot-cli PROPERTIES OUTPUT_NAME "flameshot-cli") +- target_link_options(flameshot-cli PRIVATE /SUBSYSTEM:CONSOLE) ++ if(MSVC) ++ target_link_options(flameshot-cli PRIVATE /SUBSYSTEM:CONSOLE) ++ else() # MINGW ++ target_link_options(flameshot-cli PRIVATE -municode) ++ endif() + set_property(TARGET flameshot PROPERTY WIN32_EXECUTABLE true) + # Getting error D8016 - /utf-8 automatically set by current cmake/msvc ? + #if (MSVC) diff --git a/mingw-w64-flameshot/PKGBUILD b/mingw-w64-flameshot/PKGBUILD index 6a9946b0e3..d4ac0d4ee0 100644 --- a/mingw-w64-flameshot/PKGBUILD +++ b/mingw-w64-flameshot/PKGBUILD @@ -3,57 +3,58 @@ _realname=flameshot pkgbase=mingw-w64-${_realname} pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}") -pkgver=12.1.0 -pkgrel=2 +pkgver=13.3.0 +pkgrel=1 pkgdesc="Powerful yet simple to use screenshot software (mingw-w64)" arch=('any') -mingw_arch=('mingw64' 'ucrt64' 'clang64' 'clangarm64') +mingw_arch=('ucrt64' 'clang64' 'clangarm64') url='https://flameshot.org/' msys2_repository_url="https://github.com/flameshot-org/flameshot" license=('spdx:GPL-2.0-or-later') depends=("${MINGW_PACKAGE_PREFIX}-cc-libs" "${MINGW_PACKAGE_PREFIX}-hicolor-icon-theme" - "${MINGW_PACKAGE_PREFIX}-qt5-base" - "${MINGW_PACKAGE_PREFIX}-qt5-svg") -makedepends=("${MINGW_PACKAGE_PREFIX}-cmake" + "${MINGW_PACKAGE_PREFIX}-kdsingleapplication" + "${MINGW_PACKAGE_PREFIX}-qt6-base" + "${MINGW_PACKAGE_PREFIX}-qt6-svg") +makedepends=("${MINGW_PACKAGE_PREFIX}-cc" + "${MINGW_PACKAGE_PREFIX}-cmake" "${MINGW_PACKAGE_PREFIX}-ninja" - "${MINGW_PACKAGE_PREFIX}-cc" - "${MINGW_PACKAGE_PREFIX}-qt5-tools" + "${MINGW_PACKAGE_PREFIX}-qt6-tools" "${MINGW_PACKAGE_PREFIX}-openssl" "${MINGW_PACKAGE_PREFIX}-pkgconf" - 'git') + "git") source=( - "git+$msys2_repository_url#tag=v$pkgver" + "${msys2_repository_url}/archive/refs/tags/v${pkgver}/${_realname}-${pkgver}.tar.gz" 0001-fix-translation-path.patch 0002-stringify-version-in-rc.patch 0003-fix-static-linking-with-widgets.patch 0004-install-all-files.patch - 0005-enable-command-line-options.patch + 0005-remove-MSVC-flag.patch ) -sha256sums=('108f70340fa3facd440ac9428d590befe225305d00943a920ee5594c0007cb38' +sha256sums=('bd1666313c875400e9588b47eb3fd2f4d0828460b3705a215b97746ea654c1b4' '2264badcaa81f3980ecf7318adc54f8b2951b9fd10bc2eeaf084732f85ab2f7c' '959dff8fc2aa0b6a605928b88a960ad0191476de447f937cdbe2f32266767fce' '56e999649a6ff256e70b604df4026b2c0f28468797df3b09a625fb172099d644' - '0279f28b205c77b437f79a180b86622f9cb02aa2c60b593facb48bd2902f25cb' - 'dad8f92babf43def924e50c697d7cb0102dc99e5e7452f605d3f93e3a4a71a45') + 'ed5be030f12f0cb2d3ed96c48276cbe007ecca7474c13792794daa0146e5c191' + '81deb4bc0a7b84145052c2ce2d9202367c5accc2a7c46b87296d0810449c4d02') _apply_patch_with_msg() { for _patch in "$@" do msg2 "Applying ${_patch}" - git apply "${srcdir}/${_patch}" + patch -Np1 -i "${srcdir}"/${_patch} done } prepare() { - cd "${_realname}" + cd "${_realname}-${pkgver}" _apply_patch_with_msg \ 0001-fix-translation-path.patch \ 0002-stringify-version-in-rc.patch \ 0003-fix-static-linking-with-widgets.patch \ 0004-install-all-files.patch \ - 0005-enable-command-line-options.patch + 0005-remove-MSVC-flag.patch } build() { @@ -70,8 +71,9 @@ build() { -DCMAKE_INSTALL_PREFIX="${MINGW_PREFIX}" \ "${extra_config[@]}" \ -DENABLE_OPENSSL=ON \ + -DUSE_BUNDLED_KDSINGLEAPPLICATION=OFF \ -Wno-dev \ - -S "${_realname}" \ + -S "${_realname}-${pkgver}" \ -B "build-${MSYSTEM}" cmake --build "build-${MSYSTEM}" @@ -80,5 +82,6 @@ build() { package() { DESTDIR="${pkgdir}" cmake --install "build-${MSYSTEM}" - install -Dm644 "${srcdir}/${_realname}/LICENSE" "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/LICENSE" + install -Dm644 "${srcdir}"/${_realname}-${pkgver}/LICENSE \ + "${pkgdir}"${MINGW_PREFIX}/share/licenses/${_realname}/LICENSE }