diff options
author | sjau <github.com@sjau.ch> | 2018-02-03 17:29:31 +0100 |
---|---|---|
committer | Jörg Thalheim <joerg@thalheim.io> | 2018-02-07 20:46:16 +0000 |
commit | 0d65e2e0e5b318614bf967c71308355939d9aaaf (patch) | |
tree | 89681e9c21a0cf26e5c55378009f3a070c14bc17 /pkgs/os-specific/linux/zfs | |
parent | 4442a377cb54ca6df3172fa0e7ac1268c30e0a69 (diff) |
zfs: add migration path for new crypto format
fixes #34559
Diffstat (limited to 'pkgs/os-specific/linux/zfs')
-rw-r--r-- | pkgs/os-specific/linux/zfs/default.nix | 37 |
1 files changed, 30 insertions, 7 deletions
diff --git a/pkgs/os-specific/linux/zfs/default.nix b/pkgs/os-specific/linux/zfs/default.nix index 5489bc5abbecd..c00bd286b7e42 100644 --- a/pkgs/os-specific/linux/zfs/default.nix +++ b/pkgs/os-specific/linux/zfs/default.nix @@ -5,7 +5,7 @@ , zlib, libuuid, python, attr, openssl # Kernel dependencies -, kernel ? null, spl ? null, splUnstable ? null +, kernel ? null, spl ? null, splUnstable ? null, splLegacyCrypto ? null }: with stdenv.lib; @@ -19,6 +19,7 @@ let , spl , rev ? "zfs-${version}" , isUnstable ? false + , isLegacyCrypto ? false , incompatibleKernelVersion ? null } @ args: if buildKernel && (incompatibleKernelVersion != null) && @@ -43,7 +44,7 @@ let buildInputs = optionals buildKernel [ spl ] ++ optionals buildUser [ zlib libuuid python attr ] - ++ optionals (buildUser && isUnstable) [ openssl ]; + ++ optionals (buildUser && (isUnstable || isLegacyCrypto)) [ openssl ]; # for zdb to get the rpath to libgcc_s, needed for pthread_cancel to work NIX_CFLAGS_LINK = "-lgcc_s"; @@ -160,19 +161,41 @@ in { incompatibleKernelVersion = null; # this package should point to a version / git revision compatible with the latest kernel release - version = "2018-01-10"; + version = "2018-02-02"; - rev = "1d53657bf561564162e2ad6449f80fa0140f1dd6"; - sha256 = "0ibkhfz06cypgl2c869dzdbdx2i3m8ywwdmnzscv0cin5gm31vhx"; + rev = "fbd42542686af053f0d162ec4630ffd4fff1cc30"; + sha256 = "0qzkwnnk7kz1hwvcaqlpzi5yspfhhmd2alklc07k056ddzbx52qb"; isUnstable = true; extraPatches = [ (fetchpatch { - url = "https://github.com/Mic92/zfs/compare/ded8f06a3cfee...nixos-zfs-2017-09-12.patch"; - sha256 = "033wf4jn0h0kp0h47ai98rywnkv5jwvf3xwym30phnaf8xxdx8aj"; + url = "https://github.com/Mic92/zfs/compare/fbd42542686af053f0d162ec4630ffd4fff1cc30...nixos-zfs-2018-02-02.patch"; + sha256 = "05wqwjm9648x60vkwxbp8l6z1q73r2a5l2ni28i2f4pla8s3ahln"; }) ]; spl = splUnstable; }; + + zfsLegacyCrypto = common { + # comment/uncomment if breaking kernel versions are known + incompatibleKernelVersion = null; + + # this package should point to a version / git revision compatible with the latest kernel release + version = "2018-02-01"; + + rev = "4c46b99d24a6e71b3c72462c11cb051d0930ad60"; + sha256 = "011lcp2x44jgfzqqk2gjmyii1v7rxcprggv20prxa3c552drsx3c"; + isUnstable = true; + + extraPatches = [ + (fetchpatch { + url = "https://github.com/Mic92/zfs/compare/4c46b99d24a6e71b3c72462c11cb051d0930ad60...nixos-zfs-2018-02-01.patch"; + sha256 = "1gqmgqi39qhk5kbbvidh8f2xqq25vj58i9x0wjqvcx6a71qj49ch"; + }) + ]; + + spl = splLegacyCrypto; + }; + } |