summaryrefslogtreecommitdiffstats
path: root/main/gradm/APKBUILD
diff options
context:
space:
mode:
authorWilliam Pitcock <nenolod@dereferenced.org>2011-02-08 00:07:08 -0600
committerWilliam Pitcock <nenolod@dereferenced.org>2011-02-08 00:07:08 -0600
commit4e75b2fc40c44c49152adb497660f6189261a929 (patch)
tree28cce9c750130277da370ca2cb1087c6c0b6010b /main/gradm/APKBUILD
parentb87391cc121aafd3de4c59466696a3b63dde8964 (diff)
downloadaports-4e75b2fc40c44c49152adb497660f6189261a929.tar.bz2
aports-4e75b2fc40c44c49152adb497660f6189261a929.tar.xz
testing/gradm: move to main
Diffstat (limited to 'main/gradm/APKBUILD')
-rw-r--r--main/gradm/APKBUILD57
1 files changed, 57 insertions, 0 deletions
diff --git a/main/gradm/APKBUILD b/main/gradm/APKBUILD
new file mode 100644
index 000000000..08dbd3af0
--- /dev/null
+++ b/main/gradm/APKBUILD
@@ -0,0 +1,57 @@
+# Contributor: William Pitcock <nenolod@dereferenced.org>
+# Maintainer: William Pitcock <nenolod@dereferenced.org>
+pkgname=gradm
+pkgver=2.2.0
+pkgrel=5
+pkgdesc="administrative utility for grsecurity kernels"
+url="http://www.grsecurity.org/"
+arch="all"
+license="GPL"
+makedepends="bison flex"
+install=""
+subpackages="$pkgname-doc"
+source="http://grsecurity.net/stable/gradm-2.2.0-201011061849.tar.gz
+ policy
+ base.policyd
+ grsec-rbac.initd"
+
+_builddir="$srcdir/gradm2"
+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"
+ make || return 1
+}
+
+package() {
+ cd "$_builddir"
+ make DESTDIR="$pkgdir" install || return 1
+
+ # we don't want the grsecurity-recommended policy as it's old
+ # and non-modular.
+ rm "$pkgdir"/etc/grsec/policy
+
+ # install the base policy file which pulls in everything else.
+ install -m644 "$srcdir"/policy "$pkgdir"/etc/grsec/policy
+
+ # prepare and install base policy to /var/lib/grsec/policy.d
+ install -d -D "$pkgdir"/var/lib/grsec/policy.d
+ install -m644 "$srcdir"/base.policyd "$pkgdir"/var/lib/grsec/policy.d/00-base
+
+ # install grsec-rbac into initd
+ install -d -D "$pkgdir"/etc/init.d
+ install -m755 "$srcdir"/grsec-rbac.initd "$pkgdir"/etc/init.d/grsec-rbac
+}
+
+md5sums="081765637a407dd7e4cd07f95413d6b8 gradm-2.2.0-201011061849.tar.gz
+38ee3aef884bdcfe6a5b925760f6220b policy
+1d4a2c2e522b7124ad901ae102181e72 base.policyd
+2fc5d055dd43a2d9e1bed378dcab8641 grsec-rbac.initd"