#100000# use perl rmtree instead of system rmtree or rm
This commit is contained in:
parent
ca1d51c5e1
commit
08df5b8ae3
1 changed files with 7 additions and 7 deletions
|
@ -5,9 +5,9 @@
|
||||||
#
|
#
|
||||||
# $RCSfile: build.pl,v $
|
# $RCSfile: build.pl,v $
|
||||||
#
|
#
|
||||||
# $Revision: 1.93 $
|
# $Revision: 1.94 $
|
||||||
#
|
#
|
||||||
# last change: $Author: vg $ $Date: 2003-10-24 10:06:10 $
|
# last change: $Author: vg $ $Date: 2003-10-28 11:09:56 $
|
||||||
#
|
#
|
||||||
# The Contents of this file are made available subject to the terms of
|
# The Contents of this file are made available subject to the terms of
|
||||||
# either of the following licenses
|
# either of the following licenses
|
||||||
|
@ -84,7 +84,7 @@
|
||||||
|
|
||||||
( $script_name = $0 ) =~ s/^.*\b(\w+)\.pl$/$1/;
|
( $script_name = $0 ) =~ s/^.*\b(\w+)\.pl$/$1/;
|
||||||
|
|
||||||
$id_str = ' $Revision: 1.93 $ ';
|
$id_str = ' $Revision: 1.94 $ ';
|
||||||
$id_str =~ /Revision:\s+(\S+)\s+\$/
|
$id_str =~ /Revision:\s+(\S+)\s+\$/
|
||||||
? ($script_rev = $1) : ($script_rev = "-");
|
? ($script_rev = $1) : ($script_rev = "-");
|
||||||
|
|
||||||
|
@ -97,15 +97,12 @@
|
||||||
#########################
|
#########################
|
||||||
|
|
||||||
$perl = "";
|
$perl = "";
|
||||||
$remove_commando = "";
|
|
||||||
if ( $^O eq 'MSWin32' ) {
|
if ( $^O eq 'MSWin32' ) {
|
||||||
$perl = "$ENV{COMSPEC} -c perl5";
|
$perl = "$ENV{COMSPEC} -c perl5";
|
||||||
$remove_commando = "rmdir /S /Q";
|
|
||||||
$nul = '> NULL';
|
$nul = '> NULL';
|
||||||
} else {
|
} else {
|
||||||
use Cwd 'chdir';
|
use Cwd 'chdir';
|
||||||
$perl = 'perl';
|
$perl = 'perl';
|
||||||
$remove_commando = 'rm -rf';
|
|
||||||
$nul = '> /dev/null';
|
$nul = '> /dev/null';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1372,7 +1369,10 @@ sub clear_module {
|
||||||
my $dir = &CorrectPath($StandDir.$Prj.'/'.$_);
|
my $dir = &CorrectPath($StandDir.$Prj.'/'.$_);
|
||||||
if ((!-d $dir.'/CVS') && &is_output_tree($dir)) {
|
if ((!-d $dir.'/CVS') && &is_output_tree($dir)) {
|
||||||
#print "I would delete $dir\n";
|
#print "I would delete $dir\n";
|
||||||
system ("$remove_commando $dir");
|
rmtree("$dir", 0, 1);
|
||||||
|
if (defined $SIG{__WARN__}) {
|
||||||
|
&print_error($SIG{__WARN__}) if ($SIG{__WARN__} ne '');
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue