summaryrefslogtreecommitdiff
path: root/systems/texlive/tlnet/tlpkg/TeXLive
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-03-17 03:01:06 +0000
committerNorbert Preining <norbert@preining.info>2021-03-17 03:01:06 +0000
commitbb51b61cfc3fcb367f52d31948039a1468fbcf80 (patch)
tree2c9be8de7fa3daaf6064452aaecc8ed6a0f8d567 /systems/texlive/tlnet/tlpkg/TeXLive
parent4947a16af6c8e33f697a8da222db7f3ad027ba94 (diff)
CTAN sync 202103170301
Diffstat (limited to 'systems/texlive/tlnet/tlpkg/TeXLive')
-rw-r--r--systems/texlive/tlnet/tlpkg/TeXLive/TLPOBJ.pm18
-rw-r--r--systems/texlive/tlnet/tlpkg/TeXLive/TLPSRC.pm14
2 files changed, 21 insertions, 11 deletions
diff --git a/systems/texlive/tlnet/tlpkg/TeXLive/TLPOBJ.pm b/systems/texlive/tlnet/tlpkg/TeXLive/TLPOBJ.pm
index c7cd7983b5..f62d61591d 100644
--- a/systems/texlive/tlnet/tlpkg/TeXLive/TLPOBJ.pm
+++ b/systems/texlive/tlnet/tlpkg/TeXLive/TLPOBJ.pm
@@ -1,4 +1,4 @@
-# $Id: TLPOBJ.pm 54748 2020-04-15 03:02:45Z preining $
+# $Id: TLPOBJ.pm 58382 2021-03-15 04:20:36Z preining $
# TeXLive::TLPOBJ.pm - module for using tlpobj files
# Copyright 2007-2019 Norbert Preining
# This file is licensed under the GNU General Public License version 2
@@ -6,7 +6,7 @@
package TeXLive::TLPOBJ;
-my $svnrev = '$Revision: 54748 $';
+my $svnrev = '$Revision: 58382 $';
my $_modulerevision = ($svnrev =~ m/: ([0-9]+) /) ? $1 : "unknown";
sub module_revision { return $_modulerevision; }
@@ -851,13 +851,13 @@ sub update_from_catalogue {
$self->catalogue($entry->entry->{'id'});
}
if (defined($entry->license)) {
- $self->cataloguedata->{'license'} = $entry->license;
+ $self->cataloguedata->{'license'} ||= $entry->license;
}
if (defined($entry->version) && $entry->version ne "") {
- $self->cataloguedata->{'version'} = $entry->version;
+ $self->cataloguedata->{'version'} ||= $entry->version;
}
if (defined($entry->ctan) && $entry->ctan ne "") {
- $self->cataloguedata->{'ctan'} = $entry->ctan;
+ $self->cataloguedata->{'ctan'} ||= $entry->ctan;
}
# TODO TODO TODO
# we should rewrite the also fields to TeX Live package names ...
@@ -865,17 +865,17 @@ sub update_from_catalogue {
# warning, we expect that cataloguedata entries are strings,
# so stringify these lists
if (@{$entry->also}) {
- $self->cataloguedata->{'also'} = "@{$entry->also}";
+ $self->cataloguedata->{'also'} ||= "@{$entry->also}";
}
if (@{$entry->alias}) {
- $self->cataloguedata->{'alias'} = "@{$entry->alias}";
+ $self->cataloguedata->{'alias'} ||= "@{$entry->alias}";
}
if (@{$entry->topics}) {
- $self->cataloguedata->{'topics'} = "@{$entry->topics}";
+ $self->cataloguedata->{'topics'} ||= "@{$entry->topics}";
}
if (%{$entry->contact}) {
for my $k (keys %{$entry->contact}) {
- $self->cataloguedata->{"contact-$k"} = $entry->contact->{$k};
+ $self->cataloguedata->{"contact-$k"} ||= $entry->contact->{$k};
}
}
#if (defined($entry->texlive)) {
diff --git a/systems/texlive/tlnet/tlpkg/TeXLive/TLPSRC.pm b/systems/texlive/tlnet/tlpkg/TeXLive/TLPSRC.pm
index 497b8e8b39..86592aea22 100644
--- a/systems/texlive/tlnet/tlpkg/TeXLive/TLPSRC.pm
+++ b/systems/texlive/tlnet/tlpkg/TeXLive/TLPSRC.pm
@@ -1,4 +1,4 @@
-# $Id: TLPSRC.pm 54413 2020-03-20 06:49:12Z hironobu $
+# $Id: TLPSRC.pm 58382 2021-03-15 04:20:36Z preining $
# TeXLive::TLPSRC.pm - module for handling tlpsrc files
# Copyright 2007-2020 Norbert Preining
# This file is licensed under the GNU General Public License version 2
@@ -12,7 +12,7 @@ use TeXLive::TLUtils;
use TeXLive::TLPOBJ;
use TeXLive::TLTREE;
-my $svnrev = '$Revision: 54413 $';
+my $svnrev = '$Revision: 58382 $';
my $_modulerevision = ($svnrev =~ m/: ([0-9]+) /) ? $1 : "unknown";
sub module_revision { return $_modulerevision; }
@@ -222,6 +222,9 @@ sub from_file {
} elsif ($line =~ /^tlpsetvar\s+([-_a-zA-Z0-9]+)\s+(.*)$/) {
$tlpvars{$1} = $2;
+ } elsif ($line =~ /^catalogue-(.+)\s*(.*)$/o) {
+ $self->{'cataloguedata'}{$1} = $2 if defined $2;
+
} else {
die "$srcfile:$lineno: unknown tlpsrc directive, fix: $line\n";
}
@@ -335,6 +338,7 @@ sub make_tlpobj {
$tlp->shortdesc($self->{'shortdesc'}) if (defined($self->{'shortdesc'}));
$tlp->longdesc($self->{'longdesc'}) if (defined($self->{'longdesc'}));
$tlp->catalogue($self->{'catalogue'}) if (defined($self->{'catalogue'}));
+ $tlp->cataloguedata(%{$self->{'cataloguedata'}}) if (defined($self->{'cataloguedata'}));
$tlp->executes(@{$self->{'executes'}}) if (defined($self->{'executes'}));
$tlp->postactions(@{$self->{'postactions'}}) if (defined($self->{'postactions'}));
$tlp->depends(@{$self->{'depends'}}) if (defined($self->{'depends'}));
@@ -688,6 +692,12 @@ sub catalogue {
if (@_) { $self->{'catalogue'} = shift }
return $self->{'catalogue'};
}
+sub cataloguedata {
+ my $self = shift;
+ my %ct = @_;
+ if (@_) { $self->{'cataloguedata'} = \%ct }
+ return $self->{'cataloguedata'};
+}
sub srcpatterns {
my $self = shift;
if (@_) { @{ $self->{'srcpatterns'} } = @_ }