Browse Source

Yard won't attempt to make /dev on compressed fs and ro if /dev is a symbolic

link, won't complain when there is an unitialized value in concatation in
Boot,  Ramdisk_size is always 4096 for mtdram, this setting isn't really
necessary, but is left anyways.
master
freesource 23 years ago
parent
commit
86f767a446
  1. 12
      BootRoot/BootRoot.pm
  2. 28
      BootRoot/Yard.pm

12
BootRoot/BootRoot.pm

@ -38,6 +38,10 @@ use File::Basename;
use File::Find;
use File::Path;
$SIG{__WARN__} =
sub { warn @_ unless $_[0] =~ /Subroutine [\w:]+ redefined/io
|| $_[0] =~ /Use of uninitialized value in concatenation/};
# If you want gBootRoot to do it's stuff somewhere else, change the
# value for $tmp1.
my $tmp1 = "/tmp"; # tmp should be default - Cristian
@ -1733,7 +1737,7 @@ sub uml_box {
#_______________________________________
# Submit Button
# Submit Button
my $submit_b = button_advanced(0,1,7,8,"Submit",$table_uml);
$tooltips->set_tip( $submit_b,
"Start uml kernel processes.",
@ -1922,10 +1926,8 @@ sub uml_box {
# ramdisk_size
if ( !$ramdisk_size ) {
$ramdisk_size = "ramdisk_size=$total_size";
if ( $ramdisk_size < 4096 ) {
$ramdisk_size = 4096;
}
#$ramdisk_size = "ramdisk_size=$total_size";
$ramdisk_size = "ramdisk_size=4096";
}
else {
undef $ramdisk_size;

28
BootRoot/Yard.pm

@ -1479,6 +1479,31 @@ sub create_expect_uml {
if ( $uml_exclusively ) {
if ( $fs_type eq "mkcramfs" || $fs_type eq "genromfs" ||
$fs_type eq "mkfs.jffs" || $fs_type eq "mkfs.jffs2") {
my $mount_pt = dirname($device);
# fail-safe /dev and /initrd directory check
if ( -f "$mount_pt/loopback/dev" ||
-l "$mount_pt/loopback/dev" ) {
warning("$mount_pt/loopback/dev isn't a directory " .
"not a file\n");
}
elsif ( !-d "$mount_pt/loopback/dev" ) {
errmk(sys("mkdir $mount_pt/loopback/dev"));
}
if ( -f "$mount_pt/loopback/initrd" ) {
warning("$mount_pt/loopback/initrd should be a directory" .
" not a file\n");
}
elsif ( !-d "$mount_pt/loopback/initrd" ) {
errmk(sys("mkdir $mount_pt/loopback/initrd"));
}
}
my $expect_program = "/usr/lib/bootroot/expect_uml";
my $version = "2.4";
my $ubd0 =
@ -1517,8 +1542,7 @@ sub create_expect_uml {
# Will just keep appending _cramfs .. leaving it to the
# user to realize this is happening, that way the user
# has control over the dd file.
## $fs_type eq "mkcramfs" ? ($device = $device . "_cramfs") :
## ($device = $device . "_romfs");
if ( $fs_type eq "mkcramfs" ) {
$device = $device . "_cramfs";

Loading…
Cancel
Save