blob: cd15bb39d4edd8b5f844d2fa7924c0e72ce7d08d (
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
# Contributor: Valery Kartel <valery.kartel@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=glib
pkgver=2.48.0
pkgrel=1
pkgdesc="Common C routines used by Gtk+ and other libs"
url="http://www.gtk.org"
arch="all"
license='GPL'
depends=
triggers="$pkgname.trigger=/usr/share/glib-2.0/schemas:/usr/lib/gio/modules"
depends_dev="perl python gettext-dev zlib-dev bzip2-dev libffi-dev"
makedepends="$depends_dev pcre-dev"
source="http://ftp.gnome.org/pub/gnome/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.xz
0001-gquark-make-sure-quark-is-initialized-before-create-.patch
"
subpackages="$pkgname-dbg $pkgname-doc $pkgname-dev $pkgname-lang $pkgname-bash-completion:bashcomp"
_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
cd "$_builddir"
for i in $source; do
case $i in
*.patch) msg $i; patch -p1 -i "$srcdir"/$i || return 1;;
esac
done
# workaround packaing issue. gtk-doc.make timestamp was newer than
# Makefile.am, which triggers automake re-run
touch -r docs/reference/glib/Makefile.am gtk-doc.make
}
build() {
cd "$_builddir"
./configure \
--build=$CBUILD \
--host=$CHOST \
--prefix=/usr \
--mandir=/usr/share/man \
--disable-gtk-doc \
--disable-compile-warnings \
--with-pcre=system \
--with-pic \
|| return 1
make || return 1
}
package() {
cd "$_builddir"
make DESTDIR="$pkgdir" install || return 1
rm -rf "$pkgdir"/usr/lib/charset.alias
}
dev() {
default_dev
mkdir -p "$subpkgdir"/usr/bin "$subpkgdir"/usr/share
find "$pkgdir"/usr/bin ! -name "glib-compile-schemas" -a \( \
-name "gdbus-codegen" -o \
-name "gobject-query" -o \
-name "gresource" -o \
-name "gtester*" -o \
-name "glib-*" \) \
-exec mv {} "$subpkgdir"/usr/bin \;
mv "$pkgdir"/usr/share/gdb "$pkgdir"/usr/share/glib-2.0 \
"$subpkgdir"/usr/share
}
bashcomp() {
pkgdesc="Bash completion for $pkgname"
arch="noarch"
depends=
install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
mkdir -p "$subpkgdir"/usr/share
mv "$pkgdir"/usr/share/bash-completion "$subpkgdir"/usr/share
[ "$(ls -A "$pkgdir"/usr/share)" ] || rmdir "$pkgdir"/usr/share
}
md5sums="093a586f37d2853bdb129231e1b350e0 glib-2.48.0.tar.xz
6eb959b045db81dc552edd2695911671 0001-gquark-make-sure-quark-is-initialized-before-create-.patch"
sha256sums="744be6931ca914c68af98dc38ff6b0cf8381d65e335060faddfbf04c17147c34 glib-2.48.0.tar.xz
bdddb06d2a3aaccb5846e4a3f9ae1b052d6606384d6159c2d6bf3796e28759dc 0001-gquark-make-sure-quark-is-initialized-before-create-.patch"
sha512sums="684544bc594d9f6c905495d895daed40b074bcf5fa835aefb9a1034afc9564b2bd464e68d4c378c210e96918ef5d5202350da53a7104794420e990049ddbebf5 glib-2.48.0.tar.xz
8a9cd51ee9f557772e35614d42071e1197c0164d40503871e3e79e116bed6f6a5c8f82fd3f377b5e334f342d2d1df60d404ea0ed885989d7e3412b6795fb5469 0001-gquark-make-sure-quark-is-initialized-before-create-.patch"
|