X-Git-Url: http://git.grml.org/?p=grml-autoconfig.git;a=blobdiff_plain;f=autoconfig.functions;h=c6ed6f2e19e5166070ffa5dd7102e19e48a4f69c;hp=7638ecca97edf38059723f8a3c19305b52f272a3;hb=5ee166c50786a23547bc40b05d86559a1c325283;hpb=20365ddcfab071d7447b346a6ebf804b56d394b6 diff --git a/autoconfig.functions b/autoconfig.functions index 7638ecc..c6ed6f2 100755 --- a/autoconfig.functions +++ b/autoconfig.functions @@ -512,6 +512,14 @@ config_kernel(){ # {{{ secure boot config_secureboot(){ + # systemd does this for us, but if we are not running under systemd then mokutil + # doesn't work as needed as it relies on /sys/firmware/efi/efivars (while + # /sys/firmware/efi/vars would exist) + if ! $SYSTEMD ; then + modprobe efivars + mount -t efivarfs efivarfs /sys/firmware/efi/efivars + fi + if [ -x /usr/bin/mokutil ] ; then local secstate=$(mokutil --sb-state 2>/dev/null) # "SecureBoot enabled" if [ -n "$secstate" ] ; then @@ -1317,6 +1325,10 @@ if checkbootparam 'startx' && ! echo "$CMDLINE" | grep -q 'startx.*nostartx' ; t einfo "Setting up and invoking grml-x ${WINDOWMANAGER}. Just exit X windows system to get full featured consoles." config_userlocal if $SYSTEMD ; then + if [ -n "$WINDOWMANAGER" ] ; then + mkdir -p /var/run/grml-x/ + echo "$WINDOWMANAGER" > /var/run/grml-x/window-manager + fi chvt 7 return fi