diff options
Diffstat (limited to 'Master/tlpkg/TeXLive/TLConfig.pm')
-rw-r--r-- | Master/tlpkg/TeXLive/TLConfig.pm | 42 |
1 files changed, 25 insertions, 17 deletions
diff --git a/Master/tlpkg/TeXLive/TLConfig.pm b/Master/tlpkg/TeXLive/TLConfig.pm index 495a316b0c0..1522a08b0b8 100644 --- a/Master/tlpkg/TeXLive/TLConfig.pm +++ b/Master/tlpkg/TeXLive/TLConfig.pm @@ -27,14 +27,8 @@ BEGIN { %FallbackDownloaderProgram %FallbackDownloaderArgs $DefaultCompressorFormat - $DefaultContainerExtension - @AcceptedCompressors - $AcceptedCompressorsRegexp - %CompressorProgram - %DecompressorProgram - %CompressorArgs - %DecompressorArgs - %CompressorExtension + $CompressorExtRegexp + %Compressors $InfraLocation $DatabaseName $PackageBackupDir @@ -129,15 +123,29 @@ our %FallbackDownloaderArgs = ( ); # the way we package things on the web our $DefaultCompressorFormat = "xz"; -our $DefaultContainerExtension = "tar.$DefaultCompressorFormat"; -# mind that the order here is important as gives also the preference! -our @AcceptedCompressors = qw/lz4 gzip xz/; -our $AcceptedCompressorsRegexp = "(xz|lz4|gzip)"; -our %CompressorProgram = ( 'xz' => 'xz', 'gzip' => 'gzip', 'lz4' => 'lz4'); -our %CompressorExtension = ( 'xz' => 'xz', 'gzip' => 'gz', 'lz4' => 'lz4'); -our %CompressorArgs = ( 'xz' => ['-zf'], 'gzip' => [ '-f' ], 'lz4' => ['-zfm', '--rm', '-q']); -our %DecompressorProgram = ( 'xz' => 'xz', 'gzip' => 'gzip', 'lz4' => 'lz4'); -our %DecompressorArgs = ( 'xz' => ['-dcf'], 'gzip' => ['-dcf'], 'lz4' => ['-dcf']); +# priority defines which compressor is selected for backups/rollback containers +# less is better +our %Compressors = ( + "lz4" => { + "decompress_args" => ["-dcf"], + "compress_args" => ["-zfmq", "--rm"], + "extension" => "lz4", + "priority" => 10, + }, + "gzip" => { + "decompress_args" => ["-dcf"], + "compress_args" => ["-f"], + "extension" => "gz", + "priority" => 20, + }, + "xz" => { + "decompress_args" => ["-dcf"], + "compress_args" => ["-zf"], + "extension" => "xz", + "priority" => 30, + }, +); +our $CompressorExtRegexp = "(" . join("|", map { $Compressors{$_}{'extension'} } keys(%Compressors)) . ")"; # archive (not user) settings. # these can be overridden by putting them into 00texlive.config.tlpsrc |