diff --git a/scripts/main.sh b/scripts/main.sh index 7fd4e9c..709bf2e 100644 --- a/scripts/main.sh +++ b/scripts/main.sh @@ -401,6 +401,14 @@ EOF try emerge --verbose sys-fs/cryptsetup fi + if [[ $SYSTEMD == "true" && $USED_LUKS == "true" ]] ; then + einfo "Enabling cryptsetup USE flag on sys-apps/systemd" + echo "sys-apps/systemd cryptsetup" > /etc/portage/package.use/systemd \ + || die "Could not write /etc/portage/package.use/systemd" + einfo "Rebuilding systemd with changed USE flag" + try emerge --verbose --changed-use --oneshot sys-apps/systemd + fi + # Install btrfs-progs if we used btrfs if [[ $USED_BTRFS == "true" ]]; then einfo "Installing btrfs-progs"