Browse Source

This adds alternative device choice to initrd, fdformat is kind of a solution since

mke2fs has gotten so chosy, but it isn't geometrically perfect .. expect 0x04
from lilo.
master
freesource 23 years ago
parent
commit
0529b9a78f
  1. 7
      gbootroot

7
gbootroot

@ -2449,7 +2449,7 @@ sub lilo_put_it_together {
return if err(sys("mkdir $mnt/{boot,dev}")) == 2; return if err(sys("mkdir $mnt/{boot,dev}")) == 2;
return if err(sys("cp -a /dev/{null,fd?,hda1} $mnt/dev")) == 2; return if err(sys("cp -a /dev/{null,fd?,hda1} $mnt/dev")) == 2;
# Hopefully, this works, but have never tested it # Hopefully, this works, but have never tested it -- o.k I did
if ($device !~ m,/dev/fd\d{1}$,) { if ($device !~ m,/dev/fd\d{1}$,) {
return if err(sys("cp -a $device $mnt/dev")) == 2; return if err(sys("cp -a $device $mnt/dev")) == 2;
} }
@ -2877,6 +2877,11 @@ sub initrd {
return if errmk(sys("mkdir $tmp/initrd_mnt/usr/lib")) == 2; return if errmk(sys("mkdir $tmp/initrd_mnt/usr/lib")) == 2;
pb($I,6); pb($I,6);
# Hopefully, this works, but have never tested it - o.k I did
if ($device !~ m,/dev/fd\d{1}$,) {
return if err(sys("cp -a $device $mnt/dev")) == 2;
}
return if errcp( return if errcp(
sys("cp -a /dev/{console,null,ram0,ram1,tty0} $tmp/initrd_mnt/dev")) == 2; sys("cp -a /dev/{console,null,ram0,ram1,tty0} $tmp/initrd_mnt/dev")) == 2;
return if errcp(sys("cp -a $device $tmp/initrd_mnt/dev")) == 2; return if errcp(sys("cp -a $device $tmp/initrd_mnt/dev")) == 2;

Loading…
Cancel
Save