Author: frank
Date: 2006-03-28 15:50:23 +0000 (Tue, 28 Mar 2006)
New Revision: 1131
Modified:
tetex-base/trunk/debian/tpm2licenses-new.pl
Log:
make tpm2licenses script work with "individual_<license>.tpm" for single files
Modified: tetex-base/trunk/debian/tpm2licenses-new.pl
===================================================================
--- tetex-base/trunk/debian/tpm2licenses-new.pl 2006-03-28 15:13:43 UTC (rev
1130)
+++ tetex-base/trunk/debian/tpm2licenses-new.pl 2006-03-28 15:50:23 UTC (rev
1131)
@@ -218,7 +218,7 @@
$catname = "$tpmdir/${pkgcat}.xml";
if (! -r $catname) {
$licline .= "not-in-catalogue";
- unless ($nocatalogue) {
+ unless ($nocatalogue || $pkgcat =~ m/^individual.*/) {
print "$licline\n";
next;
};
@@ -226,9 +226,11 @@
# print STDERR "found ${pkgcat}.xml in $tpmdir\n";
};
}
- unless ($nocatalogue) { #don't try to parse the xml file if we don't
have a catalogue
+ my $ltype;
+ unless ($nocatalogue || $pkgcat =~ m/^individual.*/) {
+ #don't try to parse the xml file if we don't have a catalogue
my $cat = $parser->parsefile($catname);
- my ($version, $ltype, $lversion, $lchecked, $luser, $lfile);
+ my ($version, $lversion, $lchecked, $luser, $lfile);
$node = $cat->getElementsByTagName("version")->item(0);
if ($node) {
$version = $node->getAttribute("number");
@@ -257,6 +259,12 @@
$printfiles = '1';
}
}
+ if ( $pkgcat =~ m/^individual.*/ ) {
+ $ltype = $pkgcat;
+ $ltype =~ s/individual_(.*)/$1/;
+ $licline = "$pkgcat $ltype (verification data:::::header)";
+ $printfiles = '1';
+ };
$what eq "license" && print "$licline\n";
# we know the license, it makes sense to output the files
$what eq "files" && ($printfiles || $nocatalogue) &&
printFiles($LocalTPM,$licline);
_______________________________________________
Pkg-tetex-commits mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/pkg-tetex-commits