* update cairo to 1.17.4-6

This commit is contained in:
Alexander Baldeck 2021-04-22 09:14:15 +02:00
parent 81bc45d034
commit b709abbe64
2 changed files with 39 additions and 36 deletions

View File

@ -1,18 +1,17 @@
# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
# Maintainer: Jan de Groot <jgc@archlinux.org>
# Contributor: Brice Carpentier <brice@daknet.org>
pkgname=cairo
pkgver=1.17.4
pkgrel=5
pkgrel=6
pkgdesc="2D graphics library with support for multiple output devices"
url="https://cairographics.org/"
arch=(x86_64 powerpc64le powerpc)
license=(LGPL MPL)
depends=(lzo zlib libpng fontconfig freetype2 libx11 libxext libxrender libxcb
glib2 pixman)
makedepends=(valgrind git meson)
depends=(libpng libxrender libxext fontconfig pixman glib2 lzo)
makedepends=(librsvg gtk2 poppler-glib libspectre gtk-doc valgrind git)
checkdepends=(ttf-dejavu gsfonts)
_commit=156cd3eaaebfd8635517c2baf61fcf3627ff7ec2 # tags/1.17.4^0
source=("git+https://gitlab.freedesktop.org/cairo/cairo.git#commit=$_commit")
sha256sums=('SKIP')
@ -38,16 +37,45 @@ prepare() {
# Disable XCB backend for Xlib surfaces
# https://bugs.archlinux.org/task/68839
git cherry-pick -n 3468c67fe91f0c37e0ec5d335082653a6fa609b6
# Update gtk-doc
cp /usr/share/aclocal/gtk-doc.m4 build/aclocal.gtk-doc.m4
cp /usr/share/gtk-doc/data/gtk-doc.make build/Makefile.am.gtk-doc
# Fix typo
sed -i 's/have_png/use_png/g' configure.ac
NOCONFIGURE=1 ./autogen.sh
}
build() {
arch-meson cairo build \
-D spectre=disabled \
-D tee=enabled \
-D tests=disabled
meson compile -C build
cd cairo
./configure --prefix=/usr \
--sysconfdir=/etc \
--localstatedir=/var \
--disable-static \
--disable-gl \
--enable-tee \
--enable-svg \
--enable-ps \
--enable-pdf \
--enable-gobject \
--enable-gtk-doc \
--enable-full-testing \
--enable-test-surfaces
sed -i 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
check() {
cd cairo
# FIXME: tests don't pass
env CAIRO_TEST_TARGET=image \
CAIRO_TEST_TARGET_FORMAT=rgba \
CAIRO_TESTS='!pthread-show-text' make -k check || :
}
package() {
DESTDIR="$pkgdir" meson install -C build
cd cairo
make DESTDIR="$pkgdir" install
}

View File

@ -1,25 +0,0 @@
diff --git i/meson.build w/meson.build
index b159b4071..2a1c68891 100644
--- i/meson.build
+++ w/meson.build
@@ -313,7 +313,7 @@ endif
if feature_conf.get('CAIRO_HAS_XCB_SURFACE', 0) == 1 and feature_conf.get('CAIRO_HAS_XLIB_SURFACE', 0) == 1
# FIXME: automagic
- x11xcb_dep = dependency('x11-xcb', required: false)
+ x11xcb_dep = dependency('x11-xcb', required: get_option('xlib-xcb'))
if x11xcb_dep.found()
deps += [x11xcb_dep]
feature_conf.set('CAIRO_HAS_XLIB_XCB_FUNCTIONS', 1)
diff --git i/meson_options.txt w/meson_options.txt
index ff11fe7ed..d1ae959e1 100644
--- i/meson_options.txt
+++ w/meson_options.txt
@@ -17,6 +17,7 @@ option('qt', type : 'feature', value : 'disabled')
option('tee', type : 'feature', value : 'disabled')
option('xcb', type : 'feature', value : 'auto')
option('xlib', type : 'feature', value : 'auto')
+option('xlib-xcb', type : 'feature', value : 'disabled')
#option('xml', type : 'feature', value : 'disabled')
option('zlib', type : 'feature', value : 'auto') # script, ps, pdf, xml surfaces