EditedFiles revision 7c478bd95313f5f23a4c958a745db2134aa03244
#
# Copyright 2004 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
#ident "%Z%%M% %I% %E% SMI"
#
# This script takes a file mapping CSV file as input (see flist_5.8.4_on10.csv
# for an example), a perl build directory and a ON workspace and reports files
# that are different in the build and ON directories. This show up any manual
# edits that have been made during the integration process, useful for
# identifying files that need to be preserved during future reintegrations.
# Run with the '-d' option to produce a diff file suitable for applying with
# gpatch.
use strict;
use warnings;
#
# Compare two files, return 0 for different, 1 for the same.
#
sub file_cmp
{
# Quick check - they must exist and be the same size.
# Open the files.
# Compare.
while (1) {
$len1 = -1;
$len2 = -2;
last;
}
}
}
#
# Main.
#
# Basic sanity checks.
# Work out perl version.
my ($r, $v, $s);
}
# Work out directory locations.
# Read in the mapping file.
my %file;
;
}
my @field;
m{["']([^"'\\]*(?:\\.[^"'\\]*)*)["'],?|([^,]+),?|,}g;
push(@field, undef) if (substr($line, -1, 1) eq ',');
my $p = shift(@field);
my $f = shift(@field);
# We just want the s10 column.
}
close($fh);
# Process the mappings.
foreach my $p (sort(keys(%file))) {
foreach my $f (sort(keys(%{$file{$p}}))) {
my $d = $file{$p}{$f};
# If it has gone into the distrib directory.
if ($d eq 'distrib') {
# If it has gone into the arch directory.
} elsif ($d eq 'arch') {
# If it is to be copied forwards from the last version.
} elsif ($d eq 'fwd') {
}
# Short forms of the filenames.
if ($src) {
$ssrc =~ s{[^/]+/\.\./}{}g;
}
if ($dst) {
$sdst =~ s{[^/]+/\.\./}{}g;
}
# New files.
if (! $opt_d) {
}
# Modified files.
if ($opt_d) {
"-e 's!$dst!$sdst!g'");
} else {
}
}
}
}