mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-08 22:14:34 +00:00
e04c0b0d99
This re-introduces the old stable ZFS version we had in the past following the many predicted issues of ZFS 2.2.x series, that is much more stable than any further ZFS version at the moment. I am also removing myself from maintenance of any further ZFS versions as I am planning to quit ZFS maintenance at some point. In the meantime, for users like me who depend on ZFS for critical operations, here is a ZFS version that is known to work for LTS kernels.
38 lines
930 B
Nix
38 lines
930 B
Nix
{ callPackage
|
|
, kernel ? null
|
|
, stdenv
|
|
, linuxKernel
|
|
, removeLinuxDRM ? false
|
|
, fetchpatch
|
|
, nixosTests
|
|
, ...
|
|
} @ args:
|
|
|
|
let
|
|
stdenv' = if kernel == null then stdenv else kernel.stdenv;
|
|
in
|
|
callPackage ./generic.nix args {
|
|
# You have to ensure that in `pkgs/top-level/linux-kernels.nix`
|
|
# this attribute is the correct one for this package.
|
|
kernelModuleAttribute = "zfs";
|
|
# check the release notes for compatible kernels
|
|
kernelCompatible =
|
|
if stdenv'.isx86_64 || removeLinuxDRM
|
|
then kernel.kernelOlder "6.6"
|
|
else kernel.kernelOlder "6.2";
|
|
|
|
latestCompatibleLinuxPackages = if stdenv'.isx86_64 || removeLinuxDRM
|
|
then linuxKernel.packages.linux_6_5
|
|
else linuxKernel.packages.linux_6_1;
|
|
|
|
# this package should point to the latest release.
|
|
version = "2.2.0";
|
|
|
|
tests = [
|
|
nixosTests.zfs.installer
|
|
nixosTests.zfs.stable
|
|
];
|
|
|
|
hash = "sha256-s1sdXSrLu6uSOmjprbUa4cFsE2Vj7JX5i75e4vRnlvg=";
|
|
}
|