]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
dracut.install: call dracut with --force
authorLukas Nykryn <lnykryn@redhat.com>
Thu, 25 Oct 2018 13:30:36 +0000 (15:30 +0200)
committerHarald Hoyer <harald@hoyer.xyz>
Thu, 25 Oct 2018 14:14:05 +0000 (16:14 +0200)
The kernel-install is called even if you run make install.
Since we don't call dracut with -f a second make install will fail
because initrd with same version is already there.
This makes kernel developers feel miserable.

https://bugzilla.redhat.com/show_bug.cgi?id=1642402

50-dracut.install
51-dracut-rescue.install

index 64e3549f2992890b81720bd4f0142c9c3a723a02..bbb73442b7e12ee4c82fc14616541a001d4d7503 100755 (executable)
@@ -49,7 +49,7 @@ case "$COMMAND" in
                 break
             fi
         done
-       dracut ${noimageifnotneeded:+--noimageifnotneeded} "$BOOT_DIR_ABS/$INITRD" "$KERNEL_VERSION"
+       dracut -f ${noimageifnotneeded:+--noimageifnotneeded} "$BOOT_DIR_ABS/$INITRD" "$KERNEL_VERSION"
         ret=$?
        ;;
     remove)
index 6ddafdb61408d8e0b580ce961eef5e00228dab55..ef8afac18899c21faf465b562a0f2981b30d8241 100755 (executable)
@@ -98,7 +98,7 @@ case "$COMMAND" in
         fi
 
         if [[ ! -f "$BOOT_DIR_ABS/$INITRD" ]]; then
-            dracut --no-hostonly -a "rescue" "$BOOT_DIR_ABS/$INITRD" "$KERNEL_VERSION"
+            dracut -f --no-hostonly -a "rescue" "$BOOT_DIR_ABS/$INITRD" "$KERNEL_VERSION"
             ((ret+=$?))
         fi