blob: 3840b69e702a0898282996aa72d1f582d861b8cf (
plain)
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
|
#!/bin/sh
NAME="librsvg"
DESC="SAX-based renderer for SVG files into a GdkPixbuf"
MAKEDEPS="make cargo rustc "
DEPS="cairo gdk-pixbuf glib libxml2 musl pango "
PKG_VER=2.54.1
SOURCE="https://download.gnome.org/sources/librsvg/${PKG_VER%.*}/librsvg-$PKG_VER.tar.xz"
ADDITIONAL="target.patch"
prepare () {
apply_patches
}
build () {
# Use LTO
#export CARGO_PROFILE_RELEASE_LTO=true CARGO_PROFILE_RELEASE_CODEGEN_UNITS=1
#
## Use debug
#export CARGO_PROFILE_RELEASE_DEBUG=2
export CC="clang"
export CXX="clang++"
export LD="clang"
./configure --prefix=/usr \
--libexecdir=/usr/lib/librsvg \
--disable-static \
--enable-vala
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0 /g' libtool
make
}
package () {
make DESTDIR=$PKG_DEST install
}
postinstall () {
gdk-pixbuf-query-loaders --update-cache
}
|