aboutsummaryrefslogtreecommitdiffstats
path: root/main/gobject-introspection/APKBUILD
blob: ec2d44235dbe131ce34815947d8f850ca62f1c07 (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=gobject-introspection
pkgver=0.10.8
pkgrel=2
pkgdesc="Introspection system for GObject-based libraries"
url="http://live.gnome.org/GObjectInstrospection"
arch="all"
license="LGPL GPL"
depends_dev="python glib-dev libffi-dev cairo-dev"
makedepends="$depends_dev flex bison python-dev libtool"
depends=
replaces="libgirepository"
source="http://ftp.gnome.org/pub/gnome/sources/$pkgname/${pkgver%.*}/$pkgname-$pkgver.tar.bz2"

# since this is a dev package by definition  we dont bother separate -dev
subpackages="$pkgname-doc $pkgname-dev"

_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
	cd "$_builddir"
	for i in $source; do
		case $i in
		*.patch)
			msg "Applying $i"
			patch -p1 -i "$srcdir"/$i || return 1
			;;
		esac
	done
}

build() {
	cd "$_builddir"
	./configure --prefix=/usr --disable-static || return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
	find "$pkgdir" -name '*.la' -delete
}

dev() {
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/share "$subpkgdir"/usr/ || return 1
	mv "$pkgdir"/usr/lib/gobject-introspection "$subpkgdir"/usr/lib/ \
		|| return 1
	mv "$pkgdir"/usr/bin "$subpkgdir"/usr/ || return 1
	default_dev
	replaces="gobject-introspection"
}

md5sums="b5da58a5327d13b4d1e08b8e42b2456d  gobject-introspection-0.10.8.tar.bz2"