diff options
Diffstat (limited to 'testing')
-rw-r--r-- | testing/py-rtslib/APKBUILD | 61 |
1 files changed, 61 insertions, 0 deletions
diff --git a/testing/py-rtslib/APKBUILD b/testing/py-rtslib/APKBUILD new file mode 100644 index 000000000..1646a2f71 --- /dev/null +++ b/testing/py-rtslib/APKBUILD @@ -0,0 +1,61 @@ +# Contributor: Leonardo Arena <rnalrd@alpinelinux.org> +# Maintainer: Natanael Copa <ncopa@alpinelinux.org> +pkgname=py-rtslib +_realname=rtslib +pkgver=2.1_p9 +_ver=${pkgver/_rc/rc} +_ver=${_ver/_p/.fb} +pkgrel=0 +pkgdesc="Python library that provides an object API to RisingTide Systems generic SCSI Target" +url="https://github.com/agrover/rtslib-fb" +arch="noarch" +license="AGPLv3" +depends="python" +depends_dev="py-configobj py-ethtool py-ipaddr" +makedepends="$depends_dev" +install="" +subpackages= +source="http://dev.alpinelinux.org/archive/targetcli/$_realname-$_ver.tar.gz" + +_giturl="https://github.com/agrover/rtslib-fb.git" +_gittag=v$_ver + +_builddir="$srcdir"/$_realname + +snapshot() { + mkdir -p "$srcdir" + cd "${SRCDEST:-$srcdir}" + if ! [ -d $_realname-fb.git ]; then + git clone --bare $_giturl || return 1 + cd $_realname-fb.git + else + cd $_realname-fb.git + git fetch || return 1 + fi + + git archive --prefix=$_realname/ -o "$SRCDEST"/$_realname-$_ver.tar.gz $_gittag + scp "$SRCDEST"/$_realname-$_ver.tar.gz dev.alpinelinux.org:/archive/$_realname +} + + +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" + return 0 +} + +package() { + cd "$_builddir" + python setup.py install --root="$pkgdir" +} + +md5sums="35ca95f1204d90ad8ad892b041da4bf9 rtslib-2.1.fb9.tar.gz" |