From dba94d353d250aedfe11e6d5e7d5e5abdd29bf9c Mon Sep 17 00:00:00 2001 From: Amanda Graven Date: Tue, 4 Jan 2022 11:14:08 +0100 Subject: [PATCH] Fix 32-bit builds --- 32-bit-int-fix.patch | 13 +++++++++++++ gtksourceview5.spec | 2 ++ 2 files changed, 15 insertions(+) create mode 100644 32-bit-int-fix.patch diff --git a/32-bit-int-fix.patch b/32-bit-int-fix.patch new file mode 100644 index 0000000..a03b620 --- /dev/null +++ b/32-bit-int-fix.patch @@ -0,0 +1,13 @@ +diff --git a/gtksourceview/implregex.c b/gtksourceview/implregex.c +index 7cb9a18a..b8eb8137 100644 +--- a/gtksourceview/implregex.c ++++ b/gtksourceview/implregex.c +@@ -236,7 +236,7 @@ impl_regex_new (const char *pattern, + + #ifdef GTK_SOURCE_PROFILER_ENABLED + if (GTK_SOURCE_PROFILER_ACTIVE) +- message = g_strdup_printf ("compile=%lx match=%lx pattern=%s", ++ message = g_strdup_printf ("compile=%"G_GSIZE_MODIFIER"x match=%"G_GSIZE_MODIFIER"x pattern=%s", + regex->compile_flags, + regex->match_flags, + regex->pattern); diff --git a/gtksourceview5.spec b/gtksourceview5.spec index 1755aa3..6c36d15 100644 --- a/gtksourceview5.spec +++ b/gtksourceview5.spec @@ -11,6 +11,7 @@ Summary: Source code editing widget License: LGPLv2+ URL: https://wiki.gnome.org/Projects/GtkSourceView Source0: https://download.gnome.org/sources/gtksourceview/%{api_ver}.2/gtksourceview-%{version}.tar.xz +Patch0: 32-bit-int-fix.patch BuildRequires: gcc BuildRequires: gettext @@ -60,6 +61,7 @@ the functionality of the installed %{name} package. %prep %autosetup -n gtksourceview-%{version} +%patch0 -p1 %build %meson -Dgtk_doc=true -Dsysprof=true -Dinstall_tests=true