diff options
Diffstat (limited to 'Master')
-rwxr-xr-x | Master/tlpkg/bin/tl-update-tlpdb | 29 | ||||
-rw-r--r-- | Master/tlpkg/doc/repository-setup.txt | 40 |
2 files changed, 51 insertions, 18 deletions
diff --git a/Master/tlpkg/bin/tl-update-tlpdb b/Master/tlpkg/bin/tl-update-tlpdb index 0f08c73ef52..ba83d0ca7e6 100755 --- a/Master/tlpkg/bin/tl-update-tlpdb +++ b/Master/tlpkg/bin/tl-update-tlpdb @@ -2,7 +2,7 @@ # $Id$ # convert a set of tlpsrc files (given as arguments) into tlpdb # -# Copyright 2007, 2008, 2009 Norbert Preining +# Copyright 2007, 2008, 2009, 2010 Norbert Preining # This file is licensed under the GNU General Public License version 2 # or any later version. @@ -37,6 +37,7 @@ my $opt_output; my $opt_save_anyway = 0; my $opt_tlpsrc_from_cmdline = 0; my $opt_w32warning; +my $opt_tlpdb_options_from_tlpsrc = 0; TeXLive::TLUtils::process_logging_options(); GetOptions( @@ -52,6 +53,7 @@ GetOptions( "save-anyway!" => \$opt_save_anyway, "tlpsrc-from-cmdline" => \$opt_tlpsrc_from_cmdline, "with-w32-pattern-warning" => \$opt_w32warning, + "tlpdb-options-from-tlpsrc" => \$opt_tlpdb_options_from_tlpsrc, "help|?" => \$help) or pod2usage(1); pod2usage(-exitstatus => 0, -verbose => 2) if $help; @@ -312,13 +314,18 @@ sub create_tlpdb $found_texlive_installation = 1; } if ($tlp->name eq "00texlive.config") { - my @bar = $tlp->depends; - for my $k (sort keys %TeXLive::TLConfig::TLPDBConfigs) { - push @bar, "$k/" . $TeXLive::TLConfig::TLPDBConfigs{$k}; + # in original TL we set the options in TLConfig, but local repositories + # might want to set them in the .tlpsrc file, so give them the option + # to do so + if (!$opt_tlpdb_options_from_tlpsrc) { + my @bar = $tlp->depends; + for my $k (sort keys %TeXLive::TLConfig::TLPDBConfigs) { + push @bar, "$k/" . $TeXLive::TLConfig::TLPDBConfigs{$k}; + } + # add the latest revision + push @bar, "revision/".$tltree->revision; + $tlp->depends (@bar); } - # add the latest revision - push @bar, "revision/".$tltree->revision; - $tlp->depends (@bar); } $tldb->add_tlpobj ($tlp); } @@ -443,6 +450,14 @@ file, with the exception that it does I<not> warn for binpatterns when working on the win32 architecture. Giving this option makes it issue all warnings, i.e., also those where a binpattern on win32 does not hit. +=item B<-tlpdb-options-from-tlpsrc> + +By default the tlpdb specific settings in 00texlive.config are taken from +the C<%TeXLive::TLConfig::TLPDBConfigs>. Alternative repositories might +set these values directly in the tlpsrc file. Using +B<-tlpdb-options-from-tlpsrc> overrides the default behaviour and does +not add anything to the configs set in the tlpsrc file. + =back The standard options C<-q>, C<-v>, and C<-logfile>=I<file> are also diff --git a/Master/tlpkg/doc/repository-setup.txt b/Master/tlpkg/doc/repository-setup.txt index adfded61e32..b6d52177848 100644 --- a/Master/tlpkg/doc/repository-setup.txt +++ b/Master/tlpkg/doc/repository-setup.txt @@ -100,36 +100,51 @@ and place them into You have to have ONE .tlpsrc file for each package you want to ship, and furthermore ONE for your overall installation, called -00texlive.config.tlpsrc. This should contain (at least) the following -lines: +00texlive.config.tlpsrc. This package defines some basic configurations +for the tlpdb, like how it announces itself, whether separate src and +doc containers are build, and the release years it supports. + +By default these values are taken from %TeXLive::TLConfig::TLPDBConfigs +where you can make changes in your local TLConfig.pm file, or you add +these settings directly in the tlpsrc file and call tl-update-tlpdb +later on with the option -tlpdb-options-from-tlpsrc. + +In the end the generate "package" 00texlive.config should contain +(at least) the following lines: category TLCore - depend container_split_src_files - depend container_split_doc_files depend container_format/xz depend release/NNNN-YOUR_ID + +and might optionally contain: + depend container_split_src_files + depend container_split_doc_files depend maxrelease/MMMM-YOUR_ID +The + depend container_format/xz +is *obligatory* because currently we do NOT support any other format. + The "container_split_src_files" and "container_split_doc_files" are options, they specify whether at a later stage the container script will generate separate .tar.xz archives for source and doc files, or put all of them into one .tar.xz. It is up to you. -The - depend container_format/xz -is *obligatory* because currently we do NOT support any other format. - Finally, the depend release/NNNN-YOUR_ID +and (optionally) depend maxrelease/MMMM-YOUR_ID determine(s) which release(s) of TL your repository works with. -If maxrelease is present, the year specified in $TLConfig::ReleaseYear -must be in the range [release,maxrelease]. Otherwise the release/NNNN -value must exactly match the the TL release number NNNN. +If maxrelease is present, the year specified in the local (user's) +installation's $TLConfig::ReleaseYear must be in the range +[release,maxrelease]. +If maxrelease is not present, the release/NNNN value must exactly +match the the TL release number NNNN. For example, you might have: depend release/2009-myorg and if your packages work with both TL'09 and TL'10, you could add: depend maxrelease/2010-myorg + For the rest of your package you should create .tlpsrc files describing their content. Either copy one of our .tlpsrc files, or (much better) PLEASE read the documentation of TLPSRC.pm (in POD format). @@ -156,6 +171,9 @@ the TLPSRC.pm documentation (and don't forget to copy If you have set up all your local files, and the tlpsrc files, you can create the TeX Live Database in ROOT/tlpkg/texlive.tlpdb by calling perl ROOT/tlpkg/bin/tl-update-tlpdb -from-files +If you have set your TLPDB configuration options directly in the .tlpsrc +file you have to add + -tlpdb-options-from-tlpsrc The -from-files does use a find command to find all the files in ROOT instead of using "svn status" what is done normally. By default tl-update-tlpdb uses all tlpsrc files present in ROOT/tlpkg/tlpsrc/. |