mirror of
https://github.com/roddhjav/apparmor.d.git
synced 2024-11-16 00:13:48 +01:00
29 lines
517 B
Bash
29 lines
517 B
Bash
#!/usr/bin/env bash
|
|
set -eu
|
|
|
|
export BUILDDIR=/tmp/build/ PKGDEST=/tmp/pkg
|
|
|
|
# shellcheck source=/dev/null
|
|
_lsb_release() {
|
|
. /etc/os-release || exit 1
|
|
echo "$ID"
|
|
}
|
|
DISTRIBUTION="$(_lsb_release)"
|
|
|
|
cd "$HOME/Projects/apparmor.d"
|
|
case "$DISTRIBUTION" in
|
|
arch)
|
|
make pkg
|
|
;;
|
|
debian | ubuntu | whonix)
|
|
sudo rm -rf debian/.debhelper/
|
|
make dpkg
|
|
sudo rm -rf debian/.debhelper/
|
|
;;
|
|
opensuse*) make rpm ;;
|
|
*) ;;
|
|
esac
|
|
|
|
sudo rm -rf /etc/apparmor/earlypolicy/
|
|
sudo systemctl restart apparmor || sudo systemctl status apparmor
|