summaryrefslogtreecommitdiff
path: root/release-process/scripts/mk_exim_release
diff options
context:
space:
mode:
authorPhil Pennock <pdp@exim.org>2017-02-02 15:38:14 -0500
committerPhil Pennock <pdp@exim.org>2017-02-09 21:50:40 -0500
commit00f7a87b04290db615ec29584e0554928fca81c7 (patch)
treec533f6668974d1a5a137b1fb2cbf5c56e5512e43 /release-process/scripts/mk_exim_release
parent6e4aaa853615d40316858a5ca08da784350cb142 (diff)
Release packaging & scripting improvements.exim-4_89_RC3
* Make the .xz tarball variant too, and work harder on compressing our files for distribution. + The .xz files have gained more positive feedback than any other part of the 4.89 release. * Drop usercodes from tarball + We shouldn't be embedding own-system-specifc ownership information into software release tarballs. That's for local system backups, not distribution. * Script for the size/checksums + We include checksums in the mail; this gets the format fixed and not including checksums-of-signatures, etc. I've also experimented with including the size, so let's script that to be portably generated. * Better tarball signing script + Automatically find the signing directory (if not already in it) + Sign all files, properly skipping existing .asc files + Find the signing key from git config, if available, else error out (Nigel is not on the hook as the default victim now) + Show what we're doing as we do it All changes made on the original `release_4_89` branch with `RELEASE EXPERIMENT` subject tags.
Diffstat (limited to 'release-process/scripts/mk_exim_release')
-rwxr-xr-xrelease-process/scripts/mk_exim_release34
1 files changed, 23 insertions, 11 deletions
diff --git a/release-process/scripts/mk_exim_release b/release-process/scripts/mk_exim_release
index f6cd33c7e..34fe77c67 100755
--- a/release-process/scripts/mk_exim_release
+++ b/release-process/scripts/mk_exim_release
@@ -361,21 +361,25 @@ sub create_tar_files {
}
}
+ # See also environment variables set in main, tuning compression levels
+ my @COMPRESSIONS = (
+ # compressors-dict-key, file-extension, flags-as-string
+ [ "gzip", "gz", "--gzip" ],
+ [ "bzip2", "bz2", "--bzip2" ],
+ [ "lzip", "lz", "--lzip" ],
+ [ "xz", "xz", "--xz" ],
+ );
+
foreach my $dir ( glob( File::Spec->catdir( $pkgdirs, ( 'exim*-' . $context->{release} ) ) ) ) {
my $dirname = ( File::Spec->splitdir($dir) )[-1];
- if ($context->{compressors}{gzip}) {
- print "Creating: ${pkgs}/${dirname}.tar.gz\n" if ($verbose || $debug);
- system("$tar cf ${pkgs}/${dirname}.tar.gz --gzip -C ${pkgdirs} ${dirname}")
- }
- if ($context->{compressors}{bzip2}) {
- print "Creating: ${pkgs}/${dirname}.tar.bz2\n" if ($verbose || $debug);
- system("$tar cf ${pkgs}/${dirname}.tar.bz2 --bzip2 -C ${pkgdirs} ${dirname}")
- }
- if ($context->{compressors}{lzip}) {
- print "Creating: ${pkgs}/${dirname}.tar.lz\n" if ($verbose || $debug);
- system("$tar cf ${pkgs}/${dirname}.tar.lz --lzip -C ${pkgdirs} ${dirname}")
+ foreach my $comp (@COMPRESSIONS) {
+ my ($compkey, $extension, $flags) = @{$comp};
+ next unless $context->{compressors}{$compkey};
+ print "Creating: ${pkgs}/${dirname}.tar.${extension}\n" if ($verbose || $debug);
+ system("$tar cf ${pkgs}/${dirname}.tar.${extension} ${flags} --numeric-owner -C ${pkgdirs} ${dirname}");
}
}
+
}
# ------------------------------------------------------------------
@@ -394,6 +398,7 @@ MAIN: {
compressors => {
gzip => 1,
bzip2 => 1,
+ xz => 1,
lzip => 0,
},
build_docs => 1,
@@ -402,6 +407,13 @@ MAIN: {
my $delete;
my $cleanup = 1;
##$ENV{'PATH'} = '/opt/local/bin:' . $ENV{'PATH'};
+ # We are creating files for mass distribution, so work harder to make smaller files.
+ $ENV{'GZIP'} = '-9';
+ $ENV{'BZIP2'} = '-9';
+ # xz documents minimum file sizes for levels higher than -6 to be useful and each
+ # requires more RAM on the decompressing system. Exim tarball currently 24MiB so
+ # using -8.
+ $ENV{'XZ_DEFAULTS'} = '-8';
GetOptions(
'directory=s' => \$context->{directory},