# process all the files on the command line while ($_ = shift(ARGV)) { # handle RSP files by reading their content and putting that back on the command line if (/.rsp/ || /.RSP/) { open(RSP, $_); while () { chop; push(add, $_) } unshift(ARGV, @add); undef @add; close(RSP); next; } # provide status print $_ . ":\n"; if (/.CPP/ || /.cpp/) { print " skipping source file\n"; next; } # open the files for i/o $file = $_; $new = $file . ".new"; open(IN, $file); # process all the lines in the input file undef %symbol; undef %required; undef %inline; while () { chop; # strip comments s#//.*##; if (/#include\s+"/) { ($junk1, $header, $junk2) = split(/[" ]+/); $class = $header; $class =~ s#.*/##; $class =~ s#\.h##; if (!($class =~ /^First/)) { $symbol{$class} = $header; $required{$class} = "_"; $inline{$class} = "_"; } } elsif (/#include\s+