From 52521fd80b8b5ce58eb4211c6f8a202dee218eed Mon Sep 17 00:00:00 2001 From: Oliver Tappe Date: Thu, 21 Jun 2007 18:00:00 +0000 Subject: * fixed problem with some lame shells not supporting {a,b,c} constructs, reported by Dirk git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1185 95ad53e4-c205-0410-b2fa-d234c58c8868 --- installer/OpenSLX/OSSetup/Distro/SUSE_10_1.pm | 5 ++-- .../OpenSLX/OSSetup/Distro/SUSE_10_1_x86_64.pm | 5 ++-- installer/OpenSLX/OSSetup/Distro/SUSE_10_2.pm | 27 ++++++++++------------ .../OpenSLX/OSSetup/Distro/SUSE_10_2_x86_64.pm | 5 ++-- 4 files changed, 18 insertions(+), 24 deletions(-) (limited to 'installer') diff --git a/installer/OpenSLX/OSSetup/Distro/SUSE_10_1.pm b/installer/OpenSLX/OSSetup/Distro/SUSE_10_1.pm index 42e54d4b..25ae41bb 100644 --- a/installer/OpenSLX/OSSetup/Distro/SUSE_10_1.pm +++ b/installer/OpenSLX/OSSetup/Distro/SUSE_10_1.pm @@ -50,9 +50,8 @@ sub fixPrerequiredFiles my $self = shift; my $stage1cDir = shift; - if (system("chown root: $stage1cDir/etc/{group,passwd,shadow}")) { - die _tr("unable to fix pre-required files (%s)", $!); - } + chown(0, 0, "$stage1cDir/etc/group", "$stage1cDir/etc/passwd", + "$stage1cDir/etc/shadow"); } sub updateDistroConfig diff --git a/installer/OpenSLX/OSSetup/Distro/SUSE_10_1_x86_64.pm b/installer/OpenSLX/OSSetup/Distro/SUSE_10_1_x86_64.pm index 5d40e0b0..983834f8 100644 --- a/installer/OpenSLX/OSSetup/Distro/SUSE_10_1_x86_64.pm +++ b/installer/OpenSLX/OSSetup/Distro/SUSE_10_1_x86_64.pm @@ -50,9 +50,8 @@ sub fixPrerequiredFiles my $self = shift; my $stage1cDir = shift; - if (system("chown root: $stage1cDir/etc/{group,passwd,shadow}")) { - die _tr("unable to fix pre-required files (%s)", $!); - } + chown(0, 0, "$stage1cDir/etc/group", "$stage1cDir/etc/passwd", + "$stage1cDir/etc/shadow"); } sub updateDistroConfig diff --git a/installer/OpenSLX/OSSetup/Distro/SUSE_10_2.pm b/installer/OpenSLX/OSSetup/Distro/SUSE_10_2.pm index f003ba4e..24508911 100644 --- a/installer/OpenSLX/OSSetup/Distro/SUSE_10_2.pm +++ b/installer/OpenSLX/OSSetup/Distro/SUSE_10_2.pm @@ -15,7 +15,7 @@ package OpenSLX::OSSetup::Distro::SUSE_10_2; use vars qw($VERSION); use base qw(OpenSLX::OSSetup::Distro::Base); -$VERSION = 1.01; # API-version . implementation-version +$VERSION = 1.01; # API-version . implementation-version use strict; use Carp; @@ -28,31 +28,28 @@ use OpenSLX::OSSetup::Distro::Base 1; sub new { my $class = shift; - my $self = { - 'base-name' => 'suse-10.2', - }; + my $self = {'base-name' => 'suse-10.2',}; return bless $self, $class; } sub initialize { - my $self = shift; + my $self = shift; my $engine = shift; $self->SUPER::initialize($engine); - $self->{'packager-type'} = 'rpm'; + $self->{'packager-type'} = 'rpm'; $self->{'meta-packager-type'} = $ENV{SLX_META_PACKAGER} || 'smart'; - $ENV{YAST_IS_RUNNING} = "instsys"; + $ENV{YAST_IS_RUNNING} = "instsys"; } sub fixPrerequiredFiles { - my $self = shift; + my $self = shift; my $stage1cDir = shift; - if (system("chown root: $stage1cDir/etc/{group,passwd,shadow}")) { - die _tr("unable to fix pre-required files (%s)", $!); - } + chown(0, 0, "$stage1cDir/etc/group", "$stage1cDir/etc/passwd", + "$stage1cDir/etc/shadow"); } sub updateDistroConfig @@ -83,7 +80,7 @@ sub initDistroInfo ftp://ftp.estpak.ee/pub/suse/opensuse/distribution/10.2/repo/oss ftp://ftp.jaist.ac.jp/pub/Linux/openSUSE/distribution/10.2/repo/oss ", - 'name' => 'openSUSE 10.2', + 'name' => 'openSUSE 10.2', 'repo-subdir' => 'suse', }, 'base_non-oss' => { @@ -95,14 +92,14 @@ sub initDistroInfo ftp://ftp.estpak.ee/pub/suse/opensuse/distribution/10.2/repo/non-oss ftp://ftp.jaist.ac.jp/pub/Linux/openSUSE/distribution/10.2/repo/non-oss ", - 'name' => 'openSUSE 10.2 non-OSS', + 'name' => 'openSUSE 10.2 non-OSS', 'repo-subdir' => 'suse', }, 'base_update' => { 'urls' => " ftp://ftp.gwdg.de/pub/suse/update/10.2 ", - 'name' => 'openSUSE 10.2 updates', + 'name' => 'openSUSE 10.2 updates', 'repo-subdir' => '', }, }; @@ -963,4 +960,4 @@ sub initDistroInfo }; } -1; \ No newline at end of file +1; diff --git a/installer/OpenSLX/OSSetup/Distro/SUSE_10_2_x86_64.pm b/installer/OpenSLX/OSSetup/Distro/SUSE_10_2_x86_64.pm index 6729e017..30268635 100644 --- a/installer/OpenSLX/OSSetup/Distro/SUSE_10_2_x86_64.pm +++ b/installer/OpenSLX/OSSetup/Distro/SUSE_10_2_x86_64.pm @@ -50,9 +50,8 @@ sub fixPrerequiredFiles my $self = shift; my $stage1cDir = shift; - if (system("chown root: $stage1cDir/etc/{group,passwd,shadow}")) { - die _tr("unable to fix pre-required files (%s)", $!); - } + chown(0, 0, "$stage1cDir/etc/group", "$stage1cDir/etc/passwd", + "$stage1cDir/etc/shadow"); } sub updateDistroConfig -- cgit v1.2.3-55-g7522