Hello community, here is the log from the commit of package perl-Bootloader for openSUSE:Factory checked in at 2014-01-14 16:35:29 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/perl-Bootloader (Old) and /work/SRC/openSUSE:Factory/.perl-Bootloader.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-Bootloader" Changes: -------- --- /work/SRC/openSUSE:Factory/perl-Bootloader/perl-Bootloader.changes 2013-10-30 15:48:30.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.perl-Bootloader.new/perl-Bootloader.changes 2014-01-14 16:35:30.000000000 +0100 @@ -1,0 +2,7 @@ +Tue Jan 14 14:12:44 CET 2014 - snw...@suse.de + +- fix confusion between Tools::GetDeviceMapping() and Core::GetDeviceMapping() + (bnc #858268) +- 0.801 + +------------------------------------------------------------------- Old: ---- perl-Bootloader-0.800.tar.xz New: ---- perl-Bootloader-0.801.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ perl-Bootloader.spec ++++++ --- /var/tmp/diff_new_pack.bFDY2o/_old 2014-01-14 16:35:31.000000000 +0100 +++ /var/tmp/diff_new_pack.bFDY2o/_new 2014-01-14 16:35:31.000000000 +0100 @@ -1,7 +1,7 @@ # # spec file for package perl-Bootloader # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,7 +17,7 @@ Name: perl-Bootloader -Version: 0.800 +Version: 0.801 Release: 0 Requires: coreutils Requires: e2fsprogs ++++++ perl-Bootloader-0.800.tar.xz -> perl-Bootloader-0.801.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-Bootloader-0.800/perl-Bootloader.changes new/perl-Bootloader-0.801/perl-Bootloader.changes --- old/perl-Bootloader-0.800/perl-Bootloader.changes 2013-10-29 15:14:25.000000000 +0100 +++ new/perl-Bootloader-0.801/perl-Bootloader.changes 2014-01-14 14:13:16.000000000 +0100 @@ -1,4 +1,11 @@ ------------------------------------------------------------------- +Tue Jan 14 14:12:44 CET 2014 - snw...@suse.de + +- fix confusion between Tools::GetDeviceMapping() and Core::GetDeviceMapping() + (bnc #858268) +- 0.801 + +------------------------------------------------------------------- Tue Oct 29 15:13:22 CET 2013 - snw...@suse.de - add pbl-yaml: a command line interface to perl-Bootloader using YAML files diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-Bootloader-0.800/src/Core.pm new/perl-Bootloader-0.801/src/Core.pm --- old/perl-Bootloader-0.800/src/Core.pm 2013-10-02 14:22:43.000000000 +0200 +++ new/perl-Bootloader-0.801/src/Core.pm 2014-01-14 14:09:37.000000000 +0100 @@ -1692,35 +1692,22 @@ =cut # map<string,any> GetSettings () -sub GetSettings { - my $self = shift; +sub GetSettings +{ + my $self = shift; - my %ret = (); - foreach my $key ("global", "exports", "sections", "device_map") - { - if (defined ($self->{$key})) - { - $ret{$key} = $self->{$key}; - if ($key eq "sections") - { - foreach my $section (@{$ret{$key}}) - { - $self->milestone("store: $key:" . join( " - ", %{$section})); - } - } - elsif ($key eq "global" or $key eq "device_map") - { - $self->milestone("store: $key:" . join( ",", %{$ret{$key}})); - } - else - { - $self->milestone("store: $key:" . join( ",", $ret{$key})); - } - } - } - return \%ret; + my $ret = {}; + + for ("global", "exports", "sections", "device_map") { + $ret->{$_} = $self->{$_} if defined $self->{$_}; + } + + $self->milestone("ret =", $ret); + + return $ret; } + =item C<< $status = Bootloader::Core->SetSettings (\%settings); >> diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-Bootloader-0.800/src/Tools.pm new/perl-Bootloader-0.801/src/Tools.pm --- old/perl-Bootloader-0.800/src/Tools.pm 2013-10-18 11:26:52.000000000 +0200 +++ new/perl-Bootloader-0.801/src/Tools.pm 2014-01-14 14:06:37.000000000 +0100 @@ -311,17 +311,16 @@ } =item -C<< Bootloader::Tools::GetDeviceMapping (); >> +C<< Bootloader::Tools::GetUdevMapping (); >> Return reference to hash with symlinks to block devices. =cut # Notes: -# - replaces GetUdevMapping() # - no logging as map is passed to DefineUdevMapping() and logged there # - if issues with device mapper arise, check bnc #590637 -sub GetDeviceMapping +sub GetUdevMapping { my $list; @@ -341,71 +340,6 @@ } -sub GetUdevMapping { - my %mapping= (); - local $_; - - my @output = `find -P /dev -type b`; - chomp @output; - for my $dev (@output) { - next if ($dev =~ m:^/dev/mapper/:); - - my @output2 = `udevadm info -q all -n $dev 2>/dev/null`; - chomp @output2; - - if ($dev =~ m:^/dev/dm:) #workaround for incosistency of device mapper and udev - { - my $dmdev = undef; - my $dmpart = undef; - for my $line (@output2) - { - if ($line =~ m/DM_NAME=(.*)$/) - { - $dmdev = $1; - } - elsif ($line =~ m/DM_PART=(.*)$/) - { - $dmpart = $1; - } - } - - $lib_ref->error("UDEVMAPPING: dmdev $dev doesn't have defined DM_NAME in udev") unless defined $dmdev; - my $prevdev = $dev; - $dev = "/dev/mapper/$dmdev"; - # DM_NAME could contain also part in some case (bnc#590637) - $dev = $dev."_part$dmpart" if (defined $dmpart and $dev !~ /_part[0-9]+$/); - $mapping{$prevdev} = $dev; #maps also dm dev to device mapper - } #end of workaround - - for (@output2) { - $mapping{"/dev/$1"} = $dev if /S:\s(.*)$/; - } - } - -# while (my ($k,$v) = each (%mapping)){ -# $lib_ref->milestone("UDEV MAPPING: ".($k||"")." -> ".($v||"")); -# } - - if(!(keys %mapping)) { - $lib_ref->milestone("*** WARNING: No UDEV mapping! ***"); - $lib_ref->milestone("device tree:"); - for (`find -P /dev -type b -ls 2>/dev/null`) { - chomp; - $lib_ref->milestone(" $_"); - } - $lib_ref->milestone("udevinfo:"); - for (`udevadm info -e 2>&1`) { - chomp; - $lib_ref->milestone(" $_"); - } - } - - # $lib_ref->milestone("\%mapping =", \%mapping); - - return \%mapping; -} - - =item C<< $numDM = Bootloader::Tools::DMRaidAvailable (); >> @@ -758,7 +692,7 @@ { $lib_ref = shift // Bootloader::Library->new(); - my $um = GetDeviceMapping(); + my $um = GetUdevMapping(); my $mp = ReadMountPoints($um); my $part = ReadPartitions($um); my $md = ReadRAID1Arrays($um); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-Bootloader-0.800/version new/perl-Bootloader-0.801/version --- old/perl-Bootloader-0.800/version 2013-10-29 15:13:14.000000000 +0100 +++ new/perl-Bootloader-0.801/version 2014-01-14 14:12:28.000000000 +0100 @@ -1 +1 @@ -0.800 +0.801 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/perl-Bootloader-0.800/yaml-demo new/perl-Bootloader-0.801/yaml-demo --- old/perl-Bootloader-0.800/yaml-demo 2013-10-29 11:11:19.000000000 +0100 +++ new/perl-Bootloader-0.801/yaml-demo 1970-01-01 01:00:00.000000000 +0100 @@ -1,9 +0,0 @@ -#! /bin/sh - -rm -f foo x? - -./pbl-yaml --state foo 'x1=GetBootloader()' -./pbl-yaml --state foo 'SetLoaderType(x1a)' -./pbl-yaml --state foo 'x2=GetDeviceMapping()' -./pbl-yaml --state foo 'x3=ReadPartitions(x2)' -./pbl-yaml --state foo 'x4=DefinePartitions(x3)' -- To unsubscribe, e-mail: opensuse-commit+unsubscr...@opensuse.org For additional commands, e-mail: opensuse-commit+h...@opensuse.org