aboutsummaryrefslogtreecommitdiffstats
path: root/main/usbredir/APKBUILD
blob: b56234c30fbfa668ee3d4abcb498e247a99b466a (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=usbredir
pkgver=0.7
pkgrel=1
pkgdesc="USB network redirection protocol libraries"
url="http://spice-space.org/page/UsbRedir"
arch="all"
license="GPL2+ LGPL2+"
depends=""
depends_dev="libusb-dev"
makedepends="$depends_dev"
install=""
subpackages="$pkgname-dev $pkgname-doc $pkgname-server"
source="http://spice-space.org/download/usbredir/usbredir-$pkgver.tar.bz2"

_builddir="$srcdir"/usbredir-$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 \
		--infodir=/usr/share/info \
		--localstatedir=/var \
		--disable-static \
		|| return 1
	make || return 1
}

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

server() {
	pkgdesc="Simple USB host TCP server"
	mkdir -p "$subpkgdir"/usr
	mv "$pkgdir"/usr/sbin "$subpkgdir"/usr/
}

md5sums="bc096f160e4ebb848c3a0f0fbf9500fc  usbredir-0.7.tar.bz2"
sha256sums="0a63a0712b5dc62be9cca44f97270fea5d1ec1fe7dde0c11dc74a01c8e2006aa  usbredir-0.7.tar.bz2"
sha512sums="f615fc52f195c7159d16b551f6ecd9426f2aad64222f24b964fbd66fbf59498d80d4d5cf851cc1be9ddd27a9d962afa05970e1379f1ef02e8ac304235e82ad4a  usbredir-0.7.tar.bz2"