summaryrefslogtreecommitdiffstats
path: root/main/spice-gtk/APKBUILD
blob: 3a45b486a556d26a04ac959aeb074f8594dcbbb6 (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
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=spice-gtk
pkgver=0.20
pkgrel=1
pkgdesc="A GTK+ widget for SPICE clients"
url="http://spice-space.org/page/Spice-Gtk"
arch="all"
license="LGPLv2+"
depends=""
depends_dev="gtk+3.0-dev celt051-dev polkit-dev libxrandr-dev openssl-dev
	cyrus-sasl-dev gst-plugins-base-dev jpeg-dev zlib-dev acl-dev"
makedepends="$depends_dev bash usbutils python-dev udev-dev
	usbredir-dev libusbx-dev
	polkit-dev py-parsing gobject-introspection-dev
	"
install=""
subpackages="$pkgname-dev $pkgname-doc $pkgname-lang $pkgname-tools
	spice-glib:glib"

source="http://www.spice-space.org/download/gtk/spice-gtk-$pkgver.tar.bz2"

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

build() {
	cd "$_builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--with-gtk=3.0 \
		--with-audio=gstreamer \
		--enable-smartcard=no \
		--enable-usbredir=yes \
		|| return 1
	make || return 1
}

package() {
	cd "$_builddir"
	make -j1 DESTDIR="$pkgdir" install || return 1
	rm -f "$pkgdir"/usr/lib/*.la \
		"$pkgdir"//usr/lib/py*/site-packages/*.la
}

tools() {
	pkgdesc=""
	mkdir -p "$subpkgdir"/usr
	mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}

glib() {
	pkgdesc=""
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/*-glib-*.so* \
		"$pkgdir"/usr/lib/*controller.so.* \
		"$subpkgdir"/usr/lib/ || return 1
	cd "$pkgdir"
	for i in $(find -name GLib*.typelib); do
		mkdir -p "$subpkgdir"/${i%/*}
		mv $i "$subpkgdir"/${i%/*}
	done
}

md5sums="9ef6b7f2f368b7966029b7834b7c2bec  spice-gtk-0.20.tar.bz2"
sha256sums="b1355823b0ceb2e118c1f9a9a602ccab78e1e2edf2d93f71fa42d3bc85ca75df  spice-gtk-0.20.tar.bz2"
sha512sums="db07d05d93bf5639c193f374b6eb3fe9f6bb198f0146e64f8e6e6c03d12e931c1f18a353aed123fe28535a95eb8448ef8a8babc66bdd283f951b8433839d6b9e  spice-gtk-0.20.tar.bz2"