Show find-mod.pl syntax highlighted
#!/usr/bin/perl
if ($#ARGV < 1 or $#ARGV > 2) {
print "Usage: find-mod.pl deps-file module-name [path]\n";
exit(0);
}
$found = 0;
open(DEPS, $ARGV[0]) or die "Unable to open $ARGV[0]";
while (<DEPS>) {
chomp;
if (/:/) {
($head, $rest) = split /: /;
if ($head =~ $ARGV[1]) {
if ($found == 1) {
print "Found multiple matches to `$ARGV[1]'\n";
exit(1);
}
$found = 1;
@deps = split(/ /, $rest);
foreach $dep (@deps) {
print "$ARGV[2]/$dep\n";
}
}
}
}
if ($found == 1) {
exit(0);
}
exit(2);
See more files for this project here
CQual - A tool for adding type qualifiers to C
Project homepage:
http://sourceforge.net/projects/cqual
Programming language(s): C,Java,Shell Script
License: other
analyze
analyze-char
analyze-file
analyze-kernel
analyze-pldi02
analyze-taint
analyze_sleepy
analyze_together
collected_dependencies
find-mod.pl
modules_main.c
modules_main_sleepy.i
report
report-init
report-man
report-sendmail
report-thesis.pl
report.pl
report_modules_classified
strong-upd-errs