Commit 4ac541a6 authored by Mo Zhou's avatar Mo Zhou

Amend autopkgtest script dkms-zfs-test

parent 44e2a958
Pipeline #30953 failed with stages
in 19 minutes and 48 seconds
......@@ -2,6 +2,6 @@ Tests: kernel-smoke-test
Restrictions: needs-root, isolation-machine
Depends: zfsutils-linux [ amd64 arm64 ppc64el s390x ], zfs-zed [ amd64 arm64 ppc64el s390x ], zfs-initramfs [ amd64 arm64 ppc64el s390x ], zfs-dkms [ amd64 arm64 ppc64el s390x ], zfs-test [ amd64 arm64 ppc64el s390x ]
Test: dkms-zfs-test
Restrictions: needs-root,
Depends: dkms, zfs-dkms [ amd64 arm64 ppc64el s390x ], linux-headers-amd64 [ amd64 ],
Tests: dkms-zfs-test
Restrictions: needs-root, allow-stderr
Depends: dkms, spl-dkms, zfs-dkms [ amd64 arm64 ppc64el s390x ],
set -e
kver=$(dpkg -s linux-headers-amd64 | grep Depends: | sed -e 's@.*linux-headers-\(.*-amd64\).*@\1@')
zfsver=$(dpkg -s zfs-dkms | grep Version: | sed -e 's@Version: \(.*\)-.*@\1@')
echo dkms build -k $kver zfs/$zfsver
set -xe
DEB_HOST_ARCH=$(dpkg --print-architecture)
kver=$(apt-cache show linux-headers-$DEB_HOST_ARCH | grep Depends: | sed -e 's@.*linux-headers-\(.*\)\w*@\1@')
zfsver=$(apt-cache show zfs-dkms | grep Version: | sed -e 's@Version: \(.*\)-.*@\1@')
if ! (echo "amd64 arm64 ppc64el s390x" | grep -o $DEB_HOST_ARCH); then
exit 0
echo Building ZFS/$zfsver for Linux/$kver
apt-get install linux-headers-$DEB_HOST_ARCH -y
dkms build -k $kver spl/$zfsver
dkms build -k $kver zfs/$zfsver
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment