aboutsummaryrefslogtreecommitdiffstats
path: root/testing/open-iscsi/APKBUILD
blob: ca7bbda17080473a8ad92f853274455ac1bfcc74 (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
# Maintainer: Leonardo Arena <rnalrd@gmail.com>
pkgname=open-iscsi
pkgver=2.0.871
_realver=2.0-871
pkgrel=1
pkgdesc="High performance, transport independent, multi-platform iSCSI initiator"
url="http://www.open-iscsi.org"
license="GPL-2"
depends=
makedepends=
install=""
subpackages="$pkgname-doc"
source="http://www.open-iscsi.org/bits/$pkgname-$_realver.tar.gz
	CVE-2009-1297.patch
	open-iscsi-2.0.871-makefile-cleanup.patch
	iscsid.initd"

_builddir="$srcdir"/$pkgname-$_realver

prepare() {
	cd "$_builddir"
	patch -p0 < ../../CVE-2009-1297.patch || return 1
	patch -p1 < ../../open-iscsi-2.0.871-makefile-cleanup.patch || return 1
}

build() {
	cd "$_builddir"
	make user || return 1
}

package() {
	cd "$_builddir"
	make DESTDIR="$pkgdir" install_user
	mkdir -p $pkgdir/usr/bin
	mkdir -p $pkgdir/usr/sbin
	mv $pkgdir/sbin/iscsi-iname $pkgdir/usr/bin
	mv $pkgdir/sbin/iscsi_discovery $pkgdir/usr/bin
	mv $pkgdir/sbin/iscsiadm $pkgdir/usr/bin
	mv $pkgdir/sbin/iscsid $pkgdir/usr/sbin
	install -Dm755 ../../iscsid.initd "$pkgdir"/etc/init.d/iscsid
}

md5sums="0c403e8c9ad41607571ba0e6e8ff196e  open-iscsi-2.0-871.tar.gz
d1584790b4e12f087e60089880b53d2b  CVE-2009-1297.patch
734300d7b7590dc9ae9b2fb7f5b51bf0  open-iscsi-2.0.871-makefile-cleanup.patch
3e89cb86395756dafebc4f1490f0de10  iscsid.initd"