diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2010-04-21 14:03:07 +0000 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2010-04-21 14:05:18 +0000 |
commit | 28d3a986488900f1d15ec23d02f6f264bc8fe692 (patch) | |
tree | a93b94ac3dd262dfe2ec31ab423af833b1fccd32 /testing/iscsi-scst-grsec | |
parent | 83f962b250b35e5ad6f5c4949ad53cc5e2b5f2c2 (diff) | |
download | aports-28d3a986488900f1d15ec23d02f6f264bc8fe692.tar.bz2 aports-28d3a986488900f1d15ec23d02f6f264bc8fe692.tar.xz |
main/iscsi-scst-grsec: new aport
grsec ISCSI for SCST
http://scst.sourceforge.net/
Diffstat (limited to 'testing/iscsi-scst-grsec')
-rw-r--r-- | testing/iscsi-scst-grsec/APKBUILD | 60 | ||||
-rw-r--r-- | testing/iscsi-scst-grsec/config.c.patch | 12 |
2 files changed, 72 insertions, 0 deletions
diff --git a/testing/iscsi-scst-grsec/APKBUILD b/testing/iscsi-scst-grsec/APKBUILD new file mode 100644 index 0000000000..0fae6a7477 --- /dev/null +++ b/testing/iscsi-scst-grsec/APKBUILD @@ -0,0 +1,60 @@ +# Contributor: Carlo Landmeter +# Maintainer: Natanael Copa <ncopa@alpinelinux.org> + +_flavor=${FLAVOR:-grsec} +_realname=iscsi-scst +# source the kernel version +if [ -f ../../main/linux-$_flavor/APKBUILD ]; then + . ../../main/linux-$_flavor/APKBUILD +fi +_kver=$pkgver +_kernelver=$pkgver-r$pkgrel +_abi_release=$pkgver-${_flavor} +_kpkgrel=$pkgrel + +_realver=1.0.1.1 +pkgname=${_realname}-${_flavor} +pkgver=$_kver +_mypkgrel=0 +pkgrel=$(($_kpkgrel + $_mypkgrel)) +pkgdesc="$_flavor ISCSI for SCST $_realver" +url="http://scst.sourceforge.net/" +license="GPL-2" +depends="linux-${_flavor}=${_kernelver}" +install= +makedepends="linux-${_flavor}-dev=${_kernelver} openssl-dev scst-grsec-dev" +subpackages= +source="http://downloads.sourceforge.net/scst/$_realname-$_realver.tar.gz + config.c.patch + " +_ksrc=/usr/src/linux-headers-${_abi_release} + +_builddir="$srcdir"/$_realname-$_realver +prepare() { + cd "$_builddir" + for i in "$srcdir"/*.patch; do + [ -f "$i" ] || continue + msg "Applying $i" + patch -p1 -i $i || return 1 + done + # to build mods we need the headre file. fix dependency in makefile + sed -i -e 's/^\(mods: .*\)/\1 include\/iscsi_scst_itf_ver.h/' Makefile +} + +build() { + cd "$_builddir" + unset ARCH + make mods \ + KDIR="$_ksrc" \ + SCST_INC_DIR=/usr/include/scst \ + || return 1 +} + +package() { + cd "$_builddir" + install -D -m 644 kernel/iscsi-scst.ko \ + "$pkgdir"/lib/modules/$_abi_release/extra/iscsi-scst.ko +} + +md5sums="56109c01e3d4421a36d6f47efa1fb0d5 iscsi-scst-1.0.1.1.tar.gz +48e21e3466fd819418f29e3b2487f052 config.c.patch" diff --git a/testing/iscsi-scst-grsec/config.c.patch b/testing/iscsi-scst-grsec/config.c.patch new file mode 100644 index 0000000000..e3b1523218 --- /dev/null +++ b/testing/iscsi-scst-grsec/config.c.patch @@ -0,0 +1,12 @@ +--- iscsi-scst/kernel/config.c 2009/05/11 17:24:51 841 ++++ iscsi-scst/kernel/config.c 2009/07/08 17:27:30 938 +@@ -203,7 +203,9 @@ + goto out; + } + ++#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 30) + proc_iscsi_dir->owner = THIS_MODULE; ++#endif + + err = iscsi_proc_log_entry_build(&iscsi_template); + if (err < 0) |