diff --git a/srcpkgs/krita/patches/jxl09.patch b/srcpkgs/krita/patches/jxl09.patch new file mode 100644 index 00000000000..50e2cd50bcc --- /dev/null +++ b/srcpkgs/krita/patches/jxl09.patch @@ -0,0 +1,71 @@ +From d9e258bf9d6af5f53467becf65bb21bf6f96a38e Mon Sep 17 00:00:00 2001 +From: Timo Gurr +Date: Fri, 29 Dec 2023 11:10:26 +0100 +Subject: [PATCH] Fix build with libjxl 0.9.0 + +BUG:478987 +--- + plugins/impex/jxl/JPEGXLImport.cpp | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +diff --git a/plugins/impex/jxl/JPEGXLImport.cpp b/plugins/impex/jxl/JPEGXLImport.cpp +index 573bae41247..f5b989b3b70 100644 +--- a/plugins/impex/jxl/JPEGXLImport.cpp ++++ b/plugins/impex/jxl/JPEGXLImport.cpp +@@ -511,7 +511,9 @@ JPEGXLImport::convert(KisDocument *document, QIODevice *io, KisPropertiesConfigu + JxlColorEncoding colorEncoding{}; + if (JXL_DEC_SUCCESS + == JxlDecoderGetColorAsEncodedProfile(dec.get(), ++#if JPEGXL_NUMERIC_VERSION < JPEGXL_COMPUTE_NUMERIC_VERSION(0, 9, 0) + nullptr, ++#endif + JXL_COLOR_PROFILE_TARGET_DATA, + &colorEncoding)) { + const TransferCharacteristics transferFunction = [&]() { +@@ -635,7 +637,12 @@ JPEGXLImport::convert(KisDocument *document, QIODevice *io, KisPropertiesConfigu + size_t iccSize = 0; + QByteArray iccProfile; + if (JXL_DEC_SUCCESS +- != JxlDecoderGetICCProfileSize(dec.get(), nullptr, JXL_COLOR_PROFILE_TARGET_DATA, &iccSize)) { ++ != JxlDecoderGetICCProfileSize(dec.get(), ++#if JPEGXL_NUMERIC_VERSION < JPEGXL_COMPUTE_NUMERIC_VERSION(0,9,0) ++ nullptr, ++#endif ++ JXL_COLOR_PROFILE_TARGET_DATA, ++ &iccSize)) { + errFile << "ICC profile size retrieval failed"; + document->setErrorMessage(i18nc("JPEG-XL errors", "Unable to read the image profile.")); + return ImportExportCodes::ErrorWhileReading; +@@ -643,7 +650,9 @@ JPEGXLImport::convert(KisDocument *document, QIODevice *io, KisPropertiesConfigu + iccProfile.resize(static_cast(iccSize)); + if (JXL_DEC_SUCCESS + != JxlDecoderGetColorAsICCProfile(dec.get(), ++#if JPEGXL_NUMERIC_VERSION < JPEGXL_COMPUTE_NUMERIC_VERSION(0,9,0) + nullptr, ++#endif + JXL_COLOR_PROFILE_TARGET_DATA, + reinterpret_cast(iccProfile.data()), + static_cast(iccProfile.size()))) { +@@ -657,7 +666,9 @@ JPEGXLImport::convert(KisDocument *document, QIODevice *io, KisPropertiesConfigu + if (!d.m_info.uses_original_profile) { + if (JXL_DEC_SUCCESS + != JxlDecoderGetICCProfileSize(dec.get(), ++#if JPEGXL_NUMERIC_VERSION < JPEGXL_COMPUTE_NUMERIC_VERSION(0,9,0) + nullptr, ++#endif + JXL_COLOR_PROFILE_TARGET_ORIGINAL, + &iccTargetSize)) { + errFile << "ICC profile size retrieval failed"; +@@ -667,7 +678,9 @@ JPEGXLImport::convert(KisDocument *document, QIODevice *io, KisPropertiesConfigu + iccTargetProfile.resize(static_cast(iccTargetSize)); + if (JXL_DEC_SUCCESS + != JxlDecoderGetColorAsICCProfile(dec.get(), ++#if JPEGXL_NUMERIC_VERSION < JPEGXL_COMPUTE_NUMERIC_VERSION(0,9,0) + nullptr, ++#endif + JXL_COLOR_PROFILE_TARGET_ORIGINAL, + reinterpret_cast(iccTargetProfile.data()), + static_cast(iccTargetProfile.size()))) { +-- +GitLab + diff --git a/srcpkgs/krita/patches/sip68.patch b/srcpkgs/krita/patches/sip68.patch new file mode 100644 index 00000000000..e9e4544b7cc --- /dev/null +++ b/srcpkgs/krita/patches/sip68.patch @@ -0,0 +1,23 @@ +From 2d71c47661d43a4e3c1ab0c27803de980bdf2bb2 Mon Sep 17 00:00:00 2001 +From: Antonio Rojas +Date: Mon, 11 Dec 2023 20:26:13 +0100 +Subject: [PATCH] Bump SIP ABI version to 12.8 + +Fixes build with SIP 6.8 +--- + cmake/modules/pyproject.toml.in | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/cmake/modules/pyproject.toml.in b/cmake/modules/pyproject.toml.in +index 090b2d4b0cb..085ddf41799 100644 +--- a/cmake/modules/pyproject.toml.in ++++ b/cmake/modules/pyproject.toml.in +@@ -9,7 +9,7 @@ name = "@module_name_toml@" + sip-module = "@sip_name@" + sip-include-dirs = @sip_include_dirs@ + sip-files-dir = "@module_srcs@" +-abi-version = "12" ++abi-version = "12.8" + + [tool.sip.bindings.@module_name_toml@] + tags = @module_tags@ diff --git a/srcpkgs/krita/template b/srcpkgs/krita/template index d804b581a86..4833f8bd33d 100644 --- a/srcpkgs/krita/template +++ b/srcpkgs/krita/template @@ -1,7 +1,7 @@ # Template file for 'krita' pkgname=krita version=5.2.1 -revision=3 +revision=4 build_style=cmake configure_args="-Wno-dev -DBUILD_TESTING=OFF" hostmakedepends="extra-cmake-modules gettext pkg-config python3