diff --git a/modlists/legacy b/modlists/legacy new file mode 100644 index 0000000..4febc1c --- /dev/null +++ b/modlists/legacy @@ -0,0 +1 @@ +legacy-initramfs \ No newline at end of file diff --git a/mods/legacy-initramfs/data/chroot b/mods/legacy-initramfs/data/chroot new file mode 100755 index 0000000..6709bbd --- /dev/null +++ b/mods/legacy-initramfs/data/chroot @@ -0,0 +1,4 @@ +#!/bin/bash +set -e +apt -y install findutils file xz-utils +update-initramfs -u \ No newline at end of file diff --git a/mods/legacy-initramfs/data/etc/initramfs-tools/conf.d/00-legacy-initramfs b/mods/legacy-initramfs/data/etc/initramfs-tools/conf.d/00-legacy-initramfs new file mode 100644 index 0000000..de32d0e --- /dev/null +++ b/mods/legacy-initramfs/data/etc/initramfs-tools/conf.d/00-legacy-initramfs @@ -0,0 +1,2 @@ +#MODULES=list +COMPRESS=xz diff --git a/mods/legacy-initramfs/data/etc/live/boot/00-legacy b/mods/legacy-initramfs/data/etc/live/boot/00-legacy new file mode 100644 index 0000000..2161b80 --- /dev/null +++ b/mods/legacy-initramfs/data/etc/live/boot/00-legacy @@ -0,0 +1,5 @@ +DISABLE_FAT=true +DISABLE_FUSE=true +DISABLE_NTFS=true +DISABLE_USB=true +MINIMAL=true \ No newline at end of file diff --git a/mods/legacy-initramfs/data/usr/bin/wdvn-cat b/mods/legacy-initramfs/data/usr/bin/wdvn-cat new file mode 100755 index 0000000..90625d3 --- /dev/null +++ b/mods/legacy-initramfs/data/usr/bin/wdvn-cat @@ -0,0 +1,2 @@ +#!/bin/sh +cat "$2" \ No newline at end of file diff --git a/mods/legacy-initramfs/data/usr/local/bin/update-initramfs b/mods/legacy-initramfs/data/usr/local/bin/update-initramfs new file mode 100755 index 0000000..2e6fc23 --- /dev/null +++ b/mods/legacy-initramfs/data/usr/local/bin/update-initramfs @@ -0,0 +1,12 @@ +#!/bin/bash +set -e +>&2 echo "Compressing modules ..." +for i in $(find /lib/modules -name "*.ko"); do + if [ "$(file "$i"|grep ELF)" != "" ]; then + >&2 echo "> $i ..." + xz -1 $i + mv $i.xz $i + fi +done +/usr/sbin/update-initramfs $* +exit $? \ No newline at end of file