diff -Nru dracut-059/debian/changelog dracut-059/debian/changelog --- dracut-059/debian/changelog 2023-08-16 00:02:13.000000000 +0000 +++ dracut-059/debian/changelog 2023-08-22 14:34:06.000000000 +0000 @@ -1,3 +1,23 @@ +dracut (059-4ubuntu2) mantic; urgency=medium + + * Split dracut-install into separate package for initramfs-tools + (LP: #2031185) + * Update out-of-tree patches to final version merged upstream + * Cherry-pick upstream fixes: + - fix(dracut-systemd): rootfs-generator issues + - test: increase test VM memory from 512M to 1024M to avoid OOM killer + * Address lintian complains: + - Remove empty directories in /usr/lib/dracut/modules.d + - Add ${misc:Depends} to all binary package dependencies + - Override lintian complaint executable-in-usr-lib (reported upstream) + - Override false positive about missing init.d scripts + * Install files from debian/tmp to make dh_missing happy + * Install dracut.kernel.7 man page (link to dracut.cmdline.7) + * Restrict autopkgtest to amd64 (other architectures need upstrem work) + * autopkgtest: run more upstream test cases + + -- Benjamin Drung Tue, 22 Aug 2023 16:34:06 +0200 + dracut (059-4ubuntu1) mantic; urgency=medium * fix(test): running tests no longer requires to be root diff -Nru dracut-059/debian/control dracut-059/debian/control --- dracut-059/debian/control 2023-08-15 23:59:52.000000000 +0000 +++ dracut-059/debian/control 2023-08-22 14:34:06.000000000 +0000 @@ -13,7 +13,7 @@ Architecture: all Multi-Arch: foreign Suggests: dracut-network -Depends: dracut-core (>= ${binary:Version}), dracut-core (<< ${binary:Version}+b+~) +Depends: dracut-core (>= ${binary:Version}), dracut-core (<< ${binary:Version}+b+~), ${misc:Depends} Provides: linux-initramfs-tool Conflicts: initramfs-tools, live-tools Description: Initramfs generator using udev @@ -25,7 +25,7 @@ Architecture: any Multi-Arch: foreign Recommends: cryptsetup, dmsetup, dmraid, lvm2, mdadm, console-setup, binutils, systemd, pigz, pkg-config -Depends: cpio, kmod, udev, kpartx, libkmod2, e2fsprogs, ${shlibs:Depends}, ${misc:Depends} +Depends: cpio, dracut-install, kmod, udev, kpartx, libkmod2, e2fsprogs, ${shlibs:Depends}, ${misc:Depends} Breaks: dracut-network (<< 057+157-2), dracut-live (<< 059-2) Replaces: dracut-network (<< 057+157-2), dracut-live (<< 059-2) Description: dracut is an event driven initramfs infrastructure (core tools) @@ -39,6 +39,15 @@ Having the root on MD, LVM2, LUKS is supported as well as NFS, iSCSI, NBD and FCOE with dracut-network. +Package: dracut-install +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Breaks: dracut-core (<< 059-4ubuntu2~) +Replaces: dracut-core (<< 059-4ubuntu2~) +Description: dracut is an event driven initramfs infrastructure (dracut-install) + This package just contains the dracut-install command to be used by + initramfs generating tools. + Package: dracut-network Architecture: all Recommends: nfs-common, open-iscsi, nbd-client, curl @@ -73,14 +82,14 @@ Package: dracut-config-generic Architecture: all -Depends: dracut-core +Depends: dracut-core, ${misc:Depends} Multi-Arch: foreign Description: dracut is an event driven initramfs infrastructure This is the dracut configuration to turn off hostonly image generation Package: dracut-config-rescue Architecture: all -Depends: dracut-core +Depends: dracut-core, ${misc:Depends} Multi-Arch: foreign Description: dracut is an event driven initramfs infrastructure This is the dracut configuration to turn on rescue image generation diff -Nru dracut-059/debian/dracut-core.dirs dracut-059/debian/dracut-core.dirs --- dracut-059/debian/dracut-core.dirs 2023-08-15 22:44:35.000000000 +0000 +++ dracut-059/debian/dracut-core.dirs 2023-08-22 14:34:06.000000000 +0000 @@ -1,28 +1,2 @@ -usr/lib/dracut -usr/lib/dracut/modules.d/00dash -usr/lib/dracut/modules.d/01fips -usr/lib/dracut/modules.d/90crypt -usr/lib/dracut/modules.d/90dm -usr/lib/dracut/modules.d/90dmraid -usr/lib/dracut/modules.d/90kernel-modules -usr/lib/dracut/modules.d/90kernel-modules-extra -usr/lib/dracut/modules.d/80lvmmerge -usr/lib/dracut/modules.d/90lvm -usr/lib/dracut/modules.d/90mdraid -usr/lib/dracut/modules.d/90multipath -usr/lib/dracut/modules.d/95dasd -usr/lib/dracut/modules.d/95dasd_mod -usr/lib/dracut/modules.d/95debug -usr/lib/dracut/modules.d/95resume -usr/lib/dracut/modules.d/95lunmask -usr/lib/dracut/modules.d/95rootfs-block -usr/lib/dracut/modules.d/95terminfo -usr/lib/dracut/modules.d/95udev-rules -usr/lib/dracut/modules.d/98syslog -usr/lib/dracut/modules.d/98usrmount -usr/lib/dracut/modules.d/99base -usr/share/bash-completion/completions -usr/share/pkgconfig /var/lib/dracut /etc/dracut.conf.d -/etc/logrotate.d diff -Nru dracut-059/debian/dracut-core.install dracut-059/debian/dracut-core.install --- dracut-059/debian/dracut-core.install 2023-08-15 22:58:32.000000000 +0000 +++ dracut-059/debian/dracut-core.install 2023-08-22 14:34:06.000000000 +0000 @@ -5,113 +5,112 @@ usr/lib/dracut/dracut-functions.sh usr/lib/dracut/dracut-init.sh usr/lib/dracut/dracut-initramfs-restore -usr/lib/dracut/dracut-install usr/lib/dracut/dracut-util usr/lib/dracut/skipcpio usr/lib/dracut/dracut-logger.sh lib/systemd/system usr/share/bash-completion/completions usr/share/pkgconfig/dracut.pc -dracut-version.sh usr/lib/dracut +usr/lib/dracut/dracut-version.sh etc/dracut.conf etc debian/09console-setup usr/lib/dracut/modules.d debian/90overlay-root usr/lib/dracut/modules.d -modules.d/00bash usr/lib/dracut/modules.d -modules.d/00dash usr/lib/dracut/modules.d -modules.d/00mksh usr/lib/dracut/modules.d -modules.d/00systemd usr/lib/dracut/modules.d -modules.d/00warpclock usr/lib/dracut/modules.d -modules.d/01fips usr/lib/dracut/modules.d -modules.d/01systemd-ac-power usr/lib/dracut/modules.d -modules.d/01systemd-ask-password usr/lib/dracut/modules.d -modules.d/01systemd-coredump usr/lib/dracut/modules.d -modules.d/01systemd-hostnamed usr/lib/dracut/modules.d -modules.d/01systemd-initrd usr/lib/dracut/modules.d -modules.d/01systemd-integritysetup usr/lib/dracut/modules.d -modules.d/01systemd-journald usr/lib/dracut/modules.d -modules.d/01systemd-ldconfig usr/lib/dracut/modules.d -modules.d/01systemd-modules-load usr/lib/dracut/modules.d -modules.d/01systemd-pcrphase usr/lib/dracut/modules.d -modules.d/01systemd-portabled usr/lib/dracut/modules.d -modules.d/01systemd-pstore usr/lib/dracut/modules.d -modules.d/01systemd-repart usr/lib/dracut/modules.d -modules.d/01systemd-resolved usr/lib/dracut/modules.d -modules.d/01systemd-rfkill usr/lib/dracut/modules.d -modules.d/01systemd-sysctl usr/lib/dracut/modules.d -modules.d/01systemd-sysext usr/lib/dracut/modules.d -modules.d/01systemd-sysusers usr/lib/dracut/modules.d -modules.d/01systemd-timedated usr/lib/dracut/modules.d -modules.d/01systemd-timesyncd usr/lib/dracut/modules.d -modules.d/01systemd-tmpfiles usr/lib/dracut/modules.d -modules.d/01systemd-udevd usr/lib/dracut/modules.d -modules.d/01systemd-veritysetup usr/lib/dracut/modules.d -modules.d/02caps usr/lib/dracut/modules.d -modules.d/03modsign usr/lib/dracut/modules.d -modules.d/03rescue usr/lib/dracut/modules.d -modules.d/04watchdog usr/lib/dracut/modules.d -modules.d/04watchdog-modules usr/lib/dracut/modules.d -modules.d/05busybox usr/lib/dracut/modules.d -modules.d/06dbus-broker usr/lib/dracut/modules.d -modules.d/06dbus-daemon usr/lib/dracut/modules.d -modules.d/06rngd usr/lib/dracut/modules.d -modules.d/09dbus usr/lib/dracut/modules.d -modules.d/10i18n usr/lib/dracut/modules.d -modules.d/30convertfs usr/lib/dracut/modules.d -modules.d/50drm usr/lib/dracut/modules.d -modules.d/50plymouth usr/lib/dracut/modules.d -modules.d/62bluetooth usr/lib/dracut/modules.d -modules.d/80lvmmerge usr/lib/dracut/modules.d -modules.d/81cio_ignore usr/lib/dracut/modules.d -modules.d/80lvmthinpool-monitor usr/lib/dracut/modules.d -modules.d/80test usr/lib/dracut/modules.d -modules.d/80test-makeroot usr/lib/dracut/modules.d -modules.d/80test-root usr/lib/dracut/modules.d -modules.d/90btrfs usr/lib/dracut/modules.d -modules.d/90crypt usr/lib/dracut/modules.d -modules.d/90dm usr/lib/dracut/modules.d -modules.d/90dmraid usr/lib/dracut/modules.d -modules.d/90kernel-modules usr/lib/dracut/modules.d -modules.d/90kernel-modules-extra usr/lib/dracut/modules.d -modules.d/90lvm usr/lib/dracut/modules.d -modules.d/90mdraid usr/lib/dracut/modules.d -modules.d/90multipath usr/lib/dracut/modules.d -modules.d/90nvdimm usr/lib/dracut/modules.d -modules.d/90overlayfs usr/lib/dracut/modules.d -modules.d/90ppcmac usr/lib/dracut/modules.d -modules.d/90qemu usr/lib/dracut/modules.d -modules.d/91crypt-gpg usr/lib/dracut/modules.d -modules.d/91crypt-loop usr/lib/dracut/modules.d -modules.d/91fido2 usr/lib/dracut/modules.d -modules.d/91pcsc usr/lib/dracut/modules.d -modules.d/91pkcs11 usr/lib/dracut/modules.d -modules.d/91tpm2-tss usr/lib/dracut/modules.d -modules.d/91zipl usr/lib/dracut/modules.d -modules.d/95dasd usr/lib/dracut/modules.d -modules.d/95dasd_mod usr/lib/dracut/modules.d -modules.d/95dasd_rules usr/lib/dracut/modules.d -modules.d/95dcssblk usr/lib/dracut/modules.d -modules.d/95debug usr/lib/dracut/modules.d -modules.d/95fstab-sys usr/lib/dracut/modules.d -modules.d/95lunmask usr/lib/dracut/modules.d -modules.d/95nvmf usr/lib/dracut/modules.d -modules.d/95qeth_rules usr/lib/dracut/modules.d -modules.d/95resume usr/lib/dracut/modules.d -modules.d/95rootfs-block usr/lib/dracut/modules.d -modules.d/95terminfo usr/lib/dracut/modules.d -modules.d/95udev-rules usr/lib/dracut/modules.d -modules.d/95virtfs usr/lib/dracut/modules.d -modules.d/95virtiofs usr/lib/dracut/modules.d -modules.d/96securityfs usr/lib/dracut/modules.d -modules.d/97biosdevname usr/lib/dracut/modules.d -modules.d/97masterkey usr/lib/dracut/modules.d -modules.d/98dracut-systemd usr/lib/dracut/modules.d -modules.d/98ecryptfs usr/lib/dracut/modules.d -modules.d/98integrity usr/lib/dracut/modules.d -modules.d/98pollcdrom usr/lib/dracut/modules.d -modules.d/98selinux usr/lib/dracut/modules.d -modules.d/98syslog usr/lib/dracut/modules.d -modules.d/98usrmount usr/lib/dracut/modules.d -modules.d/99base usr/lib/dracut/modules.d -modules.d/99fs-lib usr/lib/dracut/modules.d -modules.d/99memstrack usr/lib/dracut/modules.d -modules.d/99shutdown usr/lib/dracut/modules.d +usr/lib/dracut/modules.d/00bash +usr/lib/dracut/modules.d/00dash +usr/lib/dracut/modules.d/00mksh +usr/lib/dracut/modules.d/00systemd +usr/lib/dracut/modules.d/00warpclock +usr/lib/dracut/modules.d/01fips +usr/lib/dracut/modules.d/01systemd-ac-power +usr/lib/dracut/modules.d/01systemd-ask-password +usr/lib/dracut/modules.d/01systemd-coredump +usr/lib/dracut/modules.d/01systemd-hostnamed +usr/lib/dracut/modules.d/01systemd-initrd +usr/lib/dracut/modules.d/01systemd-integritysetup +usr/lib/dracut/modules.d/01systemd-journald +usr/lib/dracut/modules.d/01systemd-ldconfig +usr/lib/dracut/modules.d/01systemd-modules-load +usr/lib/dracut/modules.d/01systemd-pcrphase +usr/lib/dracut/modules.d/01systemd-portabled +usr/lib/dracut/modules.d/01systemd-pstore +usr/lib/dracut/modules.d/01systemd-repart +usr/lib/dracut/modules.d/01systemd-resolved +usr/lib/dracut/modules.d/01systemd-rfkill +usr/lib/dracut/modules.d/01systemd-sysctl +usr/lib/dracut/modules.d/01systemd-sysext +usr/lib/dracut/modules.d/01systemd-sysusers +usr/lib/dracut/modules.d/01systemd-timedated +usr/lib/dracut/modules.d/01systemd-timesyncd +usr/lib/dracut/modules.d/01systemd-tmpfiles +usr/lib/dracut/modules.d/01systemd-udevd +usr/lib/dracut/modules.d/01systemd-veritysetup +usr/lib/dracut/modules.d/02caps +usr/lib/dracut/modules.d/03modsign +usr/lib/dracut/modules.d/03rescue +usr/lib/dracut/modules.d/04watchdog +usr/lib/dracut/modules.d/04watchdog-modules +usr/lib/dracut/modules.d/05busybox +usr/lib/dracut/modules.d/06dbus-broker +usr/lib/dracut/modules.d/06dbus-daemon +usr/lib/dracut/modules.d/06rngd +usr/lib/dracut/modules.d/09dbus +usr/lib/dracut/modules.d/10i18n +usr/lib/dracut/modules.d/30convertfs +usr/lib/dracut/modules.d/50drm +usr/lib/dracut/modules.d/50plymouth +usr/lib/dracut/modules.d/62bluetooth +usr/lib/dracut/modules.d/80lvmmerge +usr/lib/dracut/modules.d/81cio_ignore +usr/lib/dracut/modules.d/80lvmthinpool-monitor +usr/lib/dracut/modules.d/80test +usr/lib/dracut/modules.d/80test-makeroot +usr/lib/dracut/modules.d/80test-root +usr/lib/dracut/modules.d/90btrfs +usr/lib/dracut/modules.d/90crypt +usr/lib/dracut/modules.d/90dm +usr/lib/dracut/modules.d/90dmraid +usr/lib/dracut/modules.d/90kernel-modules +usr/lib/dracut/modules.d/90kernel-modules-extra +usr/lib/dracut/modules.d/90lvm +usr/lib/dracut/modules.d/90mdraid +usr/lib/dracut/modules.d/90multipath +usr/lib/dracut/modules.d/90nvdimm +usr/lib/dracut/modules.d/90overlayfs +usr/lib/dracut/modules.d/90ppcmac +usr/lib/dracut/modules.d/90qemu +usr/lib/dracut/modules.d/91crypt-gpg +usr/lib/dracut/modules.d/91crypt-loop +usr/lib/dracut/modules.d/91fido2 +usr/lib/dracut/modules.d/91pcsc +usr/lib/dracut/modules.d/91pkcs11 +usr/lib/dracut/modules.d/91tpm2-tss +usr/lib/dracut/modules.d/91zipl +usr/lib/dracut/modules.d/95dasd +usr/lib/dracut/modules.d/95dasd_mod +usr/lib/dracut/modules.d/95dasd_rules +usr/lib/dracut/modules.d/95dcssblk +usr/lib/dracut/modules.d/95debug +usr/lib/dracut/modules.d/95fstab-sys +usr/lib/dracut/modules.d/95lunmask +usr/lib/dracut/modules.d/95nvmf +usr/lib/dracut/modules.d/95qeth_rules +usr/lib/dracut/modules.d/95resume +usr/lib/dracut/modules.d/95rootfs-block +usr/lib/dracut/modules.d/95terminfo +usr/lib/dracut/modules.d/95udev-rules +usr/lib/dracut/modules.d/95virtfs +usr/lib/dracut/modules.d/95virtiofs +usr/lib/dracut/modules.d/96securityfs +usr/lib/dracut/modules.d/97biosdevname +usr/lib/dracut/modules.d/97masterkey +usr/lib/dracut/modules.d/98dracut-systemd +usr/lib/dracut/modules.d/98ecryptfs +usr/lib/dracut/modules.d/98integrity +usr/lib/dracut/modules.d/98pollcdrom +usr/lib/dracut/modules.d/98selinux +usr/lib/dracut/modules.d/98syslog +usr/lib/dracut/modules.d/98usrmount +usr/lib/dracut/modules.d/99base +usr/lib/dracut/modules.d/99fs-lib +usr/lib/dracut/modules.d/99memstrack +usr/lib/dracut/modules.d/99shutdown diff -Nru dracut-059/debian/dracut-core.lintian-overrides dracut-059/debian/dracut-core.lintian-overrides --- dracut-059/debian/dracut-core.lintian-overrides 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/dracut-core.lintian-overrides 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,4 @@ +# one single directory for modules is needed, see https://github.com/dracutdevs/dracut/issues/2485 +dracut-core: executable-in-usr-lib [usr/lib/dracut/*] +# False positive: these systemd units are only needed when using systemd inside the initramfs +dracut-core: package-supports-alternative-init-but-no-init.d-script diff -Nru dracut-059/debian/dracut-core.manpages dracut-059/debian/dracut-core.manpages --- dracut-059/debian/dracut-core.manpages 2023-08-15 22:44:35.000000000 +0000 +++ dracut-059/debian/dracut-core.manpages 2023-08-22 14:34:06.000000000 +0000 @@ -1,8 +1 @@ -man/dracut.8 -man/dracut.conf.5 -man/dracut.modules.7 -man/dracut.bootup.7 -man/dracut.cmdline.7 -man/dracut-catimages.8 -man/lsinitrd.1 -debian/tmp/usr/share/man/man8/* +usr/share/man/man?/* diff -Nru dracut-059/debian/dracut.dirs dracut-059/debian/dracut.dirs --- dracut-059/debian/dracut.dirs 2023-08-15 20:49:10.000000000 +0000 +++ dracut-059/debian/dracut.dirs 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -/etc/kernel/postinst.d -/etc/kernel/postrm.d diff -Nru dracut-059/debian/dracut-install.install dracut-059/debian/dracut-install.install --- dracut-059/debian/dracut-install.install 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/dracut-install.install 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1 @@ +usr/lib/dracut/dracut-install diff -Nru dracut-059/debian/dracut-install.lintian-overrides dracut-059/debian/dracut-install.lintian-overrides --- dracut-059/debian/dracut-install.lintian-overrides 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/dracut-install.lintian-overrides 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,2 @@ +# one single directory for modules is needed, see https://github.com/dracutdevs/dracut/issues/2485 +dracut-install: executable-in-usr-lib [usr/lib/dracut/*] diff -Nru dracut-059/debian/dracut-live.dirs dracut-059/debian/dracut-live.dirs --- dracut-059/debian/dracut-live.dirs 2023-08-15 22:44:35.000000000 +0000 +++ dracut-059/debian/dracut-live.dirs 1970-01-01 00:00:00.000000000 +0000 @@ -1,4 +0,0 @@ -usr/lib/dracut/modules.d/99img-lib -usr/lib/dracut/modules.d/90dmsquash-live -usr/lib/dracut/modules.d/90livenet -usr/lib/dracut/modules.d/90overlayfs diff -Nru dracut-059/debian/dracut-live.install dracut-059/debian/dracut-live.install --- dracut-059/debian/dracut-live.install 2023-08-15 22:44:35.000000000 +0000 +++ dracut-059/debian/dracut-live.install 2023-08-22 14:34:06.000000000 +0000 @@ -1,5 +1,5 @@ -modules.d/99img-lib usr/lib/dracut/modules.d -modules.d/90dmsquash-live usr/lib/dracut/modules.d -modules.d/90dmsquash-live-autooverlay usr/lib/dracut/modules.d -modules.d/90dmsquash-live-ntfs usr/lib/dracut/modules.d -modules.d/90livenet usr/lib/dracut/modules.d +usr/lib/dracut/modules.d/99img-lib +usr/lib/dracut/modules.d/90dmsquash-live +usr/lib/dracut/modules.d/90dmsquash-live-autooverlay +usr/lib/dracut/modules.d/90dmsquash-live-ntfs +usr/lib/dracut/modules.d/90livenet diff -Nru dracut-059/debian/dracut-live.lintian-overrides dracut-059/debian/dracut-live.lintian-overrides --- dracut-059/debian/dracut-live.lintian-overrides 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/dracut-live.lintian-overrides 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,2 @@ +# one single directory for modules is needed, see https://github.com/dracutdevs/dracut/issues/2485 +dracut-live: executable-in-usr-lib [usr/lib/dracut/*] diff -Nru dracut-059/debian/dracut-network.dirs dracut-059/debian/dracut-network.dirs --- dracut-059/debian/dracut-network.dirs 2023-08-15 22:44:35.000000000 +0000 +++ dracut-059/debian/dracut-network.dirs 1970-01-01 00:00:00.000000000 +0000 @@ -1,10 +0,0 @@ -usr/lib/dracut/modules.d/35network-manager -usr/lib/dracut/modules.d/35network-legacy -usr/lib/dracut/modules.d/40network -usr/lib/dracut/modules.d/90overlay-root -usr/lib/dracut/modules.d/95fcoe -usr/lib/dracut/modules.d/95iscsi -usr/lib/dracut/modules.d/95nbd -usr/lib/dracut/modules.d/95nfs -usr/lib/dracut/modules.d/95znet -usr/lib/dracut/modules.d/95zfcp diff -Nru dracut-059/debian/dracut-network.install dracut-059/debian/dracut-network.install --- dracut-059/debian/dracut-network.install 2023-08-15 22:44:35.000000000 +0000 +++ dracut-059/debian/dracut-network.install 2023-08-22 14:34:06.000000000 +0000 @@ -1,23 +1,23 @@ debian/etc/11-ifcfg.conf etc/dracut.conf.d -modules.d/00systemd-network-management usr/lib/dracut/modules.d -modules.d/01systemd-networkd usr/lib/dracut/modules.d -modules.d/35connman usr/lib/dracut/modules.d -modules.d/35network-manager usr/lib/dracut/modules.d -modules.d/35network-legacy usr/lib/dracut/modules.d -modules.d/40network usr/lib/dracut/modules.d -modules.d/45url-lib usr/lib/dracut/modules.d -modules.d/45ifcfg usr/lib/dracut/modules.d -modules.d/80cms usr/lib/dracut/modules.d -modules.d/90kernel-network-modules usr/lib/dracut/modules.d -modules.d/90qemu-net usr/lib/dracut/modules.d -modules.d/95cifs usr/lib/dracut/modules.d -modules.d/95znet usr/lib/dracut/modules.d -modules.d/95zfcp usr/lib/dracut/modules.d -modules.d/95zfcp_rules usr/lib/dracut/modules.d -modules.d/95fcoe usr/lib/dracut/modules.d -modules.d/95fcoe-uefi usr/lib/dracut/modules.d -modules.d/95iscsi usr/lib/dracut/modules.d -modules.d/95nbd usr/lib/dracut/modules.d -modules.d/95nfs usr/lib/dracut/modules.d -modules.d/95ssh-client usr/lib/dracut/modules.d -modules.d/99uefi-lib usr/lib/dracut/modules.d +usr/lib/dracut/modules.d/00systemd-network-management +usr/lib/dracut/modules.d/01systemd-networkd +usr/lib/dracut/modules.d/35connman +usr/lib/dracut/modules.d/35network-manager +usr/lib/dracut/modules.d/35network-legacy +usr/lib/dracut/modules.d/40network +usr/lib/dracut/modules.d/45url-lib +usr/lib/dracut/modules.d/45ifcfg +usr/lib/dracut/modules.d/80cms +usr/lib/dracut/modules.d/90kernel-network-modules +usr/lib/dracut/modules.d/90qemu-net +usr/lib/dracut/modules.d/95cifs +usr/lib/dracut/modules.d/95znet +usr/lib/dracut/modules.d/95zfcp +usr/lib/dracut/modules.d/95zfcp_rules +usr/lib/dracut/modules.d/95fcoe +usr/lib/dracut/modules.d/95fcoe-uefi +usr/lib/dracut/modules.d/95iscsi +usr/lib/dracut/modules.d/95nbd +usr/lib/dracut/modules.d/95nfs +usr/lib/dracut/modules.d/95ssh-client +usr/lib/dracut/modules.d/99uefi-lib diff -Nru dracut-059/debian/dracut-network.lintian-overrides dracut-059/debian/dracut-network.lintian-overrides --- dracut-059/debian/dracut-network.lintian-overrides 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/dracut-network.lintian-overrides 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,2 @@ +# one single directory for modules is needed, see https://github.com/dracutdevs/dracut/issues/2485 +dracut-network: executable-in-usr-lib [usr/lib/dracut/*] diff -Nru dracut-059/debian/dracut-squash.dirs dracut-059/debian/dracut-squash.dirs --- dracut-059/debian/dracut-squash.dirs 2023-08-15 20:49:10.000000000 +0000 +++ dracut-059/debian/dracut-squash.dirs 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -usr/lib/dracut/modules.d/99squash diff -Nru dracut-059/debian/dracut-squash.install dracut-059/debian/dracut-squash.install --- dracut-059/debian/dracut-squash.install 2023-08-15 20:49:10.000000000 +0000 +++ dracut-059/debian/dracut-squash.install 2023-08-22 14:34:06.000000000 +0000 @@ -1 +1 @@ -modules.d/99squash usr/lib/dracut/modules.d +usr/lib/dracut/modules.d/99squash diff -Nru dracut-059/debian/not-installed dracut-059/debian/not-installed --- dracut-059/debian/not-installed 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/not-installed 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,3 @@ +usr/lib/kernel/install.d/* +# wicked dracut module is not supported by debian +usr/lib/dracut/modules.d/35network-wicked/* diff -Nru dracut-059/debian/patches/fix-dracut-systemd-check-and-create-generator-dir-outside.patch dracut-059/debian/patches/fix-dracut-systemd-check-and-create-generator-dir-outside.patch --- dracut-059/debian/patches/fix-dracut-systemd-check-and-create-generator-dir-outside.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/fix-dracut-systemd-check-and-create-generator-dir-outside.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,36 @@ +From: Antonio Alvarez Feijoo +Date: Wed, 1 Mar 2023 12:07:29 +0100 +Subject: fix(dracut-systemd): check and create generator dir outside of inner + function + +Origin: upstream, https://github.com/dracutdevs/dracut/pull/2270 +--- + modules.d/98dracut-systemd/rootfs-generator.sh | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +diff --git a/modules.d/98dracut-systemd/rootfs-generator.sh b/modules.d/98dracut-systemd/rootfs-generator.sh +index 3f88f5d..cf36915 100755 +--- a/modules.d/98dracut-systemd/rootfs-generator.sh ++++ b/modules.d/98dracut-systemd/rootfs-generator.sh +@@ -51,7 +51,6 @@ generator_mount_rootfs() { + [ -z "$1" ] && return 0 + + _name=$(dev_unit_name "$1") +- [ -d "$GENERATOR_DIR" ] || mkdir -p "$GENERATOR_DIR" + if ! [ -f "$GENERATOR_DIR"/sysroot.mount ]; then + { + echo "[Unit]" +@@ -101,9 +100,11 @@ case "${root#block:}" in + ;; + esac + +-GENERATOR_DIR="$1" +- + if [ "$rootok" = "1" ]; then ++ GENERATOR_DIR="$1" ++ [ -z "$GENERATOR_DIR" ] && exit 1 ++ [ -d "$GENERATOR_DIR" ] || mkdir -p "$GENERATOR_DIR" ++ + generator_wait_for_dev "${root#block:}" "$RDRETRY" + generator_fsck_after_pre_mount "${root#block:}" + strstr "$(cat /proc/cmdline)" 'root=' || generator_mount_rootfs "${root#block:}" "$(getarg rootfstype=)" "$(getarg rootflags=)" diff -Nru dracut-059/debian/patches/fix-dracut-systemd-do-not-hardcode-the-systemd-generator-.patch dracut-059/debian/patches/fix-dracut-systemd-do-not-hardcode-the-systemd-generator-.patch --- dracut-059/debian/patches/fix-dracut-systemd-do-not-hardcode-the-systemd-generator-.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/fix-dracut-systemd-do-not-hardcode-the-systemd-generator-.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,41 @@ +From: Antonio Alvarez Feijoo +Date: Wed, 1 Mar 2023 11:21:16 +0100 +Subject: fix(dracut-systemd): do not hardcode the systemd generator directory + +The normal directory is the first argument passed to the systemd generator, +so use it instead of hardcoding /run/systemd/generator. + +Origin: upstream, https://github.com/dracutdevs/dracut/pull/2270 +--- + modules.d/98dracut-systemd/rootfs-generator.sh | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/modules.d/98dracut-systemd/rootfs-generator.sh b/modules.d/98dracut-systemd/rootfs-generator.sh +index e1d365d..3f88f5d 100755 +--- a/modules.d/98dracut-systemd/rootfs-generator.sh ++++ b/modules.d/98dracut-systemd/rootfs-generator.sh +@@ -17,7 +17,7 @@ generator_wait_for_dev() { + # after remote-fs-pre.target since the initqueue is ordered before it so + # it will never actually show up (think Tang-pinned rootfs). + cat > "$hookdir/initqueue/finished/devexists-${_name}.sh" << EOF +-if ! grep -q After=remote-fs-pre.target /run/systemd/generator/systemd-cryptsetup@*.service 2>/dev/null; then ++if ! grep -q After=remote-fs-pre.target "$GENERATOR_DIR"/systemd-cryptsetup@*.service 2>/dev/null; then + [ -e "$1" ] + fi + EOF +@@ -77,12 +77,12 @@ generator_fsck_after_pre_mount() { + [ -z "$1" ] && return 0 + + _name=$(dev_unit_name "$1") +- [ -d /run/systemd/generator/systemd-fsck@"${_name}".service.d ] || mkdir -p /run/systemd/generator/systemd-fsck@"${_name}".service.d +- if ! [ -f /run/systemd/generator/systemd-fsck@"${_name}".service.d/after-pre-mount.conf ]; then ++ [ -d "$GENERATOR_DIR"/systemd-fsck@"${_name}".service.d ] || mkdir -p "$GENERATOR_DIR"/systemd-fsck@"${_name}".service.d ++ if ! [ -f "$GENERATOR_DIR"/systemd-fsck@"${_name}".service.d/after-pre-mount.conf ]; then + { + echo "[Unit]" + echo "After=dracut-pre-mount.service" +- } > /run/systemd/generator/systemd-fsck@"${_name}".service.d/after-pre-mount.conf ++ } > "$GENERATOR_DIR"/systemd-fsck@"${_name}".service.d/after-pre-mount.conf + fi + + } diff -Nru dracut-059/debian/patches/fix-dracut-systemd-rootfs-generator-cannot-write-outside-.patch dracut-059/debian/patches/fix-dracut-systemd-rootfs-generator-cannot-write-outside-.patch --- dracut-059/debian/patches/fix-dracut-systemd-rootfs-generator-cannot-write-outside-.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/fix-dracut-systemd-rootfs-generator-cannot-write-outside-.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,115 @@ +From: Antonio Alvarez Feijoo +Date: Wed, 8 Mar 2023 08:25:38 +0100 +Subject: fix(dracut-systemd): rootfs-generator cannot write outside of + generator dir + +Although it was already documented in systemd.generator(7) that generators must +not write to locations other than those passed as arguments, since +https://github.com/systemd/systemd/commit/ca6ce62d systemd executes generators +in a mount namespace "sandbox", so now the hooks created by the rootfs-generator +are lost. + +These hooks are created using the root= cmdline argument, so this patch moves +the creation of these hooks to a cmdline hook. + +Fixes issue #2211 +Fixes issue #2225 +Origin: upstream, https://github.com/dracutdevs/dracut/pull/2270 +--- + modules.d/98dracut-systemd/module-setup.sh | 2 ++ + modules.d/98dracut-systemd/parse-root.sh | 38 ++++++++++++++++++++++++++ + modules.d/98dracut-systemd/rootfs-generator.sh | 20 +------------- + 3 files changed, 41 insertions(+), 19 deletions(-) + create mode 100755 modules.d/98dracut-systemd/parse-root.sh + +diff --git a/modules.d/98dracut-systemd/module-setup.sh b/modules.d/98dracut-systemd/module-setup.sh +index b7da86d..3195377 100755 +--- a/modules.d/98dracut-systemd/module-setup.sh ++++ b/modules.d/98dracut-systemd/module-setup.sh +@@ -37,6 +37,8 @@ install() { + + inst_script "$moddir/rootfs-generator.sh" "$systemdutildir"/system-generators/dracut-rootfs-generator + ++ inst_hook cmdline 00 "$moddir/parse-root.sh" ++ + for i in \ + dracut-cmdline.service \ + dracut-cmdline-ask.service \ +diff --git a/modules.d/98dracut-systemd/parse-root.sh b/modules.d/98dracut-systemd/parse-root.sh +new file mode 100755 +index 0000000..90f145a +--- /dev/null ++++ b/modules.d/98dracut-systemd/parse-root.sh +@@ -0,0 +1,38 @@ ++#!/bin/sh ++ ++type getarg > /dev/null 2>&1 || . /lib/dracut-lib.sh ++ ++root=$(getarg root=) ++case "${root#block:}" in ++ LABEL=* | UUID=* | PARTUUID=* | PARTLABEL=*) ++ root="block:$(label_uuid_to_dev "$root")" ++ rootok=1 ++ ;; ++ /dev/nfs | /dev/root) # ignore legacy ++ ;; ++ /dev/*) ++ root="block:${root}" ++ rootok=1 ++ ;; ++esac ++ ++if [ "$rootok" = "1" ]; then ++ root_dev="${root#block:}" ++ root_name="$(str_replace "$root_dev" '/' '\x2f')" ++ if ! [ -e "$hookdir/initqueue/finished/devexists-${root_name}.sh" ]; then ++ ++ # If a LUKS device needs unlocking via systemd in the initrd, assume ++ # it's for the root device. In that case, don't block on it if it's ++ # after remote-fs-pre.target since the initqueue is ordered before it so ++ # it will never actually show up (think Tang-pinned rootfs). ++ cat > "$hookdir/initqueue/finished/devexists-${root_name}.sh" << EOF ++if ! grep -q After=remote-fs-pre.target /run/systemd/generator/systemd-cryptsetup@*.service 2>/dev/null; then ++ [ -e "$root_dev" ] ++fi ++EOF ++ { ++ printf '[ -e "%s" ] || ' "$root_dev" ++ printf 'warn "\"%s\" does not exist"\n' "$root_dev" ++ } >> "$hookdir/emergency/80-${root_name}.sh" ++ fi ++fi +diff --git a/modules.d/98dracut-systemd/rootfs-generator.sh b/modules.d/98dracut-systemd/rootfs-generator.sh +index cf36915..ec5886f 100755 +--- a/modules.d/98dracut-systemd/rootfs-generator.sh ++++ b/modules.d/98dracut-systemd/rootfs-generator.sh +@@ -6,28 +6,10 @@ generator_wait_for_dev() { + local _name + local _timeout + +- _name="$(str_replace "$1" '/' '\x2f')" ++ _name=$(dev_unit_name "$1") + _timeout=$(getarg rd.timeout) + _timeout=${_timeout:-0} + +- if ! [ -e "$hookdir/initqueue/finished/devexists-${_name}.sh" ]; then +- +- # If a LUKS device needs unlocking via systemd in the initrd, assume +- # it's for the root device. In that case, don't block on it if it's +- # after remote-fs-pre.target since the initqueue is ordered before it so +- # it will never actually show up (think Tang-pinned rootfs). +- cat > "$hookdir/initqueue/finished/devexists-${_name}.sh" << EOF +-if ! grep -q After=remote-fs-pre.target "$GENERATOR_DIR"/systemd-cryptsetup@*.service 2>/dev/null; then +- [ -e "$1" ] +-fi +-EOF +- { +- printf '[ -e "%s" ] || ' "$1" +- printf 'warn "\"%s\" does not exist"\n' "$1" +- } >> "$hookdir/emergency/80-${_name}.sh" +- fi +- +- _name=$(dev_unit_name "$1") + if ! [ -L "$GENERATOR_DIR"/initrd.target.wants/"${_name}".device ]; then + [ -d "$GENERATOR_DIR"/initrd.target.wants ] || mkdir -p "$GENERATOR_DIR"/initrd.target.wants + ln -s ../"${_name}".device "$GENERATOR_DIR"/initrd.target.wants/"${_name}".device diff -Nru dracut-059/debian/patches/fix-test-running-tests-no-longer-requires-to-be-root.patch dracut-059/debian/patches/fix-test-running-tests-no-longer-requires-to-be-root.patch --- dracut-059/debian/patches/fix-test-running-tests-no-longer-requires-to-be-root.patch 2023-08-15 20:49:10.000000000 +0000 +++ dracut-059/debian/patches/fix-test-running-tests-no-longer-requires-to-be-root.patch 2023-08-22 14:34:06.000000000 +0000 @@ -2,7 +2,7 @@ Date: Tue, 21 Feb 2023 00:20:29 +0000 Subject: fix(test): running tests no longer requires to be root -Origin: https://github.com/dracutdevs/dracut/pull/2429 +Origin: upstream, https://github.com/dracutdevs/dracut/pull/2429 --- Makefile | 1 - docs/HACKING.md | 10 +++++----- diff -Nru dracut-059/debian/patches/series dracut-059/debian/patches/series --- dracut-059/debian/patches/series 2023-08-15 20:49:10.000000000 +0000 +++ dracut-059/debian/patches/series 2023-08-22 14:34:06.000000000 +0000 @@ -8,4 +8,11 @@ plymouth initrd-not-initramfs.patch fix-test-running-tests-no-longer-requires-to-be-root.patch -test-Make-dracut-and-modules.d-directory-configurable.patch +test-make-dracut-directory-configurable.patch +test-make-package-libdir-configurable.patch +test-skip-test-98-if-dracut-util-is-not-available.patch +test-fix-skipcpio-path-for-installed-binary.patch +fix-dracut-systemd-do-not-hardcode-the-systemd-generator-.patch +fix-dracut-systemd-check-and-create-generator-dir-outside.patch +fix-dracut-systemd-rootfs-generator-cannot-write-outside-.patch +test-increase-test-VM-memory-from-512M-to-1024M-to-avoid-.patch diff -Nru dracut-059/debian/patches/test-fix-skipcpio-path-for-installed-binary.patch dracut-059/debian/patches/test-fix-skipcpio-path-for-installed-binary.patch --- dracut-059/debian/patches/test-fix-skipcpio-path-for-installed-binary.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/test-fix-skipcpio-path-for-installed-binary.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,30 @@ +From: Benjamin Drung +Date: Wed, 16 Aug 2023 14:03:10 +0200 +Subject: test: fix skipcpio path for installed binary + +The `skipcpio` binary is installed in `${PKGLIBDIR}/skipcpio`. + +Forwarded: https://github.com/dracutdevs/dracut/pull/2484 +Signed-off-by: Benjamin Drung +--- + test/TEST-62-SKIPCPIO/test.sh | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +diff --git a/test/TEST-62-SKIPCPIO/test.sh b/test/TEST-62-SKIPCPIO/test.sh +index e263a67..23062ee 100755 +--- a/test/TEST-62-SKIPCPIO/test.sh ++++ b/test/TEST-62-SKIPCPIO/test.sh +@@ -40,7 +40,12 @@ skipcpio_simple() { + 2 + EOF + +- "$basedir"/src/skipcpio/skipcpio "$CPIO_TESTDIR/skipcpio_simple.cpio" \ ++ if [ "$PKGLIBDIR" = "$basedir" ]; then ++ skipcpio_path="${PKGLIBDIR}/src/skipcpio" ++ else ++ skipcpio_path="${PKGLIBDIR}" ++ fi ++ "$skipcpio_path"/skipcpio "$CPIO_TESTDIR/skipcpio_simple.cpio" \ + | cpio -i --list > "$CPIO_TESTDIR/skipcpio_simple.list" + cat << EOF | diff - "$CPIO_TESTDIR/skipcpio_simple.list" + . diff -Nru dracut-059/debian/patches/test-increase-test-VM-memory-from-512M-to-1024M-to-avoid-.patch dracut-059/debian/patches/test-increase-test-VM-memory-from-512M-to-1024M-to-avoid-.patch --- dracut-059/debian/patches/test-increase-test-VM-memory-from-512M-to-1024M-to-avoid-.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/test-increase-test-VM-memory-from-512M-to-1024M-to-avoid-.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,22 @@ +From: Henrik Gombos +Date: Fri, 28 Jul 2023 22:49:21 -0400 +Subject: test: increase test VM memory from 512M to 1024M to avoid OOM killer + +Origin: upstream, https://github.com/dracutdevs/dracut/pull/2454 +--- + test/run-qemu | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/test/run-qemu b/test/run-qemu +index 5dc6103..cc5371e 100755 +--- a/test/run-qemu ++++ b/test/run-qemu +@@ -20,7 +20,7 @@ QEMU_CPU="${QEMU_CPU:-max}" + } + + # Provide rng device sourcing the hosts /dev/urandom and other standard parameters +-ARGS+=(-M q35 -smp 2 -m 512 -nodefaults -vga none -display none -no-reboot -device virtio-rng-pci) ++ARGS+=(-M q35 -smp 2 -m 1024 -nodefaults -vga none -display none -no-reboot -device virtio-rng-pci) + + if ! [[ $* == *-daemonize* ]] && ! [[ $* == *-daemonize* ]]; then + ARGS+=(-serial stdio) diff -Nru dracut-059/debian/patches/test-Make-dracut-and-modules.d-directory-configurable.patch dracut-059/debian/patches/test-Make-dracut-and-modules.d-directory-configurable.patch --- dracut-059/debian/patches/test-Make-dracut-and-modules.d-directory-configurable.patch 2023-08-15 20:49:10.000000000 +0000 +++ dracut-059/debian/patches/test-Make-dracut-and-modules.d-directory-configurable.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,778 +0,0 @@ -From: Benjamin Drung -Date: Tue, 15 Aug 2023 21:34:07 +0200 -Subject: test: Make dracut and modules.d directory configurable - -Make the directory of the `dracut` script and `modules.d` directory -configurable to allow running the test suite out-of-tree. - -This change is used to run the test suite against the installed dracut -in an autopkgtest for the Debian/Ubuntu package. - -Forwarded: https://github.com/dracutdevs/dracut/pull/2484 -Signed-off-by: Benjamin Drung ---- - test/TEST-01-BASIC/test.sh | 10 +++++----- - test/TEST-02-SYSTEMD/test.sh | 10 +++++----- - test/TEST-03-USR-MOUNT/test.sh | 10 +++++----- - test/TEST-04-FULL-SYSTEMD/test.sh | 10 +++++----- - test/TEST-10-RAID/test.sh | 8 ++++---- - test/TEST-11-LVM/test.sh | 8 ++++---- - test/TEST-12-RAID-DEG/test.sh | 8 ++++---- - test/TEST-13-ENC-RAID-LVM/test.sh | 8 ++++---- - test/TEST-14-IMSM/test.sh | 8 ++++---- - test/TEST-15-BTRFSRAID/test.sh | 8 ++++---- - test/TEST-16-DMSQUASH/test.sh | 12 ++++++------ - test/TEST-17-LVM-THIN/test.sh | 8 ++++---- - test/TEST-20-NFS/test.sh | 10 +++++----- - test/TEST-30-ISCSI/test.sh | 12 ++++++------ - test/TEST-35-ISCSI-MULTI/test.sh | 12 ++++++------ - test/TEST-40-NBD/test.sh | 18 +++++++++--------- - test/TEST-50-MULTINIC/test.sh | 10 +++++----- - test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh | 6 +++--- - test/TEST-63-DRACUT-CPIO/test.sh | 2 +- - test/test-functions | 3 +++ - 20 files changed, 92 insertions(+), 89 deletions(-) - -diff --git a/test/TEST-01-BASIC/test.sh b/test/TEST-01-BASIC/test.sh -index 37059d4..23a27b7 100755 ---- a/test/TEST-01-BASIC/test.sh -+++ b/test/TEST-01-BASIC/test.sh -@@ -25,11 +25,11 @@ test_run() { - - test_setup() { - # Create what will eventually be our root filesystem onto an overlay -- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ -+ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ - -m "test-root" \ - -i ./test-init.sh /sbin/init \ -- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ - --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ - -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 - mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* -@@ -38,7 +38,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "test-makeroot dash rootfs-block kernel-modules" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - -I "mkfs.ext3" \ -@@ -64,7 +64,7 @@ test_setup() { - rm -- "$TESTDIR"/marker.img - - # make sure --omit-drivers does not filter out drivers using regexp to test for an earlier regression (assuming there is no one letter linux kernel module needed to run the test) -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -a "test watchdog" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod i6300esb ib700wdt" \ - --omit-drivers 'a b c d e f g h i j k l m n o p q r s t u v w x y z' \ -diff --git a/test/TEST-02-SYSTEMD/test.sh b/test/TEST-02-SYSTEMD/test.sh -index b915b8f..bc3b858 100755 ---- a/test/TEST-02-SYSTEMD/test.sh -+++ b/test/TEST-02-SYSTEMD/test.sh -@@ -27,11 +27,11 @@ test_run() { - - test_setup() { - # Create what will eventually be our root filesystem onto an overlay -- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ -+ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ - -m "test-root" \ - -i ./test-init.sh /sbin/init \ -- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ - --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ - -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 - mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* -@@ -40,7 +40,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "test-makeroot dash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - -I "mkfs.ext3" \ -@@ -67,7 +67,7 @@ test_setup() { - - # systemd-analyze.sh calls man indirectly - # make the man command succeed always -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -a "test systemd" \ - -o "network kernel-network-modules" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ -diff --git a/test/TEST-03-USR-MOUNT/test.sh b/test/TEST-03-USR-MOUNT/test.sh -index b78b56b..6a19bb6 100755 ---- a/test/TEST-03-USR-MOUNT/test.sh -+++ b/test/TEST-03-USR-MOUNT/test.sh -@@ -43,12 +43,12 @@ test_run() { - - test_setup() { - # Create what will eventually be our root filesystem onto an overlay -- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ -+ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ - -m "test-root" \ - -i ./test-init.sh /sbin/init \ - -i ./fstab /etc/fstab \ -- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ - --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ - -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 - mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* -@@ -57,7 +57,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "test-makeroot dash btrfs rootfs-block kernel-modules" \ - -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ - -I "mkfs.btrfs" \ -@@ -89,7 +89,7 @@ test_setup() { - return 1 - fi - -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -a "test watchdog" \ - -o "network kernel-network-modules" \ - -d "piix ide-gd_mod ata_piix btrfs sd_mod i6300esb ib700wdt" \ -diff --git a/test/TEST-04-FULL-SYSTEMD/test.sh b/test/TEST-04-FULL-SYSTEMD/test.sh -index cf79c71..e4a3db6 100755 ---- a/test/TEST-04-FULL-SYSTEMD/test.sh -+++ b/test/TEST-04-FULL-SYSTEMD/test.sh -@@ -53,13 +53,13 @@ test_setup() { - shopt -q -s globstar - - # Create what will eventually be our root filesystem onto an overlay -- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ -+ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ - -m "test-root dbus" \ - -I "ldconfig" \ - -i ./test-init.sh /sbin/test-init \ - -i ./fstab /etc/fstab \ -- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ - --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ - -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 - -@@ -118,7 +118,7 @@ EOF - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "test-makeroot bash btrfs rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ - -I "mkfs.btrfs btrfs sync" \ -@@ -154,7 +154,7 @@ EOF - [ -e /etc/machine-id ] && EXTRA_MACHINE="/etc/machine-id" - [ -e /etc/machine-info ] && EXTRA_MACHINE+=" /etc/machine-info" - -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -a "test systemd i18n qemu" \ - ${EXTRA_MACHINE:+-I "$EXTRA_MACHINE"} \ - -o "network plymouth lvm mdraid resume crypt caps dm terminfo usrmount kernel-network-modules rngd" \ -diff --git a/test/TEST-10-RAID/test.sh b/test/TEST-10-RAID/test.sh -index 494dbcc..7f9f59a 100755 ---- a/test/TEST-10-RAID/test.sh -+++ b/test/TEST-10-RAID/test.sh -@@ -45,8 +45,8 @@ test_setup() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -75,7 +75,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash crypt lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ - --nomdadmconf \ -@@ -118,7 +118,7 @@ test_setup() { - echo -n "test" > "$initdir"/etc/key - ) - -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth network kernel-network-modules" \ - -a "debug" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ -diff --git a/test/TEST-11-LVM/test.sh b/test/TEST-11-LVM/test.sh -index b3ec547..b4b9e88 100755 ---- a/test/TEST-11-LVM/test.sh -+++ b/test/TEST-11-LVM/test.sh -@@ -46,8 +46,8 @@ test_setup() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -76,7 +76,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ - --no-hostonly-cmdline -N \ -@@ -111,7 +111,7 @@ test_setup() { - inst_hook shutdown-emergency 000 ./hard-off.sh - inst_hook emergency 000 ./hard-off.sh - ) -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth network kernel-network-modules" \ - -a "debug" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ -diff --git a/test/TEST-12-RAID-DEG/test.sh b/test/TEST-12-RAID-DEG/test.sh -index a41f721..c3cd8d3 100755 ---- a/test/TEST-12-RAID-DEG/test.sh -+++ b/test/TEST-12-RAID-DEG/test.sh -@@ -77,8 +77,8 @@ test_setup() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -106,7 +106,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash crypt lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ - --no-hostonly-cmdline -N \ -@@ -154,7 +154,7 @@ test_setup() { - chmod 0600 "$initdir"/etc/key - ) - -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth network kernel-network-modules" \ - -a "debug" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ -diff --git a/test/TEST-13-ENC-RAID-LVM/test.sh b/test/TEST-13-ENC-RAID-LVM/test.sh -index 982aede..c7b640c 100755 ---- a/test/TEST-13-ENC-RAID-LVM/test.sh -+++ b/test/TEST-13-ENC-RAID-LVM/test.sh -@@ -74,8 +74,8 @@ test_setup() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -103,7 +103,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash crypt lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ - --no-hostonly-cmdline -N \ -@@ -153,7 +153,7 @@ test_setup() { - echo -n test > "$initdir"/etc/key - chmod 0600 "$initdir"/etc/key - ) -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth network kernel-network-modules" \ - -a "debug" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ -diff --git a/test/TEST-14-IMSM/test.sh b/test/TEST-14-IMSM/test.sh -index f089e25..e68bfe2 100755 ---- a/test/TEST-14-IMSM/test.sh -+++ b/test/TEST-14-IMSM/test.sh -@@ -72,8 +72,8 @@ test_setup() { - inst_multiple -o ${_terminfodir}/l/linux - inst_simple /etc/os-release - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -100,7 +100,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash lvm mdraid dmraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod dm-multipath dm-crypt dm-round-robin faulty linear multipath raid0 raid10 raid1 raid456" \ - --no-hostonly-cmdline -N \ -@@ -141,7 +141,7 @@ test_setup() { - inst_hook shutdown-emergency 000 ./hard-off.sh - inst_hook emergency 000 ./hard-off.sh - ) -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth network kernel-network-modules" \ - -a "debug" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ -diff --git a/test/TEST-15-BTRFSRAID/test.sh b/test/TEST-15-BTRFSRAID/test.sh -index 6d1ecb6..63d511a 100755 ---- a/test/TEST-15-BTRFSRAID/test.sh -+++ b/test/TEST-15-BTRFSRAID/test.sh -@@ -49,8 +49,8 @@ test_setup() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -78,7 +78,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash btrfs rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ - --nomdadmconf \ -@@ -118,7 +118,7 @@ test_setup() { - inst_hook shutdown-emergency 000 ./hard-off.sh - inst_hook emergency 000 ./hard-off.sh - ) -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth network kernel-network-modules" \ - -a "debug" \ - -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ -diff --git a/test/TEST-16-DMSQUASH/test.sh b/test/TEST-16-DMSQUASH/test.sh -index d8a7bc7..f2e745d 100755 ---- a/test/TEST-16-DMSQUASH/test.sh -+++ b/test/TEST-16-DMSQUASH/test.sh -@@ -59,11 +59,11 @@ test_run() { - - test_setup() { - # Create what will eventually be our root filesystem onto an overlay -- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ -+ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ - -m "test-root" \ - -i ./test-init.sh /sbin/init \ -- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ -+ -i "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ - --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ - -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 - mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* -@@ -72,7 +72,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - --modules "test-makeroot rootfs-block qemu" \ - --drivers "ext4 sd_mod" \ - --install "sfdisk mkfs.ext4 mksquashfs" \ -@@ -100,7 +100,7 @@ test_setup() { - return 1 - fi - -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - --modules "test dash dmsquash-live qemu" \ - --omit "rngd" \ - --drivers "ext4 sd_mod" \ -@@ -108,7 +108,7 @@ test_setup() { - --no-hostonly --no-hostonly-cmdline \ - --force "$TESTDIR"/initramfs.testing "$KVERSION" || return 1 - -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - --modules "test dmsquash-live-autooverlay qemu" \ - --omit "rngd" \ - --drivers "ext4 sd_mod" \ -diff --git a/test/TEST-17-LVM-THIN/test.sh b/test/TEST-17-LVM-THIN/test.sh -index a9e2cb6..60f126a 100755 ---- a/test/TEST-17-LVM-THIN/test.sh -+++ b/test/TEST-17-LVM-THIN/test.sh -@@ -44,8 +44,8 @@ test_setup() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -74,7 +74,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ - --no-hostonly-cmdline -N \ -@@ -109,7 +109,7 @@ test_setup() { - inst_hook shutdown-emergency 000 ./hard-off.sh - inst_hook emergency 000 ./hard-off.sh - ) -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth network kernel-network-modules" \ - -a "debug" -I lvs \ - -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ -diff --git a/test/TEST-20-NFS/test.sh b/test/TEST-20-NFS/test.sh -index c637b57..136c1bb 100755 ---- a/test/TEST-20-NFS/test.sh -+++ b/test/TEST-20-NFS/test.sh -@@ -316,8 +316,8 @@ test_setup() { - fi - done - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -360,7 +360,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/server/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/server/overlay / \ - -m "bash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --nomdadmconf \ -@@ -398,7 +398,7 @@ test_setup() { - ) - - # Make client's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth" \ - -a "dmsquash-live debug watchdog ${USE_NETWORK}" \ - --no-hostonly-cmdline -N \ -@@ -414,7 +414,7 @@ test_setup() { - inst_hook pre-mount 99 ./wait-if-server.sh - ) - # Make server's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash rootfs-block debug kernel-modules watchdog qemu network network-legacy" \ - -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 i6300esb" \ - --no-hostonly-cmdline -N \ -diff --git a/test/TEST-30-ISCSI/test.sh b/test/TEST-30-ISCSI/test.sh -index 83368e2..703ef9a 100755 ---- a/test/TEST-30-ISCSI/test.sh -+++ b/test/TEST-30-ISCSI/test.sh -@@ -153,8 +153,8 @@ test_setup() { - inst_multiple -o ${_terminfodir}/l/linux - inst_simple /etc/os-release - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -179,7 +179,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash crypt lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --no-hostonly-cmdline -N \ -@@ -270,7 +270,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --nomdadmconf \ -@@ -307,7 +307,7 @@ test_setup() { - inst_simple ./client.link /etc/systemd/network/01-client.link - ) - # Make client's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth dmraid nfs" \ - -a "debug ${USE_NETWORK}" \ - --no-hostonly-cmdline -N \ -@@ -324,7 +324,7 @@ test_setup() { - inst_multiple sysctl - ) - # Make server's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -a "dash rootfs-block debug kernel-modules network network-legacy" \ - -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 drbg" \ - --no-hostonly-cmdline -N \ -diff --git a/test/TEST-35-ISCSI-MULTI/test.sh b/test/TEST-35-ISCSI-MULTI/test.sh -index 20247d9..d9434bc 100755 ---- a/test/TEST-35-ISCSI-MULTI/test.sh -+++ b/test/TEST-35-ISCSI-MULTI/test.sh -@@ -165,8 +165,8 @@ test_setup() { - inst_multiple -o ${_terminfodir}/l/linux - inst_simple /etc/os-release - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -191,7 +191,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash crypt lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --no-hostonly-cmdline -N \ -@@ -282,7 +282,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --nomdadmconf \ -@@ -319,7 +319,7 @@ test_setup() { - inst_simple ./client.link /etc/systemd/network/01-client.link - ) - # Make client's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth dmraid nfs" \ - -a "debug ${USE_NETWORK}" \ - --no-hostonly-cmdline -N \ -@@ -335,7 +335,7 @@ test_setup() { - inst_hook pre-mount 99 ./wait-if-server.sh - ) - # Make server's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -a "dash rootfs-block debug kernel-modules network network-legacy" \ - -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 drbg" \ - --no-hostonly-cmdline -N \ -diff --git a/test/TEST-40-NBD/test.sh b/test/TEST-40-NBD/test.sh -index 8f8b156..4496c10 100755 ---- a/test/TEST-40-NBD/test.sh -+++ b/test/TEST-40-NBD/test.sh -@@ -212,8 +212,8 @@ make_encrypted_root() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -247,7 +247,7 @@ make_encrypted_root() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash crypt lvm mdraid kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 ext3 sd_mod" \ - --no-hostonly-cmdline -N \ -@@ -293,8 +293,8 @@ make_client_root() { - done - inst_multiple -o ${_terminfodir}/l/linux - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -327,7 +327,7 @@ make_client_root() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --nomdadmconf \ -@@ -426,7 +426,7 @@ EOF - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --nomdadmconf \ -@@ -479,7 +479,7 @@ test_setup() { - inst_simple ./client.link /etc/systemd/network/01-client.link - ) - -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "plymouth iscsi nfs" \ - -a "debug watchdog ${USE_NETWORK}" \ - --no-hostonly-cmdline -N \ -@@ -494,7 +494,7 @@ test_setup() { - inst_simple ./server.link /etc/systemd/network/01-server.link - inst_hook pre-mount 99 ./wait-if-server.sh - ) -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -a "rootfs-block debug kernel-modules network network-legacy" \ - -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 drbg" \ - --no-hostonly-cmdline -N \ -diff --git a/test/TEST-50-MULTINIC/test.sh b/test/TEST-50-MULTINIC/test.sh -index 21362b9..7e23eb0 100755 ---- a/test/TEST-50-MULTINIC/test.sh -+++ b/test/TEST-50-MULTINIC/test.sh -@@ -263,8 +263,8 @@ test_setup() { - fi - done - -- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-lib.sh" "/lib/dracut-lib.sh" -+ inst_simple "${MODULES_D}/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" - inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" - ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" - ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" -@@ -307,7 +307,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --nomdadmconf \ -@@ -347,7 +347,7 @@ test_setup() { - inst_hook pre-pivot 85 "$basedir/modules.d/45ifcfg/write-ifcfg.sh" - ) - # Make client's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -o "ifcfg plymouth" \ - -a "debug watchdog ${USE_NETWORK}" \ - --no-hostonly-cmdline -N \ -@@ -363,7 +363,7 @@ test_setup() { - inst_hook pre-mount 99 ./wait-if-server.sh - ) - # Make server's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "dash rootfs-block debug kernel-modules watchdog qemu network network-legacy" \ - -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod nfsv2 nfsv3 nfsv4 nfs_acl nfs_layout_nfsv41_files nfsd e1000 i6300esb ib700wdt" \ - --no-hostonly-cmdline -N \ -diff --git a/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh b/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh -index 12afca9..427b4d2 100755 ---- a/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh -+++ b/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh -@@ -334,7 +334,7 @@ test_setup() { - # create an initramfs that will create the target root filesystem. - # We do it this way so that we do not risk trashing the host mdraid - # devices, volume groups, encrypted partitions, etc. -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - -m "bash rootfs-block kernel-modules qemu" \ - -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ - --nomdadmconf \ -@@ -361,7 +361,7 @@ test_setup() { - inst_simple ./client.link /etc/systemd/network/01-client.link - ) - # Make client's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - --no-early-microcode \ - -o "plymouth" \ - -a "debug ${USE_NETWORK}" \ -@@ -377,7 +377,7 @@ test_setup() { - inst_hook pre-mount 99 ./wait-if-server.sh - ) - # Make server's dracut image -- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ -+ "$DRACUT" -l -i "$TESTDIR"/overlay / \ - --no-early-microcode \ - -m "rootfs-block debug kernel-modules watchdog qemu network network-legacy" \ - -d "ipvlan macvlan af_packet piix ide-gd_mod ata_piix ext3 sd_mod nfsv2 nfsv3 nfsv4 nfs_acl nfs_layout_nfsv41_files nfsd virtio-net i6300esb ib700wdt" \ -diff --git a/test/TEST-63-DRACUT-CPIO/test.sh b/test/TEST-63-DRACUT-CPIO/test.sh -index be93cfb..163bab2 100755 ---- a/test/TEST-63-DRACUT-CPIO/test.sh -+++ b/test/TEST-63-DRACUT-CPIO/test.sh -@@ -30,7 +30,7 @@ echo o > /proc/sysrq-trigger - sleep 20 - EOF - -- "$basedir"/dracut.sh -l --drivers "" \ -+ "$DRACUT" -l --drivers "" \ - "${dracut_cpio_params[@]}" \ - --modules "bash base" \ - --include "$tdir/init.sh" /lib/dracut/hooks/emergency/00-init.sh \ -diff --git a/test/test-functions b/test/test-functions -index 204abae..5d28374 100644 ---- a/test/test-functions -+++ b/test/test-functions -@@ -12,6 +12,9 @@ export TESTDIR - - if [[ -z $basedir ]]; then basedir="$(realpath ../..)"; fi - -+DRACUT=${DRACUT-${basedir}/dracut.sh} -+MODULES_D=${MODULES_D-${basedir}/modules.d} -+ - command -v test_check &> /dev/null || test_check() { - : - } diff -Nru dracut-059/debian/patches/test-make-dracut-directory-configurable.patch dracut-059/debian/patches/test-make-dracut-directory-configurable.patch --- dracut-059/debian/patches/test-make-dracut-directory-configurable.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/test-make-dracut-directory-configurable.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,601 @@ +From: Benjamin Drung +Date: Wed, 16 Aug 2023 11:06:16 +0200 +Subject: test: make dracut directory configurable + +Make the directory of the `dracut.sh` script configurable to allow +running the test suite out-of-tree. + +This change is used to run the test suite against the installed dracut +in an autopkgtest for the Debian/Ubuntu package. + +Forwarded: https://github.com/dracutdevs/dracut/pull/2484 +Signed-off-by: Benjamin Drung +--- + test/TEST-01-BASIC/test.sh | 6 +++--- + test/TEST-02-SYSTEMD/test.sh | 6 +++--- + test/TEST-03-USR-MOUNT/test.sh | 6 +++--- + test/TEST-04-FULL-SYSTEMD/test.sh | 6 +++--- + test/TEST-10-RAID/test.sh | 4 ++-- + test/TEST-11-LVM/test.sh | 4 ++-- + test/TEST-12-RAID-DEG/test.sh | 4 ++-- + test/TEST-13-ENC-RAID-LVM/test.sh | 4 ++-- + test/TEST-14-IMSM/test.sh | 4 ++-- + test/TEST-15-BTRFSRAID/test.sh | 4 ++-- + test/TEST-16-DMSQUASH/test.sh | 8 ++++---- + test/TEST-17-LVM-THIN/test.sh | 4 ++-- + test/TEST-20-NFS/test.sh | 6 +++--- + test/TEST-30-ISCSI/test.sh | 8 ++++---- + test/TEST-35-ISCSI-MULTI/test.sh | 8 ++++---- + test/TEST-40-NBD/test.sh | 10 +++++----- + test/TEST-50-MULTINIC/test.sh | 6 +++--- + test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh | 6 +++--- + test/TEST-63-DRACUT-CPIO/test.sh | 2 +- + test/test-functions | 2 ++ + 20 files changed, 55 insertions(+), 53 deletions(-) + +diff --git a/test/TEST-01-BASIC/test.sh b/test/TEST-01-BASIC/test.sh +index 37059d4..f387472 100755 +--- a/test/TEST-01-BASIC/test.sh ++++ b/test/TEST-01-BASIC/test.sh +@@ -25,7 +25,7 @@ test_run() { + + test_setup() { + # Create what will eventually be our root filesystem onto an overlay +- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ ++ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root" \ + -i ./test-init.sh /sbin/init \ + -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +@@ -38,7 +38,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "test-makeroot dash rootfs-block kernel-modules" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + -I "mkfs.ext3" \ +@@ -64,7 +64,7 @@ test_setup() { + rm -- "$TESTDIR"/marker.img + + # make sure --omit-drivers does not filter out drivers using regexp to test for an earlier regression (assuming there is no one letter linux kernel module needed to run the test) +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -a "test watchdog" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod i6300esb ib700wdt" \ + --omit-drivers 'a b c d e f g h i j k l m n o p q r s t u v w x y z' \ +diff --git a/test/TEST-02-SYSTEMD/test.sh b/test/TEST-02-SYSTEMD/test.sh +index b915b8f..27addc4 100755 +--- a/test/TEST-02-SYSTEMD/test.sh ++++ b/test/TEST-02-SYSTEMD/test.sh +@@ -27,7 +27,7 @@ test_run() { + + test_setup() { + # Create what will eventually be our root filesystem onto an overlay +- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ ++ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root" \ + -i ./test-init.sh /sbin/init \ + -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +@@ -40,7 +40,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "test-makeroot dash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + -I "mkfs.ext3" \ +@@ -67,7 +67,7 @@ test_setup() { + + # systemd-analyze.sh calls man indirectly + # make the man command succeed always +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -a "test systemd" \ + -o "network kernel-network-modules" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ +diff --git a/test/TEST-03-USR-MOUNT/test.sh b/test/TEST-03-USR-MOUNT/test.sh +index b78b56b..8887520 100755 +--- a/test/TEST-03-USR-MOUNT/test.sh ++++ b/test/TEST-03-USR-MOUNT/test.sh +@@ -43,7 +43,7 @@ test_run() { + + test_setup() { + # Create what will eventually be our root filesystem onto an overlay +- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ ++ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root" \ + -i ./test-init.sh /sbin/init \ + -i ./fstab /etc/fstab \ +@@ -57,7 +57,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "test-makeroot dash btrfs rootfs-block kernel-modules" \ + -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ + -I "mkfs.btrfs" \ +@@ -89,7 +89,7 @@ test_setup() { + return 1 + fi + +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -a "test watchdog" \ + -o "network kernel-network-modules" \ + -d "piix ide-gd_mod ata_piix btrfs sd_mod i6300esb ib700wdt" \ +diff --git a/test/TEST-04-FULL-SYSTEMD/test.sh b/test/TEST-04-FULL-SYSTEMD/test.sh +index cf79c71..2fcb87d 100755 +--- a/test/TEST-04-FULL-SYSTEMD/test.sh ++++ b/test/TEST-04-FULL-SYSTEMD/test.sh +@@ -53,7 +53,7 @@ test_setup() { + shopt -q -s globstar + + # Create what will eventually be our root filesystem onto an overlay +- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ ++ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root dbus" \ + -I "ldconfig" \ + -i ./test-init.sh /sbin/test-init \ +@@ -118,7 +118,7 @@ EOF + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "test-makeroot bash btrfs rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ + -I "mkfs.btrfs btrfs sync" \ +@@ -154,7 +154,7 @@ EOF + [ -e /etc/machine-id ] && EXTRA_MACHINE="/etc/machine-id" + [ -e /etc/machine-info ] && EXTRA_MACHINE+=" /etc/machine-info" + +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -a "test systemd i18n qemu" \ + ${EXTRA_MACHINE:+-I "$EXTRA_MACHINE"} \ + -o "network plymouth lvm mdraid resume crypt caps dm terminfo usrmount kernel-network-modules rngd" \ +diff --git a/test/TEST-10-RAID/test.sh b/test/TEST-10-RAID/test.sh +index 494dbcc..3211030 100755 +--- a/test/TEST-10-RAID/test.sh ++++ b/test/TEST-10-RAID/test.sh +@@ -75,7 +75,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash crypt lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ + --nomdadmconf \ +@@ -118,7 +118,7 @@ test_setup() { + echo -n "test" > "$initdir"/etc/key + ) + +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth network kernel-network-modules" \ + -a "debug" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ +diff --git a/test/TEST-11-LVM/test.sh b/test/TEST-11-LVM/test.sh +index b3ec547..a9cb8e2 100755 +--- a/test/TEST-11-LVM/test.sh ++++ b/test/TEST-11-LVM/test.sh +@@ -76,7 +76,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ + --no-hostonly-cmdline -N \ +@@ -111,7 +111,7 @@ test_setup() { + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh + ) +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth network kernel-network-modules" \ + -a "debug" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ +diff --git a/test/TEST-12-RAID-DEG/test.sh b/test/TEST-12-RAID-DEG/test.sh +index a41f721..05080b2 100755 +--- a/test/TEST-12-RAID-DEG/test.sh ++++ b/test/TEST-12-RAID-DEG/test.sh +@@ -106,7 +106,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash crypt lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ + --no-hostonly-cmdline -N \ +@@ -154,7 +154,7 @@ test_setup() { + chmod 0600 "$initdir"/etc/key + ) + +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth network kernel-network-modules" \ + -a "debug" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ +diff --git a/test/TEST-13-ENC-RAID-LVM/test.sh b/test/TEST-13-ENC-RAID-LVM/test.sh +index 982aede..b985125 100755 +--- a/test/TEST-13-ENC-RAID-LVM/test.sh ++++ b/test/TEST-13-ENC-RAID-LVM/test.sh +@@ -103,7 +103,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash crypt lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ + --no-hostonly-cmdline -N \ +@@ -153,7 +153,7 @@ test_setup() { + echo -n test > "$initdir"/etc/key + chmod 0600 "$initdir"/etc/key + ) +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth network kernel-network-modules" \ + -a "debug" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ +diff --git a/test/TEST-14-IMSM/test.sh b/test/TEST-14-IMSM/test.sh +index f089e25..3584a5d 100755 +--- a/test/TEST-14-IMSM/test.sh ++++ b/test/TEST-14-IMSM/test.sh +@@ -100,7 +100,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash lvm mdraid dmraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod dm-multipath dm-crypt dm-round-robin faulty linear multipath raid0 raid10 raid1 raid456" \ + --no-hostonly-cmdline -N \ +@@ -141,7 +141,7 @@ test_setup() { + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh + ) +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth network kernel-network-modules" \ + -a "debug" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ +diff --git a/test/TEST-15-BTRFSRAID/test.sh b/test/TEST-15-BTRFSRAID/test.sh +index 6d1ecb6..a8d73d3 100755 +--- a/test/TEST-15-BTRFSRAID/test.sh ++++ b/test/TEST-15-BTRFSRAID/test.sh +@@ -78,7 +78,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash btrfs rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ + --nomdadmconf \ +@@ -118,7 +118,7 @@ test_setup() { + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh + ) +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth network kernel-network-modules" \ + -a "debug" \ + -d "piix ide-gd_mod ata_piix btrfs sd_mod" \ +diff --git a/test/TEST-16-DMSQUASH/test.sh b/test/TEST-16-DMSQUASH/test.sh +index d8a7bc7..83189e5 100755 +--- a/test/TEST-16-DMSQUASH/test.sh ++++ b/test/TEST-16-DMSQUASH/test.sh +@@ -59,7 +59,7 @@ test_run() { + + test_setup() { + # Create what will eventually be our root filesystem onto an overlay +- "$basedir"/dracut.sh -l --keep --tmpdir "$TESTDIR" \ ++ "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root" \ + -i ./test-init.sh /sbin/init \ + -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +@@ -72,7 +72,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + --modules "test-makeroot rootfs-block qemu" \ + --drivers "ext4 sd_mod" \ + --install "sfdisk mkfs.ext4 mksquashfs" \ +@@ -100,7 +100,7 @@ test_setup() { + return 1 + fi + +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + --modules "test dash dmsquash-live qemu" \ + --omit "rngd" \ + --drivers "ext4 sd_mod" \ +@@ -108,7 +108,7 @@ test_setup() { + --no-hostonly --no-hostonly-cmdline \ + --force "$TESTDIR"/initramfs.testing "$KVERSION" || return 1 + +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + --modules "test dmsquash-live-autooverlay qemu" \ + --omit "rngd" \ + --drivers "ext4 sd_mod" \ +diff --git a/test/TEST-17-LVM-THIN/test.sh b/test/TEST-17-LVM-THIN/test.sh +index a9e2cb6..54425ba 100755 +--- a/test/TEST-17-LVM-THIN/test.sh ++++ b/test/TEST-17-LVM-THIN/test.sh +@@ -74,7 +74,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ + --no-hostonly-cmdline -N \ +@@ -109,7 +109,7 @@ test_setup() { + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh + ) +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth network kernel-network-modules" \ + -a "debug" -I lvs \ + -d "piix ide-gd_mod ata_piix ext2 sd_mod" \ +diff --git a/test/TEST-20-NFS/test.sh b/test/TEST-20-NFS/test.sh +index c637b57..b7ee214 100755 +--- a/test/TEST-20-NFS/test.sh ++++ b/test/TEST-20-NFS/test.sh +@@ -360,7 +360,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/server/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/server/overlay / \ + -m "bash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --nomdadmconf \ +@@ -398,7 +398,7 @@ test_setup() { + ) + + # Make client's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth" \ + -a "dmsquash-live debug watchdog ${USE_NETWORK}" \ + --no-hostonly-cmdline -N \ +@@ -414,7 +414,7 @@ test_setup() { + inst_hook pre-mount 99 ./wait-if-server.sh + ) + # Make server's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash rootfs-block debug kernel-modules watchdog qemu network network-legacy" \ + -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 i6300esb" \ + --no-hostonly-cmdline -N \ +diff --git a/test/TEST-30-ISCSI/test.sh b/test/TEST-30-ISCSI/test.sh +index 83368e2..02151c9 100755 +--- a/test/TEST-30-ISCSI/test.sh ++++ b/test/TEST-30-ISCSI/test.sh +@@ -179,7 +179,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash crypt lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --no-hostonly-cmdline -N \ +@@ -270,7 +270,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --nomdadmconf \ +@@ -307,7 +307,7 @@ test_setup() { + inst_simple ./client.link /etc/systemd/network/01-client.link + ) + # Make client's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth dmraid nfs" \ + -a "debug ${USE_NETWORK}" \ + --no-hostonly-cmdline -N \ +@@ -324,7 +324,7 @@ test_setup() { + inst_multiple sysctl + ) + # Make server's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -a "dash rootfs-block debug kernel-modules network network-legacy" \ + -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 drbg" \ + --no-hostonly-cmdline -N \ +diff --git a/test/TEST-35-ISCSI-MULTI/test.sh b/test/TEST-35-ISCSI-MULTI/test.sh +index 20247d9..672052b 100755 +--- a/test/TEST-35-ISCSI-MULTI/test.sh ++++ b/test/TEST-35-ISCSI-MULTI/test.sh +@@ -191,7 +191,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash crypt lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --no-hostonly-cmdline -N \ +@@ -282,7 +282,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --nomdadmconf \ +@@ -319,7 +319,7 @@ test_setup() { + inst_simple ./client.link /etc/systemd/network/01-client.link + ) + # Make client's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth dmraid nfs" \ + -a "debug ${USE_NETWORK}" \ + --no-hostonly-cmdline -N \ +@@ -335,7 +335,7 @@ test_setup() { + inst_hook pre-mount 99 ./wait-if-server.sh + ) + # Make server's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -a "dash rootfs-block debug kernel-modules network network-legacy" \ + -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 drbg" \ + --no-hostonly-cmdline -N \ +diff --git a/test/TEST-40-NBD/test.sh b/test/TEST-40-NBD/test.sh +index 8f8b156..9545a1a 100755 +--- a/test/TEST-40-NBD/test.sh ++++ b/test/TEST-40-NBD/test.sh +@@ -247,7 +247,7 @@ make_encrypted_root() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash crypt lvm mdraid kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 ext3 sd_mod" \ + --no-hostonly-cmdline -N \ +@@ -327,7 +327,7 @@ make_client_root() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --nomdadmconf \ +@@ -426,7 +426,7 @@ EOF + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --nomdadmconf \ +@@ -479,7 +479,7 @@ test_setup() { + inst_simple ./client.link /etc/systemd/network/01-client.link + ) + +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "plymouth iscsi nfs" \ + -a "debug watchdog ${USE_NETWORK}" \ + --no-hostonly-cmdline -N \ +@@ -494,7 +494,7 @@ test_setup() { + inst_simple ./server.link /etc/systemd/network/01-server.link + inst_hook pre-mount 99 ./wait-if-server.sh + ) +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -a "rootfs-block debug kernel-modules network network-legacy" \ + -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod e1000 drbg" \ + --no-hostonly-cmdline -N \ +diff --git a/test/TEST-50-MULTINIC/test.sh b/test/TEST-50-MULTINIC/test.sh +index 21362b9..f1e8ba1 100755 +--- a/test/TEST-50-MULTINIC/test.sh ++++ b/test/TEST-50-MULTINIC/test.sh +@@ -307,7 +307,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --nomdadmconf \ +@@ -347,7 +347,7 @@ test_setup() { + inst_hook pre-pivot 85 "$basedir/modules.d/45ifcfg/write-ifcfg.sh" + ) + # Make client's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -o "ifcfg plymouth" \ + -a "debug watchdog ${USE_NETWORK}" \ + --no-hostonly-cmdline -N \ +@@ -363,7 +363,7 @@ test_setup() { + inst_hook pre-mount 99 ./wait-if-server.sh + ) + # Make server's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "dash rootfs-block debug kernel-modules watchdog qemu network network-legacy" \ + -d "af_packet piix ide-gd_mod ata_piix ext3 sd_mod nfsv2 nfsv3 nfsv4 nfs_acl nfs_layout_nfsv41_files nfsd e1000 i6300esb ib700wdt" \ + --no-hostonly-cmdline -N \ +diff --git a/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh b/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh +index 12afca9..427b4d2 100755 +--- a/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh ++++ b/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh +@@ -334,7 +334,7 @@ test_setup() { + # create an initramfs that will create the target root filesystem. + # We do it this way so that we do not risk trashing the host mdraid + # devices, volume groups, encrypted partitions, etc. +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + -m "bash rootfs-block kernel-modules qemu" \ + -d "piix ide-gd_mod ata_piix ext3 sd_mod" \ + --nomdadmconf \ +@@ -361,7 +361,7 @@ test_setup() { + inst_simple ./client.link /etc/systemd/network/01-client.link + ) + # Make client's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + --no-early-microcode \ + -o "plymouth" \ + -a "debug ${USE_NETWORK}" \ +@@ -377,7 +377,7 @@ test_setup() { + inst_hook pre-mount 99 ./wait-if-server.sh + ) + # Make server's dracut image +- "$basedir"/dracut.sh -l -i "$TESTDIR"/overlay / \ ++ "$DRACUT" -l -i "$TESTDIR"/overlay / \ + --no-early-microcode \ + -m "rootfs-block debug kernel-modules watchdog qemu network network-legacy" \ + -d "ipvlan macvlan af_packet piix ide-gd_mod ata_piix ext3 sd_mod nfsv2 nfsv3 nfsv4 nfs_acl nfs_layout_nfsv41_files nfsd virtio-net i6300esb ib700wdt" \ +diff --git a/test/TEST-63-DRACUT-CPIO/test.sh b/test/TEST-63-DRACUT-CPIO/test.sh +index be93cfb..163bab2 100755 +--- a/test/TEST-63-DRACUT-CPIO/test.sh ++++ b/test/TEST-63-DRACUT-CPIO/test.sh +@@ -30,7 +30,7 @@ echo o > /proc/sysrq-trigger + sleep 20 + EOF + +- "$basedir"/dracut.sh -l --drivers "" \ ++ "$DRACUT" -l --drivers "" \ + "${dracut_cpio_params[@]}" \ + --modules "bash base" \ + --include "$tdir/init.sh" /lib/dracut/hooks/emergency/00-init.sh \ +diff --git a/test/test-functions b/test/test-functions +index 204abae..e1b0618 100644 +--- a/test/test-functions ++++ b/test/test-functions +@@ -12,6 +12,8 @@ export TESTDIR + + if [[ -z $basedir ]]; then basedir="$(realpath ../..)"; fi + ++DRACUT=${DRACUT-${basedir}/dracut.sh} ++ + command -v test_check &> /dev/null || test_check() { + : + } diff -Nru dracut-059/debian/patches/test-make-package-libdir-configurable.patch dracut-059/debian/patches/test-make-package-libdir-configurable.patch --- dracut-059/debian/patches/test-make-package-libdir-configurable.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/test-make-package-libdir-configurable.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,913 @@ +From: Benjamin Drung +Date: Wed, 16 Aug 2023 13:50:47 +0200 +Subject: test: make package libdir configurable + +Make the package libdir configurable to allow running the test suite +out-of-tree. `PKGLIBDIR` can be pointed to the installed dracut libdir. +Use `PKGLIBDIR` for the location of `dracut-init.sh`, `dracut-install`, +`dracut-util`, `dracut-cpio`, and `modules.d`. + +This change is used to run the test suite against the installed dracut +in an autopkgtest for the Debian/Ubuntu package. + +Forwarded: https://github.com/dracutdevs/dracut/pull/2484 +Signed-off-by: Benjamin Drung +--- + test/TEST-01-BASIC/test.sh | 4 ++-- + test/TEST-02-SYSTEMD/test.sh | 4 ++-- + test/TEST-03-USR-MOUNT/test.sh | 4 ++-- + test/TEST-04-FULL-SYSTEMD/test.sh | 12 ++++++------ + test/TEST-10-RAID/test.sh | 12 ++++++------ + test/TEST-11-LVM/test.sh | 12 ++++++------ + test/TEST-12-RAID-DEG/test.sh | 12 ++++++------ + test/TEST-13-ENC-RAID-LVM/test.sh | 12 ++++++------ + test/TEST-14-IMSM/test.sh | 12 ++++++------ + test/TEST-15-BTRFSRAID/test.sh | 12 ++++++------ + test/TEST-16-DMSQUASH/test.sh | 4 ++-- + test/TEST-17-LVM-THIN/test.sh | 12 ++++++------ + test/TEST-20-NFS/test.sh | 16 ++++++++-------- + test/TEST-30-ISCSI/test.sh | 18 +++++++++--------- + test/TEST-35-ISCSI-MULTI/test.sh | 18 +++++++++--------- + test/TEST-40-NBD/test.sh | 28 ++++++++++++++-------------- + test/TEST-50-MULTINIC/test.sh | 18 +++++++++--------- + test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh | 10 +++++----- + test/TEST-63-DRACUT-CPIO/test.sh | 2 +- + test/TEST-98-GETARG/test.sh | 8 ++++---- + test/test-functions | 1 + + 21 files changed, 116 insertions(+), 115 deletions(-) + +diff --git a/test/TEST-01-BASIC/test.sh b/test/TEST-01-BASIC/test.sh +index f387472..7832879 100755 +--- a/test/TEST-01-BASIC/test.sh ++++ b/test/TEST-01-BASIC/test.sh +@@ -28,8 +28,8 @@ test_setup() { + "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root" \ + -i ./test-init.sh /sbin/init \ +- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ + --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ + -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 + mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* +diff --git a/test/TEST-02-SYSTEMD/test.sh b/test/TEST-02-SYSTEMD/test.sh +index 27addc4..c0e5906 100755 +--- a/test/TEST-02-SYSTEMD/test.sh ++++ b/test/TEST-02-SYSTEMD/test.sh +@@ -30,8 +30,8 @@ test_setup() { + "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root" \ + -i ./test-init.sh /sbin/init \ +- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ + --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ + -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 + mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* +diff --git a/test/TEST-03-USR-MOUNT/test.sh b/test/TEST-03-USR-MOUNT/test.sh +index 8887520..7bf32c4 100755 +--- a/test/TEST-03-USR-MOUNT/test.sh ++++ b/test/TEST-03-USR-MOUNT/test.sh +@@ -47,8 +47,8 @@ test_setup() { + -m "test-root" \ + -i ./test-init.sh /sbin/init \ + -i ./fstab /etc/fstab \ +- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ + --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ + -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 + mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* +diff --git a/test/TEST-04-FULL-SYSTEMD/test.sh b/test/TEST-04-FULL-SYSTEMD/test.sh +index 2fcb87d..6154cf4 100755 +--- a/test/TEST-04-FULL-SYSTEMD/test.sh ++++ b/test/TEST-04-FULL-SYSTEMD/test.sh +@@ -58,19 +58,19 @@ test_setup() { + -I "ldconfig" \ + -i ./test-init.sh /sbin/test-init \ + -i ./fstab /etc/fstab \ +- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ + --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ + -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 + + mkdir -p "$TESTDIR"/overlay/source && cp -a "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* && export initdir=$TESTDIR/overlay/source + + if type -P rpm &> /dev/null; then +- rpm -ql systemd | xargs -r "$basedir"/dracut-install ${initdir:+-D "$initdir"} -o -a -l ++ rpm -ql systemd | xargs -r "$PKGLIBDIR"/dracut-install ${initdir:+-D "$initdir"} -o -a -l + elif type -P dpkg &> /dev/null; then +- dpkg -L systemd | xargs -r "$basedir"/dracut-install ${initdir:+-D "$initdir"} -o -a -l ++ dpkg -L systemd | xargs -r "$PKGLIBDIR"/dracut-install ${initdir:+-D "$initdir"} -o -a -l + elif type -P pacman &> /dev/null; then +- pacman -Q -l systemd | while read -r _ a; do printf -- "%s\0" "$a"; done | xargs -0 -r "$basedir"/dracut-install ${initdir:+-D "$initdir"} -o -a -l ++ pacman -Q -l systemd | while read -r _ a; do printf -- "%s\0" "$a"; done | xargs -0 -r "$PKGLIBDIR"/dracut-install ${initdir:+-D "$initdir"} -o -a -l + else + echo "Can't install systemd base" + return 1 +@@ -84,7 +84,7 @@ test_setup() { + | while read -r i || [ -n "$i" ]; do + i=${i##Exec*=} + i=${i##-} +- "$basedir"/dracut-install ${initdir:+-D "$initdir"} -o -a -l "$i" ++ "$PKGLIBDIR"/dracut-install ${initdir:+-D "$initdir"} -o -a -l "$i" + done + + # setup the testsuite target +diff --git a/test/TEST-10-RAID/test.sh b/test/TEST-10-RAID/test.sh +index 3211030..b934da1 100755 +--- a/test/TEST-10-RAID/test.sh ++++ b/test/TEST-10-RAID/test.sh +@@ -32,7 +32,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -45,9 +45,9 @@ test_setup() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -66,7 +66,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mke2fs poweroff cp umount dd sync grep + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -107,7 +107,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown dd + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +diff --git a/test/TEST-11-LVM/test.sh b/test/TEST-11-LVM/test.sh +index a9cb8e2..482acd9 100755 +--- a/test/TEST-11-LVM/test.sh ++++ b/test/TEST-11-LVM/test.sh +@@ -33,7 +33,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -46,9 +46,9 @@ test_setup() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -67,7 +67,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mke2fs poweroff cp umount dd sync + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -106,7 +106,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown dd + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +diff --git a/test/TEST-12-RAID-DEG/test.sh b/test/TEST-12-RAID-DEG/test.sh +index 05080b2..bc15c89 100755 +--- a/test/TEST-12-RAID-DEG/test.sh ++++ b/test/TEST-12-RAID-DEG/test.sh +@@ -64,7 +64,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -77,9 +77,9 @@ test_setup() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -97,7 +97,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mke2fs poweroff cp umount dd grep sync + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -142,7 +142,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown dd + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +diff --git a/test/TEST-13-ENC-RAID-LVM/test.sh b/test/TEST-13-ENC-RAID-LVM/test.sh +index b985125..29eb601 100755 +--- a/test/TEST-13-ENC-RAID-LVM/test.sh ++++ b/test/TEST-13-ENC-RAID-LVM/test.sh +@@ -61,7 +61,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -74,9 +74,9 @@ test_setup() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -94,7 +94,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mke2fs poweroff cp umount grep dd sync + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -138,7 +138,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown dd + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +diff --git a/test/TEST-14-IMSM/test.sh b/test/TEST-14-IMSM/test.sh +index 3584a5d..d8c895e 100755 +--- a/test/TEST-14-IMSM/test.sh ++++ b/test/TEST-14-IMSM/test.sh +@@ -58,7 +58,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -72,9 +72,9 @@ test_setup() { + inst_multiple -o ${_terminfodir}/l/linux + inst_simple /etc/os-release + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -92,7 +92,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mke2fs poweroff cp umount grep dd sync realpath + inst_hook initqueue 01 ./create-root.sh + ) +@@ -136,7 +136,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +diff --git a/test/TEST-15-BTRFSRAID/test.sh b/test/TEST-15-BTRFSRAID/test.sh +index a8d73d3..192763a 100755 +--- a/test/TEST-15-BTRFSRAID/test.sh ++++ b/test/TEST-15-BTRFSRAID/test.sh +@@ -36,7 +36,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -49,9 +49,9 @@ test_setup() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -69,7 +69,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.btrfs poweroff cp umount dd sync + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -113,7 +113,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +diff --git a/test/TEST-16-DMSQUASH/test.sh b/test/TEST-16-DMSQUASH/test.sh +index 83189e5..1604bd0 100755 +--- a/test/TEST-16-DMSQUASH/test.sh ++++ b/test/TEST-16-DMSQUASH/test.sh +@@ -62,8 +62,8 @@ test_setup() { + "$DRACUT" -l --keep --tmpdir "$TESTDIR" \ + -m "test-root" \ + -i ./test-init.sh /sbin/init \ +- -i "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ +- -i "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" \ ++ -i "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" \ + --no-hostonly --no-hostonly-cmdline --nomdadmconf --nohardlink \ + -f "$TESTDIR"/initramfs.root "$KVERSION" || return 1 + mkdir -p "$TESTDIR"/overlay/source && mv "$TESTDIR"/dracut.*/initramfs/* "$TESTDIR"/overlay/source && rm -rf "$TESTDIR"/dracut.* +diff --git a/test/TEST-17-LVM-THIN/test.sh b/test/TEST-17-LVM-THIN/test.sh +index 54425ba..c5589d9 100755 +--- a/test/TEST-17-LVM-THIN/test.sh ++++ b/test/TEST-17-LVM-THIN/test.sh +@@ -31,7 +31,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -44,9 +44,9 @@ test_setup() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -65,7 +65,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mke2fs poweroff cp umount grep dmsetup dd sync + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -104,7 +104,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +diff --git a/test/TEST-20-NFS/test.sh b/test/TEST-20-NFS/test.sh +index b7ee214..5815dd8 100755 +--- a/test/TEST-20-NFS/test.sh ++++ b/test/TEST-20-NFS/test.sh +@@ -239,7 +239,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/server/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + + ( + cd "$initdir" || exit +@@ -300,7 +300,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/server/overlay/source/nfs/client + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + + ( + cd "$initdir" || exit +@@ -316,9 +316,9 @@ test_setup() { + fi + done + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -351,7 +351,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/server/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount sync dd + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -390,7 +390,7 @@ test_setup() { + export initdir="$TESTDIR"/overlay + mkdir -p "$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +@@ -408,7 +408,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir="$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + rm "$initdir"/etc/systemd/network/01-client.link + inst_simple ./server.link /etc/systemd/network/01-server.link + inst_hook pre-mount 99 ./wait-if-server.sh +diff --git a/test/TEST-30-ISCSI/test.sh b/test/TEST-30-ISCSI/test.sh +index 02151c9..555ecfa 100755 +--- a/test/TEST-30-ISCSI/test.sh ++++ b/test/TEST-30-ISCSI/test.sh +@@ -138,7 +138,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -153,9 +153,9 @@ test_setup() { + inst_multiple -o ${_terminfodir}/l/linux + inst_simple /etc/os-release + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -170,7 +170,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount setsid dd sync blockdev + inst_hook initqueue 01 ./create-client-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -215,7 +215,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p dev sys proc etc var/run tmp var/lib/dhcpd /etc/iscsi +@@ -261,7 +261,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount sync dd + inst_hook initqueue 01 ./create-server-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -300,7 +300,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +@@ -317,7 +317,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir="$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + rm "$initdir"/etc/systemd/network/01-client.link + inst_simple ./server.link /etc/systemd/network/01-server.link + inst_hook pre-mount 99 ./wait-if-server.sh +diff --git a/test/TEST-35-ISCSI-MULTI/test.sh b/test/TEST-35-ISCSI-MULTI/test.sh +index 672052b..908742c 100755 +--- a/test/TEST-35-ISCSI-MULTI/test.sh ++++ b/test/TEST-35-ISCSI-MULTI/test.sh +@@ -150,7 +150,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p -- dev sys proc etc var/run tmp +@@ -165,9 +165,9 @@ test_setup() { + inst_multiple -o ${_terminfodir}/l/linux + inst_simple /etc/os-release + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -182,7 +182,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount setsid dd sync blockdev + inst_hook initqueue 01 ./create-client-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -227,7 +227,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p dev sys proc etc var/run tmp var/lib/dhcpd /etc/iscsi +@@ -273,7 +273,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount sync dd + inst_hook initqueue 01 ./create-server-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -312,7 +312,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh +@@ -329,7 +329,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir="$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + rm "$initdir"/etc/systemd/network/01-client.link + inst_simple ./server.link /etc/systemd/network/01-server.link + inst_hook pre-mount 99 ./wait-if-server.sh +diff --git a/test/TEST-40-NBD/test.sh b/test/TEST-40-NBD/test.sh +index 9545a1a..f070ceb 100755 +--- a/test/TEST-40-NBD/test.sh ++++ b/test/TEST-40-NBD/test.sh +@@ -198,7 +198,7 @@ make_encrypted_root() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + mkdir -p "$initdir" + ( + cd "$initdir" || exit +@@ -212,9 +212,9 @@ make_encrypted_root() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -231,7 +231,7 @@ make_encrypted_root() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + ( + cd "$initdir" || exit + mkdir -p dev sys proc etc tmp var run root +@@ -280,7 +280,7 @@ make_client_root() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + mkdir -p "$initdir" + ( + cd "$initdir" || exit +@@ -293,9 +293,9 @@ make_client_root() { + done + inst_multiple -o ${_terminfodir}/l/linux + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -318,7 +318,7 @@ make_client_root() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount sync dd + inst_hook initqueue 01 ./create-client-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -361,7 +361,7 @@ make_server_root() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + mkdir -p "$initdir" + ( + cd "$initdir" || exit +@@ -417,7 +417,7 @@ EOF + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount sync dd sync + inst_hook initqueue 01 ./create-server-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -462,7 +462,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown dd + inst_hook shutdown-emergency 000 ./hard-off.sh + inst ./cryptroot-ask.sh /sbin/cryptroot-ask +@@ -489,7 +489,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir="$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + rm "$initdir"/etc/systemd/network/01-client.link + inst_simple ./server.link /etc/systemd/network/01-server.link + inst_hook pre-mount 99 ./wait-if-server.sh +diff --git a/test/TEST-50-MULTINIC/test.sh b/test/TEST-50-MULTINIC/test.sh +index f1e8ba1..183d6ea 100755 +--- a/test/TEST-50-MULTINIC/test.sh ++++ b/test/TEST-50-MULTINIC/test.sh +@@ -186,7 +186,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + + ( + cd "$initdir" || exit +@@ -247,7 +247,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay/source/nfs/client + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + + ( + cd "$initdir" || exit +@@ -263,9 +263,9 @@ test_setup() { + fi + done + +- inst_simple "${basedir}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" +- inst_simple "${basedir}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" +- inst_binary "${basedir}/dracut-util" "/usr/bin/dracut-util" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-lib.sh" "/lib/dracut-lib.sh" ++ inst_simple "${PKGLIBDIR}/modules.d/99base/dracut-dev-lib.sh" "/lib/dracut-dev-lib.sh" ++ inst_binary "${PKGLIBDIR}/dracut-util" "/usr/bin/dracut-util" + ln -s dracut-util "${initdir}/usr/bin/dracut-getarg" + ln -s dracut-util "${initdir}/usr/bin/dracut-getargs" + +@@ -298,7 +298,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount sync dd + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -337,14 +337,14 @@ test_setup() { + export initdir="$TESTDIR"/overlay + mkdir -p "$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook shutdown-emergency 000 ./hard-off.sh + inst_hook emergency 000 ./hard-off.sh + inst_simple ./client.link /etc/systemd/network/01-client.link + + inst_binary awk +- inst_hook pre-pivot 85 "$basedir/modules.d/45ifcfg/write-ifcfg.sh" ++ inst_hook pre-pivot 85 "$PKGLIBDIR/modules.d/45ifcfg/write-ifcfg.sh" + ) + # Make client's dracut image + "$DRACUT" -l -i "$TESTDIR"/overlay / \ +@@ -357,7 +357,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir="$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + rm "$initdir"/etc/systemd/network/01-client.link + inst_simple ./server.link /etc/systemd/network/01-server.link + inst_hook pre-mount 99 ./wait-if-server.sh +diff --git a/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh b/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh +index 427b4d2..8591943 100755 +--- a/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh ++++ b/test/TEST-60-BONDBRIDGEVLANIFCFG/test.sh +@@ -211,7 +211,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir=$TESTDIR/overlay/source + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + + ( + cd "$initdir" || exit +@@ -282,7 +282,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay/source/nfs/client + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sh shutdown poweroff stty cat ps ln ip \ + mount dmesg mkdir cp ping grep ls sort dd + for _terminfodir in /lib/terminfo /etc/terminfo /usr/share/terminfo; do +@@ -325,7 +325,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir=$TESTDIR/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple sfdisk mkfs.ext3 poweroff cp umount sync dd + inst_hook initqueue 01 ./create-root.sh + inst_hook initqueue/finished 01 ./finished-false.sh +@@ -355,7 +355,7 @@ test_setup() { + # shellcheck disable=SC2030 + export initdir="$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_multiple poweroff shutdown + inst_hook emergency 000 ./hard-off.sh + inst_simple ./client.link /etc/systemd/network/01-client.link +@@ -372,7 +372,7 @@ test_setup() { + # shellcheck disable=SC2031 + export initdir="$TESTDIR"/overlay + # shellcheck disable=SC1090 +- . "$basedir"/dracut-init.sh ++ . "$PKGLIBDIR"/dracut-init.sh + inst_simple ./server.link /etc/systemd/network/01-server.link + inst_hook pre-mount 99 ./wait-if-server.sh + ) +diff --git a/test/TEST-63-DRACUT-CPIO/test.sh b/test/TEST-63-DRACUT-CPIO/test.sh +index 163bab2..f9dff10 100755 +--- a/test/TEST-63-DRACUT-CPIO/test.sh ++++ b/test/TEST-63-DRACUT-CPIO/test.sh +@@ -7,7 +7,7 @@ TEST_DESCRIPTION="kernel cpio extraction tests for dracut-cpio" + # see dracut-cpio source for unit tests + + test_check() { +- if ! [[ -x $basedir/dracut-cpio ]]; then ++ if ! [[ -x "$PKGLIBDIR/dracut-cpio" ]]; then + echo "Test needs dracut-cpio... Skipping" + return 1 + fi +diff --git a/test/TEST-98-GETARG/test.sh b/test/TEST-98-GETARG/test.sh +index 012396b..74a1bec 100755 +--- a/test/TEST-98-GETARG/test.sh ++++ b/test/TEST-98-GETARG/test.sh +@@ -12,10 +12,10 @@ test_check() { + + test_setup() { + make -C "$basedir" dracut-util +- ln -sfnr "$basedir"/dracut-util "$TESTDIR"/dracut-getarg +- ln -sfnr "$basedir"/dracut-util "$TESTDIR"/dracut-getargs +- ln -sfnr "$basedir"/modules.d/99base/dracut-lib.sh "$TESTDIR"/dracut-lib.sh +- ln -sfnr "$basedir"/modules.d/99base/dracut-dev-lib.sh "$TESTDIR"/dracut-dev-lib.sh ++ ln -sfnr "$PKGLIBDIR"/dracut-util "$TESTDIR"/dracut-getarg ++ ln -sfnr "$PKGLIBDIR"/dracut-util "$TESTDIR"/dracut-getargs ++ ln -sfnr "$PKGLIBDIR"/modules.d/99base/dracut-lib.sh "$TESTDIR"/dracut-lib.sh ++ ln -sfnr "$PKGLIBDIR"/modules.d/99base/dracut-dev-lib.sh "$TESTDIR"/dracut-dev-lib.sh + return 0 + } + +diff --git a/test/test-functions b/test/test-functions +index e1b0618..43008fd 100644 +--- a/test/test-functions ++++ b/test/test-functions +@@ -13,6 +13,7 @@ export TESTDIR + if [[ -z $basedir ]]; then basedir="$(realpath ../..)"; fi + + DRACUT=${DRACUT-${basedir}/dracut.sh} ++PKGLIBDIR=${PKGLIBDIR-$basedir} + + command -v test_check &> /dev/null || test_check() { + : diff -Nru dracut-059/debian/patches/test-skip-test-98-if-dracut-util-is-not-available.patch dracut-059/debian/patches/test-skip-test-98-if-dracut-util-is-not-available.patch --- dracut-059/debian/patches/test-skip-test-98-if-dracut-util-is-not-available.patch 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/patches/test-skip-test-98-if-dracut-util-is-not-available.patch 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,34 @@ +From: Benjamin Drung +Date: Wed, 16 Aug 2023 13:56:41 +0200 +Subject: test: skip test 98 if dracut-util is not available + +Building `dracut-util` requires the source code to be present and +prevents running the test against the installed system. Check that +`dracut-util` and rely on the test environment to build `dracut-util` +beforehand. + +Forwarded: https://github.com/dracutdevs/dracut/pull/2484 +--- + test/TEST-98-GETARG/test.sh | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/test/TEST-98-GETARG/test.sh b/test/TEST-98-GETARG/test.sh +index 74a1bec..8f628a2 100755 +--- a/test/TEST-98-GETARG/test.sh ++++ b/test/TEST-98-GETARG/test.sh +@@ -7,11 +7,13 @@ + TEST_DESCRIPTION="dracut getarg command" + + test_check() { +- return 0 ++ if ! [[ -x "$PKGLIBDIR/dracut-util" ]]; then ++ echo "Test needs dracut-util... Skipping" ++ return 1 ++ fi + } + + test_setup() { +- make -C "$basedir" dracut-util + ln -sfnr "$PKGLIBDIR"/dracut-util "$TESTDIR"/dracut-getarg + ln -sfnr "$PKGLIBDIR"/dracut-util "$TESTDIR"/dracut-getargs + ln -sfnr "$PKGLIBDIR"/modules.d/99base/dracut-lib.sh "$TESTDIR"/dracut-lib.sh diff -Nru dracut-059/debian/rules dracut-059/debian/rules --- dracut-059/debian/rules 2023-08-15 20:49:10.000000000 +0000 +++ dracut-059/debian/rules 2023-08-22 14:34:06.000000000 +0000 @@ -1,6 +1,6 @@ #!/usr/bin/make -f -export DH_VERBOSE=1 +#export DH_VERBOSE=1 DPKG_EXPORT_BUILDTOOLS=1 -include /usr/share/dpkg/buildtools.mk diff -Nru dracut-059/debian/tests/control dracut-059/debian/tests/control --- dracut-059/debian/tests/control 2023-08-15 23:59:52.000000000 +0000 +++ dracut-059/debian/tests/control 2023-08-22 14:34:06.000000000 +0000 @@ -1,14 +1,72 @@ # Note: These tests need root on Ubuntu, because the kernel is only readable by root. See https://launchpad.net/bugs/759725 -Tests: upstream +# Skip following test cases that also fail upstream: +# * TEST-20-NFS: https://github.com/dracutdevs/dracut/issues/1901 +# * TEST-30-ISCSI: https://github.com/dracutdevs/dracut/issues/2497 +# * TEST-35-ISCSI-MULTI: https://github.com/dracutdevs/dracut/issues/2498 +# * TEST-50-MULTINIC: disabled in upstream CI since 2023-01-02 +# * TEST-60-BONDBRIDGEVLAN: https://github.com/dracutdevs/dracut/issues/2328 +# arm64, armhf, ppc64el, and s390x need upstream support: https://github.com/dracutdevs/dracut/issues/2493 +Architecture: amd64 +Test-Command: debian/tests/run-upstream-tests SKIP="16 20 30 35 40 50 60" Depends: btrfs-progs, busybox, + cryptsetup, dbus-broker, + dmraid, dracut-core, + fdisk, + gawk, kbd, - linux-image-amd64 | linux-image-arm64 | linux-image-armmp | linux-image-powerpc64 | linux-image-s390x | linux-image-generic, + linux-image-generic, + lvm2, make, + mdadm, mount, qemu-kvm, + systemd-boot-efi, systemd-sysv, util-linux -Restrictions: allow-stderr, needs-root, skip-not-installable +Restrictions: allow-stderr, needs-root +Features: test-name=upstream-dracut-core + +Architecture: amd64 +Test-Command: debian/tests/run-upstream-tests TESTS="16" +Depends: btrfs-progs, + busybox, + dbus-broker, + dracut-live, + fdisk, + kbd, + linux-image-generic, + make, + mount, + parted, + qemu-kvm, + squashfs-tools, + systemd-sysv, + util-linux +Restrictions: allow-stderr, needs-root +Features: test-name=upstream-dracut-live + +Architecture: amd64 +Test-Command: debian/tests/run-upstream-tests TESTS="40" +Depends: cryptsetup, + dracut-network, + gawk, + iproute2, + iputils-ping, + isc-dhcp-server, + linux-image-generic, + lvm2, + make, + mdadm, + mount, + nbd-client, + nbd-server, + procps, + qemu-kvm, + systemd-sysv, + util-linux, + vim +Restrictions: allow-stderr, needs-root +Features: test-name=upstream-dracut-network diff -Nru dracut-059/debian/tests/run-upstream-tests dracut-059/debian/tests/run-upstream-tests --- dracut-059/debian/tests/run-upstream-tests 1970-01-01 00:00:00.000000000 +0000 +++ dracut-059/debian/tests/run-upstream-tests 2023-08-22 14:34:06.000000000 +0000 @@ -0,0 +1,18 @@ +#!/bin/sh +set -eu + +if test -n "${AUTOPKGTEST_TMP-}"; then + export TMPDIR="${AUTOPKGTEST_TMP}" +fi + +# shellcheck disable=SC2012 +KVERSION=$(cd /lib/modules; ls -1 | tail -1) +export KVERSION +export DRACUT=dracut +export PKGLIBDIR=/usr/lib/dracut + +# Prapare out-of-tree test directory +TESTDIR="$(mktemp -d -t dracut-test.XXXXXXXXXX)" +cp -r test/* "$TESTDIR" + +make -C "$TESTDIR" V=1 check "$@" diff -Nru dracut-059/debian/tests/upstream dracut-059/debian/tests/upstream --- dracut-059/debian/tests/upstream 2023-08-15 23:53:20.000000000 +0000 +++ dracut-059/debian/tests/upstream 1970-01-01 00:00:00.000000000 +0000 @@ -1,19 +0,0 @@ -#!/bin/sh -set -eu - -if test -n "${AUTOPKGTEST_TMP-}"; then - export TMPDIR="${AUTOPKGTEST_TMP}" -fi - -# shellcheck disable=SC2012 -KVERSION=$(cd /lib/modules; ls -1 | tail -1) -export KVERSION -export DRACUT=dracut -export MODULES_D=/usr/lib/dracut/modules.d - -# Prapare out-of-tree test directory -TESTDIR="$(mktemp -d -t dracut-test.XXXXXXXXXX)" -cp -r test/* "$TESTDIR" - -# TODO: Check why those skipped test fail or hang -make -C "$TESTDIR" SKIP="10 11 12 13 14 15 16 17 20 30 35 40 50 60 62 63 98" V=1 check