summaryrefslogtreecommitdiff
path: root/pkg/linux-headers/fetch.sh
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2020-05-08 13:05:22 -0700
committerMichael Forney <mforney@mforney.org>2020-05-08 13:05:22 -0700
commitf74127556dade2c7434517caf16967e452787d79 (patch)
tree1227b2bce10bcd9878f3944800a34d7dfaded272 /pkg/linux-headers/fetch.sh
parent64dcee6008ce4d8704babb9a107fd0afdb6f4993 (diff)
Detect decompression tool automatically
This fixes cross-compilation from macOS, whose bsdtar does support xz through liblzma, but does not have xz(1).
Diffstat (limited to 'pkg/linux-headers/fetch.sh')
-rw-r--r--pkg/linux-headers/fetch.sh4
1 files changed, 1 insertions, 3 deletions
diff --git a/pkg/linux-headers/fetch.sh b/pkg/linux-headers/fetch.sh
index 94d70276..0d5f32d8 100644
--- a/pkg/linux-headers/fetch.sh
+++ b/pkg/linux-headers/fetch.sh
@@ -1,5 +1,4 @@
: "${SHA256SUM:=sha256sum}"
-: "${PAXREAD:=pax -r}"
set -e
@@ -18,8 +17,7 @@ if ! $SHA256SUM -c sha256 2>/dev/null ; then
fi
read -r _ archive <sha256
-
-xz -d -c "$archive" | $PAXREAD -s ',^[^/]*,src,' \
+sh "$OLDPWD/scripts/extract.sh" "$archive" -s ',^[^/]*,src,' \
'linux-*/Makefile' \
'linux-*/arch/*/include/uapi' \
'linux-*/arch/*/syscalls' \