summaryrefslogtreecommitdiff
path: root/community/libplist/APKBUILD
blob: 2833adde267f3d9e3dcff68a8f7c517d5b29f928 (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=libplist
pkgver=2.0.0
pkgrel=0
pkgdesc="A library to handle Apple Property List format whereas it's binary or XML"
url="http://libimobiledevice.org/"
arch="all"
license="GPL2 LGPL2.1"
depends=""
depends_dev="libxml2-dev glib-dev"
makedepends="swig python2-dev $depends_dev cython-dev python2 cython"
subpackages="$pkgname-dev py-$pkgname:py $pkgname-util $pkgname++:cxx"
source="http://www.libimobiledevice.org/downloads/libplist-$pkgver.tar.bz2"

_builddir="$srcdir"/build
_src="$srcdir"/$pkgname-$pkgver
build() {
	cd "$srcdir"
	mkdir -p "$_builddir"
	cd "$_builddir"
	$_src/configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--mandir=/usr/share/man \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install || return 1
}

util() {
	pkgdesc="Util for libplist"
	mkdir -p "$subpkgdir"/usr
	mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}

py() {
	pkgdesc="Python bindings for libplist"
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/python* "$subpkgdir"/usr/lib/
}

cxx() {
	pkgdesc="C++ bindings to libplist"
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/*++.so.* "$subpkgdir"/usr/lib/
}

sha512sums="81508bf6773483528816725c3b5b868563b84fd7810999404072e5ea9efa7fc9f11ef997f32208e4421aa26b15edd0c65f87c67c1472e8c4e356f1e9fe7740ee  libplist-2.0.0.tar.bz2"