Blame 0010-dracut.sh-don-t-check-gzip-for-rsyncable-if-pigz-is-.patch
|
Harald Hoyer |
eeb1c2 |
From 66fd7e43295cb67ac6eaaced3c7b271920e07dce Mon Sep 17 00:00:00 2001
|
|
Harald Hoyer |
eeb1c2 |
From: Harald Hoyer <harald@redhat.com>
|
|
Harald Hoyer |
eeb1c2 |
Date: Wed, 29 Oct 2014 14:18:34 +0100
|
|
Harald Hoyer |
eeb1c2 |
Subject: [PATCH] dracut.sh: don't check gzip for --rsyncable, if pigz is
|
|
Harald Hoyer |
eeb1c2 |
available
|
|
Harald Hoyer |
eeb1c2 |
|
|
Harald Hoyer |
eeb1c2 |
---
|
|
Harald Hoyer |
eeb1c2 |
dracut.sh | 8 +++++++-
|
|
Harald Hoyer |
eeb1c2 |
1 file changed, 7 insertions(+), 1 deletion(-)
|
|
Harald Hoyer |
eeb1c2 |
|
|
Harald Hoyer |
eeb1c2 |
diff --git a/dracut.sh b/dracut.sh
|
|
Harald Hoyer |
eeb1c2 |
index 7aa1264..4590f79 100755
|
|
Harald Hoyer |
eeb1c2 |
--- a/dracut.sh
|
|
Harald Hoyer |
eeb1c2 |
+++ b/dracut.sh
|
|
Harald Hoyer |
eeb1c2 |
@@ -822,7 +822,13 @@ case $compress in
|
|
Harald Hoyer |
eeb1c2 |
bzip2) compress="bzip2 -9";;
|
|
Harald Hoyer |
eeb1c2 |
lzma) compress="lzma -9 -T0";;
|
|
Harald Hoyer |
eeb1c2 |
xz) compress="xz --check=crc32 --lzma2=dict=1MiB -T0";;
|
|
Harald Hoyer |
eeb1c2 |
- gzip) compress="gzip -n -9"; command -v gzip --help 2>&1 | grep -q rsyncable && compress="gzip -n -9 --rsyncable"; command -v pigz > /dev/null 2>&1 && compress="pigz -9 -n -T -R";;
|
|
Harald Hoyer |
eeb1c2 |
+ gzip) compress="gzip -n -9";
|
|
Harald Hoyer |
eeb1c2 |
+ if command -v pigz > /dev/null 2>&1; then
|
|
Harald Hoyer |
eeb1c2 |
+ compress="pigz -9 -n -T -R"
|
|
Harald Hoyer |
eeb1c2 |
+ elif command -v gzip --help 2>&1 | grep -q rsyncable; then
|
|
Harald Hoyer |
eeb1c2 |
+ compress="gzip -n -9 --rsyncable"
|
|
Harald Hoyer |
eeb1c2 |
+ fi
|
|
Harald Hoyer |
eeb1c2 |
+ ;;
|
|
Harald Hoyer |
eeb1c2 |
lzo) compress="lzop -9";;
|
|
Harald Hoyer |
eeb1c2 |
lz4) compress="lz4 -l -9";;
|
|
Harald Hoyer |
eeb1c2 |
esac
|