Pass subjects instead of subject filenames to info/mktop.pl

mktop.pl doesn't actually use the files, so this is simpler and
clearer.
This commit is contained in:
Markus Armbruster 2013-04-27 17:03:34 +02:00
parent 02a18de4d4
commit a2338a1db4
2 changed files with 5 additions and 14 deletions

View file

@ -331,8 +331,8 @@ subjects.mk: info/findsubj.pl $(tsrc)
$(tsubj): info/mksubj.pl $(tsubj): info/mksubj.pl
perl $(srcdir)/info/mksubj.pl $@ $(filter %.t, $^) perl $(srcdir)/info/mksubj.pl $@ $(filter %.t, $^)
$(ttop): $(tsubj) $(ttop): info/mktop.pl
perl $(srcdir)/info/mktop.pl $@ $(filter %.t, $^) $(call quiet-command,perl $(srcdir)/info/mktop.pl $@ $(subjects),GEN $@)
info.nr/all: $(filter-out info.nr/all, $(info.nr)) info.nr/all: $(filter-out info.nr/all, $(info.nr))
>$@ >$@

View file

@ -29,22 +29,13 @@
# #
# Known contributors to this file: # Known contributors to this file:
# Ken Stevens (when it was still info.pl) # Ken Stevens (when it was still info.pl)
# Markus Armbruster, 2006 # Markus Armbruster, 2006-2013
# #
# Usage: mktop.pl OUTFILE SUBJECT-INDEX-FILE... # Usage: mktop.pl OUTFILE SUBJECT...
# The SUBJECT-INDEX-FILE... contain all the subject indexes. Derive
# the subjects from the file names, write the index to OUTFILE. Only
# the file names are used, the files aren't accessed.
my $out = shift @ARGV; my $out = shift @ARGV;
my @subject = (); my @subject = sort @ARGV;
for (@ARGV) {
/([^\/]*)\.t$/
or die "Strange subject file name";
push @subject, $1;
}
@subject = sort @subject;
open(TOP, ">$out") open(TOP, ">$out")
or die "Can't open $out: $!"; or die "Can't open $out: $!";