summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2008-12-09 22:40:22 +0000
committerKarl Berry <karl@freefriends.org>2008-12-09 22:40:22 +0000
commita425057480a2ab8ddea0896d22fff152390cda3d (patch)
treecd70326a68b83f77aeafc65153a5d229d5d1ba0e /Master
parenta04cd5203028d7814866e4107e11078359c55953 (diff)
--no-ctan fix from jim hefferon
git-svn-id: svn://tug.org/texlive/trunk@11569 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rwxr-xr-xMaster/tlpkg/bin/check-depend-consistency32
-rwxr-xr-xMaster/tlpkg/bin/ctan2tl11
2 files changed, 28 insertions, 15 deletions
diff --git a/Master/tlpkg/bin/check-depend-consistency b/Master/tlpkg/bin/check-depend-consistency
index 2859a3118d2..988bbbd6713 100755
--- a/Master/tlpkg/bin/check-depend-consistency
+++ b/Master/tlpkg/bin/check-depend-consistency
@@ -4,7 +4,7 @@
# This file is licensed under the GNU General Public License version 2
# or any later version.
#
-# Check that all package are contained in some collection.
+# Check that all packages are contained in some collection.
BEGIN {
$^W = 1;
@@ -27,7 +27,6 @@ use File::Path;
my $help = 0;
TeXLive::TLUtils::process_logging_options();
-
GetOptions("help|?" => \$help) or pod2usage(1);
pod2usage(-exitstatus => 0, -verbose => 2) if $help;
@@ -36,19 +35,26 @@ exit (&main ());
sub main
{
# get the db.
- chomp (my $Master = `cd $mydir/../.. && pwd`); # xx TLPDB should default
- my $tlpdb = TeXLive::TLPDB->new ("root" => "$Master");
- die("Cannot find tlpdb in $Master!\n") unless defined($tlpdb);
+ chomp (my $Master = `cd $mydir/../.. && pwd`);
+ my $tlpdb = TeXLive::TLPDB->new("root" => $Master);
+ die "$0: Cannot find tlpdb in $Master.\n" unless defined($tlpdb);
+
my %presentpkg;
- my %wrongdep;
for my $pkg ($tlpdb->list_packages) {
$presentpkg{$pkg} = 1;
}
+
+ # list of collections.
+ my @colls = $tlpdb->collections;
+ my @coll_deps = $tlpdb->expand_dependencies("-no-collections",$tlpdb,@colls);
+
+
+ my %wrongdep;
+ my %nodep;
for my $pkg ($tlpdb->list_packages) {
# do not check any package starting with 00texlive
next if $pkg =~ m/^00texlive/;
- #next if ($pkg =~ m/^00texlive\.config$/);
- #next if ($pkg =~ m/^00texlive-installation\.config$/);
+
for my $d ($tlpdb->get_package($pkg)->depends) {
next if ($d =~ m/\.ARCH$/);
if (!defined($presentpkg{$d})) {
@@ -56,6 +62,7 @@ sub main
}
}
}
+
if (keys %wrongdep) {
print "DEPENDS WITHOUT PACKAGES:\n";
for my $d (keys %wrongdep) {
@@ -65,12 +72,11 @@ sub main
}
-
__END__
=head1 NAME
-check-depend-consistency - check that all depends actually exist as packages
+check-depend-consistency - check that all dependencies exist as packages
=head1 SYNOPSIS
@@ -84,8 +90,10 @@ function in L<TeXLive::TLUtils> for details.
=head1 DESCRIPTION
-Check consistency of C<depend> statements in all TeX Live packages,
-including collections and schemes.
+Check that all C<depend> statements in all TeX Live packages
+(collections, schemes, and normal packages) refer to existing packages,
+according to the tlpdb that is within the hierarchy from which this
+script is invoked.
=head1 AUTHORS AND COPYRIGHT
diff --git a/Master/tlpkg/bin/ctan2tl b/Master/tlpkg/bin/ctan2tl
index 6ac192017ed..66125006e8a 100755
--- a/Master/tlpkg/bin/ctan2tl
+++ b/Master/tlpkg/bin/ctan2tl
@@ -55,7 +55,12 @@ if test -z "$pkg"; then
exit 1
fi
-ctan_dir1=`tlpkginfo --prepare $pkg`
+if $copy_from_ctan; then
+ ctan_dir1=`tlpkginfo --prepare $pkg`
+else
+ ctan_dir1="$pkg"
+fi
+
if test -z "$ctan_dir1"; then
echo "$0: can't find CTAN directory for $pkg." >&2
exit 1
@@ -91,13 +96,13 @@ else
cp -pr $ctan_dir1/. $pkg
fi
-fi # end of copying from CTAN.
-
# clean up the tmpdir possibly created by 'tlpkginfo --prepare'
ctan_root=`tlpkginfo --ctan-root`
if ! echo "$ctan_dir1" | egrep "^$ctan_root" >/dev/null; then
rm -rf $ctan_dir1
fi
+fi # end of copying from CTAN.
+
#
printf "\n$0: calling ctan2tds\n"