blob: 6f55b50ccf976db72895a6b9ce530039a14a05ef (
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
|
# Contributor: William Pitcock <nenolod@dereferenced.org>
# Maintainer: William Pitcock <nenolod@dereferenced.org>
pkgname=gradm
pkgver=2.2.0
pkgrel=3
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 /etc/grsec/policy.d
install -d -D "$pkgdir"/etc/grsec/policy.d
install -m644 "$srcdir"/base.policyd "$pkgdir"/etc/grsec/policy.d/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
06495eebb8f2346d96c64c133d1614fa policy
9b66076b8e74e3d6a637457e23b5c699 base.policyd
2fc5d055dd43a2d9e1bed378dcab8641 grsec-rbac.initd"
|