]> TLD Linux GIT Repositories - packages/dracut.git/blob - initrd-release.patch
- updated to 059
[packages/dracut.git] / initrd-release.patch
1 diff -urpa dracut-056.orig/modules.d/98dracut-systemd/dracut-cmdline.sh dracut-056/modules.d/98dracut-systemd/dracut-cmdline.sh
2 --- dracut-056.orig/modules.d/98dracut-systemd/dracut-cmdline.sh        2022-02-18 12:32:53.000000000 +0100
3 +++ dracut-056/modules.d/98dracut-systemd/dracut-cmdline.sh     2022-08-28 19:16:30.262174543 +0200
4 @@ -5,7 +5,7 @@ if [ -f /dracut-state.sh ]; then
5  fi
6  type getarg > /dev/null 2>&1 || . /lib/dracut-lib.sh
7  
8 -[ -f /usr/lib/initrd-release ] && . /usr/lib/initrd-release
9 +[ -f /etc/initrd-release ] && . /etc/initrd-release
10  [ -n "$VERSION" ] && info "dracut-$VERSION"
11  
12  if ! getargbool 1 'rd.hostonly'; then
13 diff -urpa dracut-056.orig/modules.d/99base/dracut-lib.sh dracut-056/modules.d/99base/dracut-lib.sh
14 --- dracut-056.orig/modules.d/99base/dracut-lib.sh      2022-02-18 12:32:53.000000000 +0100
15 +++ dracut-056/modules.d/99base/dracut-lib.sh   2022-08-28 19:16:30.263174545 +0200
16 @@ -385,7 +385,7 @@ splitsep() {
17  }
18  
19  setdebug() {
20 -    [ -f /usr/lib/initrd-release ] || return
21 +    [ -f /etc/initrd-release ] || return
22      if [ -z "$RD_DEBUG" ]; then
23          if [ -e /proc/cmdline ]; then
24              RD_DEBUG=no
25 diff -urpa dracut-056.orig/modules.d/99base/init.sh dracut-056/modules.d/99base/init.sh
26 --- dracut-056.orig/modules.d/99base/init.sh    2022-08-28 19:12:37.568702916 +0200
27 +++ dracut-056/modules.d/99base/init.sh 2022-08-28 19:16:30.263174545 +0200
28 @@ -102,7 +102,7 @@ else
29      exec 0<> /dev/console 1<> /dev/console 2<> /dev/console
30  fi
31  
32 -[ -f /usr/lib/initrd-release ] && . /usr/lib/initrd-release
33 +[ -f /etc/initrd-release ] && . /etc/initrd-release
34  [ -n "$VERSION_ID" ] && info "$NAME-$VERSION_ID"
35  
36  source_conf /etc/conf.d
37 diff -urpa dracut-056.orig/modules.d/99base/module-setup.sh dracut-056/modules.d/99base/module-setup.sh
38 --- dracut-056.orig/modules.d/99base/module-setup.sh    2022-02-18 12:32:53.000000000 +0100
39 +++ dracut-056/modules.d/99base/module-setup.sh 2022-08-28 19:23:42.688085700 +0200
40 @@ -78,7 +78,7 @@ install() {
41      if [[ -e $dracutsysrootdir/etc/os-release ]]; then
42          # shellcheck disable=SC1090
43          . "$dracutsysrootdir"/etc/os-release
44 -        grep -hE -ve '^VERSION=' -ve '^PRETTY_NAME' "$dracutsysrootdir"/etc/os-release > "${initdir}"/usr/lib/initrd-release
45 +        grep -hE -ve '^VERSION=' -ve '^PRETTY_NAME' "$dracutsysrootdir"/etc/os-release > "${initdir}"/etc/initrd-release
46          [[ -n ${VERSION} ]] && VERSION+=" "
47          [[ -n ${PRETTY_NAME} ]] && PRETTY_NAME+=" "
48      else
49 @@ -89,7 +89,7 @@ install() {
50              echo "ID=dracut"
51              echo "VERSION_ID=\"$DRACUT_VERSION\""
52              echo 'ANSI_COLOR="0;34"'
53 -        } > "${initdir}"/usr/lib/initrd-release
54 +        } > "${initdir}"/etc/initrd-release
55      fi
56      VERSION+="dracut-$DRACUT_VERSION"
57      PRETTY_NAME+="dracut-$DRACUT_VERSION (Initramfs)"
58 @@ -100,10 +100,8 @@ install() {
59          # to easily detect the dracut version if need be without
60          # having it mixed in with the real underlying OS version.
61          echo "DRACUT_VERSION=\"${DRACUT_VERSION}\""
62 -    } >> "$initdir"/usr/lib/initrd-release
63 +    } >> "$initdir"/etc/initrd-release
64      echo "dracut-$DRACUT_VERSION" > "$initdir/lib/dracut/dracut-$DRACUT_VERSION"
65 -    ln -sf ../usr/lib/initrd-release "$initdir"/etc/initrd-release
66 -    ln -sf initrd-release "$initdir"/usr/lib/os-release
67      ln -sf initrd-release "$initdir"/etc/os-release
68  
69      ## save host_devs which we need bring up