Update to a 2024-08-17 git snapshot

Use a prebuilt splash image on s390x because the build hangs otherwise.

Signed-off-by: Nils Philippsen <nils@tiptoe.de>
This commit is contained in:
Nils Philippsen 2024-08-17 22:56:35 +02:00
parent 31d023ce71
commit ff107597ed
5 changed files with 28 additions and 54 deletions

2
.gitignore vendored
View File

@ -43,3 +43,5 @@ gimp-2.6.10-1-autoreconf.patch.bz2
/gimp-2.10.36.tar.bz2
/gimp-2.10.38.tar.bz2
/gimp-2.99.19-git256e0ca5a0.tar.xz
/gimp-2.99.19-gitd38362c9a0.tar.xz
/gimp-splash.png

View File

@ -1,45 +0,0 @@
From d101dc6b0a1acceb0286b8232a58ff7b6448502b Mon Sep 17 00:00:00 2001
From: Nils Philippsen <nils@tiptoe.de>
Date: Thu, 15 Aug 2024 09:50:48 +0200
Subject: [PATCH] plug-ins: Fix building TIFF loader on big endian
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
A recent addition to load layers in Sketchbook TIFFs contained a typo in
code specific to big endian machines, making it fail to build there,
which wasnt caught in CI.
In addition to this fix, use the appropriately named macro to convert
from little endian to big endian.
Signed-off-by: Nils Philippsen <nils@tiptoe.de>
---
plug-ins/file-tiff/file-tiff-load.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/plug-ins/file-tiff/file-tiff-load.c b/plug-ins/file-tiff/file-tiff-load.c
index 62988e793c..5988d2a77b 100644
--- a/plug-ins/file-tiff/file-tiff-load.c
+++ b/plug-ins/file-tiff/file-tiff-load.c
@@ -1911,7 +1911,7 @@ load_rgba (TIFF *tif,
guint32 i;
for (i = row_start; i < row_end; i++)
- buffer[i] = GUINT32_TO_LE (buffer[i]);
+ buffer[i] = GUINT32_FROM_LE (buffer[i]);
#endif
gegl_buffer_set (channel[0].buffer,
@@ -2451,7 +2451,7 @@ load_sketchbook_layers (TIFF *tif,
/* Make sure our channels are in the right order */
for (i = row_start; i < row_end; i++)
- pixels[i] = GUINT32_TO_LE (pixel[i]);
+ pixels[i] = GUINT32_FROM_LE (pixels[i]);
#endif
gegl_buffer_set (buffer,
GEGL_RECTANGLE (0, layer_height - row - 1,
--
2.46.0

1
gimp-splash.sha256sum Normal file
View File

@ -0,0 +1 @@
90ac7f576388aeee0cff4c8f3c05a6b2ee89ffc1f82bd42208db9a5fadc138d3 gimp-data/images/gimp-splash.xcf.xz

View File

@ -27,9 +27,11 @@
%ifnarch s390x
%bcond tests 1
%bcond prebuilt_splash 0
%else
# Tests hang on s390x, skip them.
%bcond tests 0
%bcond prebuilt_splash 1
%endif
# When building in Koji or mock, networking isnt available.
@ -56,7 +58,7 @@ gimp:app / ui
Summary: GNU Image Manipulation Program
Name: gimp
Epoch: 2
Version: 2.99.19^20240814git256e0ca5a0
Version: 2.99.19^20240817gitd38362c9a0
Release: %autorelease
# Compute some version related macros.
@ -213,6 +215,11 @@ Source0: https://download.gimp.org/pub/gimp/v%{bin_version}/gimp-%{versio
Source0: gimp-%{plain_version}-git%{git_rev}.tar.xz
%endif
# Building this from source hangs on s390x 😢. Building on any other arch will convert
# gimp-data/images/gimp-splash.xcf.xz just fine.
Source1: gimp-splash.png
Source2: gimp-splash.sha256sum
# Fedora specific patches:
# Try using the system monitor profile for color management by default.
@ -227,12 +234,6 @@ Patch3: gimp-2.99.19-external-help-browser.patch
# Dont require an unreleased gegl version
Patch4: 0001-Don-t-require-unreleased-gegl-version.patch
# Submitted upstream:
# Fix building TIFF loader plug-in on big endian
# https://gitlab.gnome.org/GNOME/gimp/-/merge_requests/1778
Patch5: 0001-plug-ins-Fix-building-TIFF-loader-on-big-endian.patch
%description
GIMP (GNU Image Manipulation Program) is a powerful image composition and
editing program, which can be extremely useful for creating logos and other
@ -280,6 +281,8 @@ cat << EOF
--- 8< --- Build options ---------------------------------------------------
is default version: %{with is_default_version}
label overlay: %{with label_overlay}
tests: %{with tests}
prebuilt splash: %{with prebuilt_splash}
%if %defined snapshot
snapshot: %{snapshot}
plain_version: %{plain_version}
@ -294,7 +297,9 @@ EOF
%patch 2 -p1 -b .no-phone-home-default
%patch 3 -p1 -b .external-help-browser
%patch 4 -p1 -b .don-t-require-unreleased-gegl-version
%patch 5 -p1 -b .fix-building-tiff-loader-on-big-endian
# Verify the splash file source hasnt changed
sha256sum -c %{SOURCE2}
%build
# Use hardening compiler/linker flags because gimp is likely to deal with files
@ -310,11 +315,21 @@ EOF
-Dilbm=disabled \
-Dbug-report-url="https://bugzilla.redhat.com/"
%if %{with prebuilt_splash}
# Building this from source hangs on s390x 😢, so prevent attempting to build it …
sed -i -e '/^subdir/!s/^/# /g' gimp-data/images/meson.build
%endif
%meson_build
%install
%meson_install
%if %{with prebuilt_splash}
# … instead, copy the prebuilt file into place.
install -m 644 %{SOURCE1} %{buildroot}%{_datadir}/gimp/%{api_version}/images/gimp-splash.png
%endif
# Generate RPM macros from pkg-config data:
# %%_gimp_datadir -- toplevel directory for brushes, gradients, scripts, ...
# %%_gimp_libdir -- toplevel directory for modules, plug-ins, ...

View File

@ -1 +1,2 @@
SHA512 (gimp-2.99.19-git256e0ca5a0.tar.xz) = aadde8172a0d867641a304d2dd84ecb96ac2d2111ead6b64d251cdb21695054671a480a461d611335466161026b7d2ead0472941b27df3f2aa91251aa2d19c7b
SHA512 (gimp-2.99.19-gitd38362c9a0.tar.xz) = 5498e7cda471ddc96109af5c52720a52e42b7e100d158a360bfb3935502633f77c394a613d0552c254b06c076cc38a5ce92c69e697d19bbcd673ea43a5b3b64e
SHA512 (gimp-splash.png) = e4443fa1c4eaf50ce4a89681d436d9c23ccae7e3a6cac1e853bba05d851c815c59c53d52c9f3e159460d52e03b492cc48f366f6e194b7ca8c740692eb0c2d963