You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by wr...@locus.apache.org on 2000/05/26 06:51:08 UTC
cvs commit: apache-2.0/src/helpers dsp5tocvs.pl
wrowe 00/05/25 21:51:08
Modified: src/helpers dsp5tocvs.pl
Log:
Whoops... the two converters were to be non-destructive, and should be
allowed to run multiple times in a row without harm. This fixes a
snafu that created multiple #PROP lines when invoked repeatedly.
Revision Changes Path
1.3 +7 -3 apache-2.0/src/helpers/dsp5tocvs.pl
Index: dsp5tocvs.pl
===================================================================
RCS file: /home/cvs/apache-2.0/src/helpers/dsp5tocvs.pl,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- dsp5tocvs.pl 2000/05/26 04:22:14 1.2
+++ dsp5tocvs.pl 2000/05/26 04:51:07 1.3
@@ -8,11 +8,14 @@
if (m|.dsp$|) {
$tname = '.#' . $_;
+ $verchg = 0;
print "Convert VC6 project " . $_ . " to VC5 in " . $File::Find::dir . "\n";
$srcfl = new IO::File $_, "r" || die;
$dstfl = new IO::File $tname, "w" || die;
while ($src = <$srcfl>) {
- $src =~ s|Format Version 5\.00|Format Version 6\.00|;
+ if ($src =~ s|Format Version 5\.00|Format Version 6\.00|) {
+ $verchg = -1;
+ }
$src =~ s|^(# ADD CPP .*)/Zi (.*)|$1/ZI $2|;
$src =~ s|^(# ADD BASE CPP .*)/Zi (.*)|$1/ZI $2|;
if ($src =~ s|^(!MESSAGE .*)\\\n|$1|) {
@@ -20,8 +23,9 @@
$src = $src . $cont;
}
print $dstfl $src;
- if ($src =~ m|^# Begin Project|) {
- print $dstfl "# PROP AllowPerConfigDependencies 0\n"; }
+ if ($verchg && $src =~ m|^# Begin Project|) {
+ print $dstfl "# PROP AllowPerConfigDependencies 0\n";
+ }
}
undef $srcfl;
undef $dstfl;