aboutsummaryrefslogtreecommitdiffstats
path: root/community/librsvg/APKBUILD
blob: 409dba0642f3fc39609266d9a7b423d551ffe8cb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
# Contributor: Rasmus Thomsen <oss@cogitri.dev>
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Rasmus Thomsen <oss@cogitri.dev>
pkgname=librsvg
pkgver=2.54.4
pkgrel=0
pkgdesc="SAX-based renderer for SVG files into a GdkPixbuf"
url="https://wiki.gnome.org/Projects/LibRsvg"
arch="all !s390x !riscv64" # rust
license="LGPL-2.1-or-later"
subpackages="$pkgname-dbg $pkgname-dev $pkgname-doc"
makedepends="
	bzip2-dev
	cairo-dev
	cargo
	gi-docgen
	glib-dev
	gobject-introspection-dev
	gtk+3.0-dev
	libgsf-dev
	py3-docutils
	rust
	ttf-dejavu
	vala
	"
source="https://download.gnome.org/sources/librsvg/${pkgver%.*}/librsvg-$pkgver.tar.xz
	target.patch
	"
# tests are very dependent on versions of pango/cairo/freetype
options="!check"

# secfixes:
#   2.50.4-r0:
#     - RUSTSEC-2020-0146
#   2.46.2-r0:
#     - CVE-2019-20446

export RUSTFLAGS="$RUSTFLAGS -C debuginfo=2"
export CARGO_PROFILE_RELEASE_LTO=true
export CARGO_PROFILE_RELEASE_CODEGEN_UNITS=1

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--libexecdir=/usr/lib/$pkgname \
		--disable-static \
		--enable-vala
	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
e3415044a4faa48ec83e25cbd86dfbe7bc997286269298fb913a61a13d55195f660bcef459950979c2b8d60b144b29e33b278b2c4da0c376de65c34f39687e9a  librsvg-2.54.4.tar.xz
8cc9b9dd70a6dedb550a50e12a1bf0ca12f87487f432dcc2568d47412752565d563d7f488390108f49bda324b47387fec9386cf20be47e75d56fb482ecf0bb67  target.patch
"