You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by wr...@apache.org on 2007/08/17 22:51:16 UTC
svn commit: r567138 - /apr/apr/trunk/build/fixwin32mak.pl
Author: wrowe
Date: Fri Aug 17 13:51:15 2007
New Revision: 567138
URL: http://svn.apache.org/viewvc?view=rev&rev=567138
Log:
Tabs? **tabs???** Mea culpa.
Modified:
apr/apr/trunk/build/fixwin32mak.pl
Modified: apr/apr/trunk/build/fixwin32mak.pl
URL: http://svn.apache.org/viewvc/apr/apr/trunk/build/fixwin32mak.pl?view=diff&rev=567138&r1=567137&r2=567138
==============================================================================
--- apr/apr/trunk/build/fixwin32mak.pl (original)
+++ apr/apr/trunk/build/fixwin32mak.pl Fri Aug 17 13:51:15 2007
@@ -22,60 +22,60 @@
sub fixcwd {
if (m|.mak$|) {
$thisroot = $File::Find::dir;
- $thisroot =~ s|^./(.*)$|$1|;
- $thisroot =~ s|/|\\\\|g;
+ $thisroot =~ s|^./(.*)$|$1|;
+ $thisroot =~ s|/|\\\\|g;
$thisroot = $root . "\\\\" . $thisroot;
$thisaltroot = $altroot . "\\\\" . $thisroot;
$oname = $_;
- $tname = '.#' . $_;
- $verchg = 0;
- $srcfl = new IO::File $_, "r" || die;
- $dstfl = new IO::File $tname, "w" || die;
- while ($src = <$srcfl>) {
- if ($src =~ m|^\s*($root[^\"]*)\".*$|) {
- $orig = $thisroot;
+ $tname = '.#' . $_;
+ $verchg = 0;
+ $srcfl = new IO::File $_, "r" || die;
+ $dstfl = new IO::File $tname, "w" || die;
+ while ($src = <$srcfl>) {
+ if ($src =~ m|^\s*($root[^\"]*)\".*$|) {
+ $orig = $thisroot;
} elsif ($src =~ m|^\s*($altroot[^\"]*)\".*$|) {
- $orig = $thisaltroot;
+ $orig = $thisaltroot;
}
if (defined($orig)) {
$repl = "cd \".";
while (!($src =~ s|$orig|$repl|)) {
- if (!($orig =~ s|^(.*)\\\\[^\\]+$|$1|)) {
+ if (!($orig =~ s|^(.*)\\\\[^\\]+$|$1|)) {
break;
}
- $repl .= "\\..";
- }
-print "Replaced " . $orig . " with " . $repl . "\n";
- $verchg = -1;
+ $repl .= "\\..";
+ }
+ print "Replaced " . $orig . " with " . $repl . "\n";
+ $verchg = -1;
undef $orig;
- }
+ }
print $dstfl $src;
- }
- undef $srcfl;
- undef $dstfl;
- if ($verchg) {
- unlink $oname || die;
- rename $tname, $oname || die;
- print "Corrected absolute paths within " . $oname . " in " . $File::Find::dir . "\n";
- }
- else {
- unlink $tname;
- }
+ }
+ undef $srcfl;
+ undef $dstfl;
+ if ($verchg) {
+ unlink $oname || die;
+ rename $tname, $oname || die;
+ print "Corrected absolute paths within " . $oname . " in " . $File::Find::dir . "\n";
+ }
+ else {
+ unlink $tname;
+ }
$dname = $oname;
$dname =~ s/.mak$/.dsp/;
- @dstat = stat($dname);
+ @dstat = stat($dname);
@ostat = stat($oname);
if ($ostat[9] && $dstat[9] && ($ostat[9] != $dstat[9])) {
@onames = ($oname);
utime $dstat[9], $dstat[9], @onames;
- print "Touched datestamp for " . $oname . " in " . $File::Find::dir . "\n";
+ print "Touched datestamp for " . $oname . " in " . $File::Find::dir . "\n";
}
$oname =~ s/.mak$/.dep/;
@ostat = stat($oname);
if ($ostat[9] && $dstat[9] && ($ostat[9] != $dstat[9])) {
@onames = ($oname);
utime $dstat[9], $dstat[9], @onames;
- print "Touched datestamp for " . $oname . " in " . $File::Find::dir . "\n";
+ print "Touched datestamp for " . $oname . " in " . $File::Find::dir . "\n";
}
}
}