diff options
| author | Carlo Landmeter <clandmeter@alpinelinux.org> | 2018-11-08 10:38:01 +0000 |
|---|---|---|
| committer | Carlo Landmeter <clandmeter@alpinelinux.org> | 2018-11-08 10:45:48 +0000 |
| commit | bd7dfffa42a4cb3b62deb42055e0492651ce587f (patch) | |
| tree | 4024d399e1cecaf71dc4be26ccdd0bb29ec2727e /main/abuild/add-multithreaded-compression.patch | |
| parent | 547142025a3ed969e8e80288dfa0540f8d672f12 (diff) | |
| download | aports-bd7dfffa42a4cb3b62deb42055e0492651ce587f.tar.bz2 aports-bd7dfffa42a4cb3b62deb42055e0492651ce587f.tar.xz | |
main/abuild: add multithreaded compression support
Diffstat (limited to 'main/abuild/add-multithreaded-compression.patch')
| -rw-r--r-- | main/abuild/add-multithreaded-compression.patch | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/main/abuild/add-multithreaded-compression.patch b/main/abuild/add-multithreaded-compression.patch new file mode 100644 index 0000000000..a89a6bdb20 --- /dev/null +++ b/main/abuild/add-multithreaded-compression.patch @@ -0,0 +1,33 @@ +From 21b62c7675dc63d01b84eb7127227033389f35ae Mon Sep 17 00:00:00 2001 +From: Tiago Ilieve <tiago.myhro@gmail.com> +Date: Sun, 28 Oct 2018 12:34:02 +0000 +Subject: [PATCH] abuild.in: add multithreaded compression + +The 'Compressing data' step takes a significant amount of time when +packaging software with huge binaries, like Kubernetes. This can +certainly be shortened using multithreaded compression, like 'pigz'. +--- + abuild.in | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/abuild.in b/abuild.in +index 42382e5..ec57104 100644 +--- a/abuild.in ++++ b/abuild.in +@@ -1451,6 +1451,7 @@ human_size() { + + create_apks() { + local file= dir= name= ver= apk= datadir= size= ++ local gzip=$(command -v pigz || echo gzip) + getpkgver || return 1 + if ! options_has "!tracedeps"; then + for file in "$pkgbasedir"/.control.*/.PKGINFO; do +@@ -1487,7 +1488,7 @@ create_apks() { + touch .dummy + set -- .dummy + fi +- tar --xattrs -f - -c "$@" | abuild-tar --hash | gzip -9 >"$dir"/data.tar.gz ++ tar --xattrs -f - -c "$@" | abuild-tar --hash | $gzip -9 >"$dir"/data.tar.gz + + msg "Create checksum..." + # append the hash for data.tar.gz |
