aboutsummaryrefslogtreecommitdiff
path: root/Tools/make_index
diff options
context:
space:
mode:
authorKris Kennaway <kris@FreeBSD.org>2002-08-31 05:46:25 +0000
committerKris Kennaway <kris@FreeBSD.org>2002-08-31 05:46:25 +0000
commit8ed01ab91cf51d5eae0adbcf933f137d186a0b20 (patch)
tree631a126b7fc3e574265b02fed2b3ef360a239278 /Tools/make_index
parent247f9bcafd0abec760da66c18caa1361792cd105 (diff)
downloadports-8ed01ab91cf51d5eae0adbcf933f137d186a0b20.tar.gz
ports-8ed01ab91cf51d5eae0adbcf933f137d186a0b20.zip
Notes
Diffstat (limited to 'Tools/make_index')
-rw-r--r--Tools/make_index19
1 files changed, 12 insertions, 7 deletions
diff --git a/Tools/make_index b/Tools/make_index
index f2ba2895aa8f..3708e94928db 100644
--- a/Tools/make_index
+++ b/Tools/make_index
@@ -114,11 +114,16 @@ foreach $name (keys %index) {
# With all that done we're finally ready to write out the new
# INDEX file one port at a time.
foreach $name (@names) {
- my $pkg = $index{$name};
- recurse($pkg);
- print "$pkg->{text}|";
- print join(' ', sort(@{$pkg->{bdep}})) if @{$pkg->{bdep}};
- print "|";
- print join(' ', sort(@{$pkg->{rdep}})) if @{$pkg->{rdep}};
- print "|$pkg->{rest}\n";
+ my $pkg = $index{$name};
+ if (exists $pkg->{'PRINTED'}) {
+ print STDERR "Warning: Duplicate INDEX entry: $name\n";
+ } else {
+ recurse($pkg);
+ print "$pkg->{text}|";
+ print join(' ', sort(@{$pkg->{bdep}})) if @{$pkg->{bdep}};
+ print "|";
+ print join(' ', sort(@{$pkg->{rdep}})) if @{$pkg->{rdep}};
+ print "|$pkg->{rest}\n";
+ ++$pkg->{'PRINTED'};
+ }
}