OSDN Git Service

more work on 66-void:
authormobinmob <mobinmob@disroot.org>
Wed, 5 Oct 2022 17:50:56 +0000 (20:50 +0300)
committermobinmob <mobinmob@disroot.org>
Sun, 9 Oct 2022 15:03:37 +0000 (18:03 +0300)
- remove apparmor - it belongs to boot-66serv
- make it a more proper package, prepare for removal of runit bits
that are not needed for the runit 66 service.

srcpkgs/66-void/files/09-apparmor.sh [deleted file]
srcpkgs/66-void/files/apparmor [deleted file]
srcpkgs/66-void/runit-void-apparmor.INSTALL [deleted file]
srcpkgs/66-void/template

diff --git a/srcpkgs/66-void/files/09-apparmor.sh b/srcpkgs/66-void/files/09-apparmor.sh
deleted file mode 100644 (file)
index 1d24b4e..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-# vim: set ts=4 sw=4 et:
-
-# AppArmor is not enabled in kernel, silently exit
-[ ! -d /sys/kernel/security/apparmor ] && return
-
-# Load config
-[ -r /etc/default/apparmor ] && . /etc/default/apparmor
-
-# Proceed to load profiles depending on user settings
-msg "Loading AppArmor profiles..."
-
-if [ -n "$APPARMOR" ]; then
-       if [ "$APPARMOR" != "complain" -a "$APPARMOR" != "enforce" ]; then
-               printf '! AppArmor set to %s - ignoring profiles\n' "$APPARMOR"
-               return
-       fi
-
-       [ "$APPARMOR" = "complain" ] && AACOMPLAIN="-C"
-
-       if [ -d /etc/apparmor.d -a -x /usr/bin/apparmor_parser ]; then
-               apparmor_parser -a $AACOMPLAIN $(find /etc/apparmor.d -maxdepth 1 -type f ! -name '*.new-*_*')
-       else
-               printf '! AppArmor installation problem - ensure you have installed apparmor package\n'
-       fi
-else
-       printf '! AppArmor disabled - ignoring profiles\n'
-fi
diff --git a/srcpkgs/66-void/files/apparmor b/srcpkgs/66-void/files/apparmor
deleted file mode 100644 (file)
index b32ce11..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-# AppArmor configuration
-
-# Possible options:
-# - disable
-# - complain
-# - enforce
-APPARMOR=complain
diff --git a/srcpkgs/66-void/runit-void-apparmor.INSTALL b/srcpkgs/66-void/runit-void-apparmor.INSTALL
deleted file mode 100644 (file)
index 54b8e2d..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-case "$ACTION" in
-pre)
-  # Fix incorrect path in /etc/default
-  if [ -e /etc/default/apparmor/rc.apparmor ]; then
-    mv /etc/default/apparmor/rc.apparmor /etc/default/rc.apparmor
-    rm -rf /etc/default/apparmor
-    mv /etc/default/rc.apparmor /etc/default/apparmor
-  fi
-  if [ -d /etc/default/apparmor ]; then
-    rm -rf /etc/default/apparmor
-  fi
-       ;;
-esac
index cfa44f3..5a19ac1 100644 (file)
@@ -3,15 +3,15 @@
 # the void-runit repository.
 pkgname=66-void
 version=20220308
-_version=20210314
 revision=1
-wrksrc="void-runit-${_version}"
+_void_runit_version=20210314
+wrksrc="void-runit-${_void_runit_version}"
 build_style=gnu-makefile
-short_desc="Void Linux runit scripts"
+short_desc="Void Linux base package, adapted for 66"
 maintainer="mobinmob <mobinmob@disroot.org>"
 license="CC0-1.0"
 homepage="https://github.com/void-linux/void-runit"
-distfiles="https://github.com/void-linux/void-runit/archive/${_version}.tar.gz"
+distfiles="https://github.com/void-linux/void-runit/archive/${_void_runit_version}.tar.gz"
 checksum=9ac95a14b5e1aedfcf0b093b8992b08316448ac1afb7fd26501ac43c4ebf3847
 replaces="runit-void>=0"
 
@@ -28,23 +28,10 @@ post_install() {
        vconf ${FILESDIR}/hostname
        vconf ${FILESDIR}/os-release
        vconf ${FILESDIR}/locale.conf
-       vinstall ${FILESDIR}/apparmor 644 /etc/default/
-       vinstall ${FILESDIR}/09-apparmor.sh 644 /etc/runit/core-services/
        # Create symlinks for init and init utilities
        ln -s /usr/bin/66 "${DESTDIR}"/usr/bin/init
        for i in reboot poweroff halt shutdown;
                do
                ln -s /etc/66/${i} "${DESTDIR}"/usr/bin/${i}
                done
-       
 }
-
-#66-void-apparmor_package() {
-#      short_desc+=" - AppArmor initialization"
-#      depends="${sourcepkg}-${version}_${revision}"
-#      conf_files="/etc/default/apparmor"
-#      pkg_install() {
-#              vmove etc/default/apparmor
-#              vmove etc/runit/core-services/09-apparmor.sh
-#      }
-#}