Merge remote-tracking branch 'origin/pr/242'
[grml-debootstrap.git] / grml-debootstrap
index 4b04e00..76c3648 100755 (executable)
@@ -601,7 +601,7 @@ done
 [ "$_opt_contrib" ]             && COMPONENTS="$COMPONENTS contrib"
 
 case "${RELEASE}" in
-  lenny|squeeze|wheezy|jessie|stretch|buster|bullseye)
+  jessie|stretch|buster|bullseye)
     [ "$_opt_non_free" ] && COMPONENTS="$COMPONENTS non-free"
     ;;
   *)
@@ -926,16 +926,10 @@ while IFS= read -r i; do
   NUM_PARTITIONS=$(( NUM_PARTITIONS + 1 ))
 done < "$TMPFILE"
 
-# force metadata version 0.90 for lenny so old grub can boot from this array.
-METADATA_VERSION=""
-if [ "$RELEASE" = "lenny" ]; then
-   METADATA_VERSION="-e0"
-fi
-
 ERRORFILE=$(mktemp)
 # shellcheck disable=SC2086
 yes | mdadm --create "${TARGET}" --level="${RAIDLEVEL}" \
-      --raid-devices="${NUM_PARTITIONS}" ${METADATA_VERSION} ${SELECTED_PARTITIONS} >/dev/null 2>$ERRORFILE
+      --raid-devices="${NUM_PARTITIONS}" ${SELECTED_PARTITIONS} >/dev/null 2>$ERRORFILE
 RC=$?
 if [ "$RC" = 0 ] ; then
    dialog --title "$PN" --msgbox \
@@ -1303,7 +1297,7 @@ mkfs() {
   # so disable this feature for older Debian releases where it's known to be unsupported
   if [ -n "$MKFS" ] && [ "$MKFS" = "mkfs.ext4" ] ; then
     case "$RELEASE" in
-      lenny|squeeze|wheezy|jessie)
+      jessie)
         # assume a more recent version if we can't identify the version via dpkg-query
         local e2fsprogs_version
         e2fsprogs_version="$(dpkg-query --show --showformat='${Version}' e2fsprogs 2>/dev/null || echo 1.44)"
@@ -1320,7 +1314,7 @@ mkfs() {
   # Disable this feature for Debian releases older than bookworm
   if [ -n "$MKFS" ] && [ "$MKFS" = "mkfs.ext4" ] ; then
     case "$RELEASE" in
-      lenny|squeeze|wheezy|jessie|stretch|buster|bullseye)
+      jessie|stretch|buster|bullseye)
         local e2fsprogs_version
         # assume a more recent version if we can't identify the version via dpkg-query
         e2fsprogs_version="$(dpkg-query --show --showformat='${Version}' e2fsprogs 2>/dev/null || echo 1.47)"
@@ -1618,15 +1612,7 @@ grub_install() {
       eerror "Error: grub not installed inside Virtual Machine. Can not install bootloader." ; eend 1
       bailout 1
     fi
-
-    case "$RELEASE" in
-      lenny|squeeze|wheezy)
-        cp "${MNTPOINT}"/usr/lib/grub/i386-pc/* "${MNTPOINT}/boot/grub/"
-        ;;
-      *)
-        cp -a "${MNTPOINT}"/usr/lib/grub/i386-pc "${MNTPOINT}/boot/grub/"
-        ;;
-    esac
+    cp -a "${MNTPOINT}"/usr/lib/grub/i386-pc "${MNTPOINT}/boot/grub/"
 
     if [ -n "$VMEFI" ]; then