From 7bc4a6d17e9f920214002a68113c06386fab0222 Mon Sep 17 00:00:00 2001 From: John Vogel Date: Sun, 16 Apr 2023 02:55:22 -0400 Subject: mkinitfs: delete fork --- mkinitfs/mkinitfs.trigger | 37 ------------------------------------- 1 file changed, 37 deletions(-) delete mode 100644 mkinitfs/mkinitfs.trigger (limited to 'mkinitfs/mkinitfs.trigger') diff --git a/mkinitfs/mkinitfs.trigger b/mkinitfs/mkinitfs.trigger deleted file mode 100644 index 35b13c0..0000000 --- a/mkinitfs/mkinitfs.trigger +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/sh - -CONFIG='/etc/mkinitfs/mkinitfs.conf' -if [ -f "$CONFIG" ]; then - case "$(. "$CONFIG" >/dev/null; printf %s "$disable_trigger")" in - yes | YES | true | TRUE | 1) exit 0;; - esac -fi - -for i in "$@"; do - # get last element in path - flavor=${i##*/} - if ! [ -f "$i"/kernel.release ]; then - # kernel was uninstalled - rm -f $( readlink -f /boot/initramfs-$flavor ) \ - /boot/initramfs-$flavor /boot/vmlinuz-$flavor \ - /boot/$flavor /boot/$flavor.gz /$flavor /$flavor.gz - continue - fi - abi_release=$(cat "$i"/kernel.release) - initfs=initramfs-$flavor - mkinitfs -o /boot/$initfs $abi_release || { - echo " mkinitfs failed!" >2 - echo " your system may not be bootable" >2 - exit 1 - } -done - -# extlinux will use path relative partition, so if /boot is on a -# separate partition we want /boot/ resolve to / -if ! [ -e /boot/boot ]; then - ln -sf . /boot/boot 2>/dev/null # silence error in case of FAT -fi - -# sync only the filesystem on /boot as that is where we are writing the initfs. -sync -f /boot -exit 0 -- cgit v1.2.3