Removed also the pata mkinitcpio hook if install on hda
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 28 May 2008 15:40:25 +0000 (17:40 +0200)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 28 May 2008 15:40:25 +0000 (17:40 +0200)
src/install+setup/install/main.c

index 72af0ce59a620338904213e6ad67468b1197e245..4cd8ffd07353d151391819e019ca29f532b076d4 100644 (file)
@@ -501,9 +501,13 @@ int main(int argc, char *argv[])
                replace("/harddisk/boot/grub/grub.conf", "MOUNT", "ro");
        }
 
                replace("/harddisk/boot/grub/grub.conf", "MOUNT", "ro");
        }
 
-       /* Remove the ide hook if we install sda */
+       /* mkinitcpio has a problem if ide and pata are included */
        if ( scsi_disk==1 ) {
        if ( scsi_disk==1 ) {
-         replace("/harddisk/etc/mkinitcpio.conf", " ide ", " ");
+           /* Remove the ide hook if we install sda */
+           replace("/harddisk/etc/mkinitcpio.conf", " ide ", " ");
+       } else {
+           /* Remove the pata hook if we install hda */
+           replace("/harddisk/etc/mkinitcpio.conf", " pata ", " ");
        }
        /* Going to make our initrd... */
        snprintf(commandstring, STRING_SIZE, "/sbin/chroot /harddisk /sbin/mkinitcpio -g /boot/ipfirerd.img -k %s-ipfire", KERNEL_VERSION);
        }
        /* Going to make our initrd... */
        snprintf(commandstring, STRING_SIZE, "/sbin/chroot /harddisk /sbin/mkinitcpio -g /boot/ipfirerd.img -k %s-ipfire", KERNEL_VERSION);