apparmor: update to 2.13.1.

Also cleanup the template a little
This commit is contained in:
Rasmus Thomsen 2018-10-21 14:22:17 +02:00 committed by maxice8
parent c280da2e44
commit 485822d38b
2 changed files with 17 additions and 48 deletions

View file

@ -1,19 +0,0 @@
# vim:syntax=apparmor
#include <tunables/global>
profile ping /{usr/,}bin/iputils-ping {
#include <abstractions/base>
#include <abstractions/consoles>
#include <abstractions/nameservice>
capability net_raw,
capability setuid,
network inet raw,
network inet6 raw,
/{usr/,}bin/iputils-ping mixr,
/etc/modules.conf r,
# Site-specific additions and overrides. See local/README for details.
#include <local/usr.bin.iputils-ping>
}

View file

@ -1,15 +1,16 @@
# Template file for 'apparmor'
pkgname=apparmor
version=2.13.0
revision=7
version=2.13.1
revision=1
build_style=gnu-configure
_short_ver=${version%\.*}
wrksrc="${pkgname}-v${_short_ver}"
build_wrksrc="libraries/libapparmor"
build_wrksrc=libraries/libapparmor
patch_args="-Np1"
hostmakedepends="bison flex autoconf automake libtool swig python3"
makedepends="perl python3-devel"
depends="runit-void-apparmor python3 libapparmor"
checkdepends="dejagnu"
short_desc="Mandatory access control to restrict programs"
maintainer="Olivier Mauras <olivier@mauras.ch>"
license="GPL-2.0-only, LGPL-2.1-only"
@ -24,7 +25,7 @@ if [ -z "$CROSS_BUILD" ]; then
fi
pre_configure() {
NOCONFIGURE=1 ./autogen.sh
autoreconf -if
}
pre_build() {
@ -33,37 +34,24 @@ pre_build() {
# Put in place our own profiles
cp ${FILESDIR}/profiles/* profiles/apparmor.d/
mv profiles/apparmor.d/bin.ping profiles/apparmor/profiles/extras/
}
post_build() {
cd ${wrksrc}/binutils
make ${makejobs}
cd ${wrksrc}/utils
make ${makejobs}
cd ${wrksrc}/parser
sed -i 's#$(DESTDIR)/sbin#$(DESTDIR)/usr/bin#g' Makefile
sed -i 's#${DESTDIR}/lib#${DESTDIR}/usr/lib#g' Makefile
make ${makejobs}
cd ${wrksrc}/profiles
make ${makejobs}
cd ${wrksrc}
sed -i 's#$(DESTDIR)/sbin#$(DESTDIR)/usr/bin#g' parser/Makefile
make ${makejobs} -C binutils
make ${makejobs} -C utils
make ${makejobs} -C parser
make ${makejobs} -C profiles
}
post_install() {
cd ${wrksrc}/binutils
make DESTDIR=${DESTDIR} install
cd ${wrksrc}/utils
make DESTDIR=${DESTDIR} BINDIR=${DESTDIR}/usr/bin install
cd ${wrksrc}/parser
make DESTDIR=${DESTDIR} install
cd ${wrksrc}/profiles
make DESTDIR=${DESTDIR} install
cd ${wrksrc}
make DESTDIR=${DESTDIR} install -C binutils
make DESTDIR=${DESTDIR} BINDIR=${DESTDIR}/usr/bin install -C utils
make DESTDIR=${DESTDIR} APPARMOR_BIN_PREFIX=${DESTDIR}/usr/lib/apparmor \
SBINDIR=${DESTDIR}/usr/bin USR_SBINDIR=${DESTDIR}/usr/bin install -C parser
make DESTDIR=${DESTDIR} install -C profiles
# Put Vim syntax in the correct place
mkdir -p ${DESTDIR}/usr/share/vim/vim80/syntax/