aboutsummaryrefslogtreecommitdiffstats
path: root/main/usbredir/APKBUILD
blob: 868238f0c469319503ca12e23da5a0ad7eb0bc6f (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
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=usbredir
pkgver=0.7
pkgrel=2
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
	Initialize-usb_redir_hello_header-to-0-in-usbredirparser_init.patch
	usbredirhost-Add-2798-0001-to-the-do-not-reset-blacklist.patch
	usbredirtestclient-Fix-a-memory-leak.patch
	"

_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
}

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

md5sums="bc096f160e4ebb848c3a0f0fbf9500fc  usbredir-0.7.tar.bz2
ad93b58e63ba30c1df2f0fc933eb7d74  Initialize-usb_redir_hello_header-to-0-in-usbredirparser_init.patch
a56584d5298fb196851ccaa7525c19d2  usbredirhost-Add-2798-0001-to-the-do-not-reset-blacklist.patch
227300e89ac76ffcc1e15248408a8a73  usbredirtestclient-Fix-a-memory-leak.patch"
sha256sums="0a63a0712b5dc62be9cca44f97270fea5d1ec1fe7dde0c11dc74a01c8e2006aa  usbredir-0.7.tar.bz2
9c00ec29047575a1875f0128bf4bf4798c459bb98952e468bab73824d03283e9  Initialize-usb_redir_hello_header-to-0-in-usbredirparser_init.patch
eae2360f95883c8aa87c1e1a92c532dbd05493d863288fdbf90d437de80cf264  usbredirhost-Add-2798-0001-to-the-do-not-reset-blacklist.patch
dc8c8950f880294cc53373904eb98b0e9ae8cdd802d293bcde007bbe5b4de26a  usbredirtestclient-Fix-a-memory-leak.patch"
sha512sums="f615fc52f195c7159d16b551f6ecd9426f2aad64222f24b964fbd66fbf59498d80d4d5cf851cc1be9ddd27a9d962afa05970e1379f1ef02e8ac304235e82ad4a  usbredir-0.7.tar.bz2
a5b0813a98507b22616341814b997b04a2d0259b75d3a6e39c85d9e85e92a422b29edfbb023749e5dc8a2c680858e6ffc4b3ec5b97c077ab99f57c8bc05c799e  Initialize-usb_redir_hello_header-to-0-in-usbredirparser_init.patch
150ac5c43cf0f353e19da61a9a8abe8400c929fe435f2b6184b1f4cf1998083eda559cce3113e4a493e106036fb69a216652964bf7bef464aa17a84e07105166  usbredirhost-Add-2798-0001-to-the-do-not-reset-blacklist.patch
3bd98d50571f3682359a15401d46dee9ba9f2727ca94ecf47eae826f438fc9a224627510715d0535a08e35e72f97827162704ecdfe0b06a0cc81f0bbd0d19d33  usbredirtestclient-Fix-a-memory-leak.patch"