From 0a5d7ba512bf9aa0a986c2c4f4741419feb41e74 Mon Sep 17 00:00:00 2001 From: Pavel Vinogradov Date: Tue, 9 Aug 2022 14:05:47 -0400 Subject: x11-libs/cairo: follow-up for stable branch --- x11-libs/cairo/HISTORY | 5 +++- x11-libs/cairo/PRE_BUILD | 5 +--- .../0001-Fix-build-with-newer-binutils.patch | 34 ++++++++++++++++++++++ .../cairo-1.10.0-buggy_gradients.patch | 14 +++++++++ 4 files changed, 53 insertions(+), 5 deletions(-) create mode 100644 x11-libs/cairo/patches-stable/0001-Fix-build-with-newer-binutils.patch create mode 100644 x11-libs/cairo/patches-stable/cairo-1.10.0-buggy_gradients.patch (limited to 'x11-libs') diff --git a/x11-libs/cairo/HISTORY b/x11-libs/cairo/HISTORY index 4a0c6b268f..f947295877 100644 --- a/x11-libs/cairo/HISTORY +++ b/x11-libs/cairo/HISTORY @@ -1,6 +1,9 @@ 2022-08-09 Pavel Vinogradov - * PRE_BUILD, 0001-Fix-build-against-binutils-2.39.patch: fix build + * PRE_BUILD, patches/0001-Fix-build-against-binutils-2.39.patch, + patches-stable/0001-Fix-build-with-newer-binutils.patch: fix build against binutils 2.39 + * cairo-1.10.0-buggy_gradients.patch -> + patches-stable/cairo-1.10.0-buggy_gradients.patch 2022-08-06 Pavel Vinogradov * CONFIGURE, DEPENDS, DETAILS, PRE_BUILD, PRE_SUB_DEPENDS, diff --git a/x11-libs/cairo/PRE_BUILD b/x11-libs/cairo/PRE_BUILD index f7d147eebf..02e1d7d5e9 100755 --- a/x11-libs/cairo/PRE_BUILD +++ b/x11-libs/cairo/PRE_BUILD @@ -3,7 +3,4 @@ cd ${SOURCE_DIRECTORY} && apply_patch_dir patches && -if [[ "$CAIRO_BRANCH" != "scm" ]]; then - # http://bugs.gentoo.org/show_bug.cgi?id=336696 - patch -p1 -d "$SOURCE_DIRECTORY" < "$SPELL_DIRECTORY/cairo-1.10.0-buggy_gradients.patch" -fi +if [[ "$CAIRO_BRANCH" != "scm" ]]; then apply_patch_dir patches-stable; fi diff --git a/x11-libs/cairo/patches-stable/0001-Fix-build-with-newer-binutils.patch b/x11-libs/cairo/patches-stable/0001-Fix-build-with-newer-binutils.patch new file mode 100644 index 0000000000..27d0e0d20d --- /dev/null +++ b/x11-libs/cairo/patches-stable/0001-Fix-build-with-newer-binutils.patch @@ -0,0 +1,34 @@ +From 24996e6ee241ebcd303dd34a2b06b37a6dd0c217 Mon Sep 17 00:00:00 2001 +From: Simon McVittie +Date: Wed, 13 Jul 2022 21:26:57 +0100 +Subject: [PATCH] Fix build with newer binutils-dev installed + +It seems the PTR typedef (or macro?) has been removed from newer versions +of libbfd. + +Resolves: https://gitlab.freedesktop.org/cairo/cairo/-/issues/581 +Signed-off-by: Simon McVittie +--- + util/cairo-trace/lookup-symbol.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/util/cairo-trace/lookup-symbol.c b/util/cairo-trace/lookup-symbol.c +index 3934066b9..ca15688c4 100644 +--- a/util/cairo-trace/lookup-symbol.c ++++ b/util/cairo-trace/lookup-symbol.c +@@ -106,10 +106,10 @@ _symtab_init (struct symtab *symtab, const char *filename) + if (! bfd_check_format_matches (symtab->bfd, bfd_object, &matching)) + goto BAIL; + +- symcount = bfd_read_minisymbols (symtab->bfd, false, (PTR) &symtab->syms, &size); ++ symcount = bfd_read_minisymbols (symtab->bfd, false, (void **) &symtab->syms, &size); + if (symcount == 0) { + symcount = bfd_read_minisymbols (symtab->bfd, true /* dynamic */ , +- (PTR) &symtab->syms, &size); ++ (void **) &symtab->syms, &size); + } + if (symcount < 0) + goto BAIL; +-- +GitLab + diff --git a/x11-libs/cairo/patches-stable/cairo-1.10.0-buggy_gradients.patch b/x11-libs/cairo/patches-stable/cairo-1.10.0-buggy_gradients.patch new file mode 100644 index 0000000000..a3a4a96120 --- /dev/null +++ b/x11-libs/cairo/patches-stable/cairo-1.10.0-buggy_gradients.patch @@ -0,0 +1,14 @@ +--- a/src/cairo-xlib-display.c.ubuntu 2010-08-04 11:57:49.000000000 +0200 ++++ b/src/cairo-xlib-display.c 2010-08-04 11:58:28.000000000 +0200 +@@ -353,11 +353,7 @@ + /* Prior to Render 0.10, there is no protocol support for gradients and + * we call function stubs instead, which would silently consume the drawing. + */ +-#if RENDER_MAJOR == 0 && RENDER_MINOR < 10 + display->buggy_gradients = TRUE; +-#else +- display->buggy_gradients = FALSE; +-#endif + display->buggy_pad_reflect = FALSE; + display->buggy_repeat = FALSE; + -- cgit v1.2.3