nixpkgs/pkgs/os-specific/linux/apfs/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

50 lines
1.4 KiB
Nix
Raw Normal View History

2021-02-10 02:37:24 +03:00
{ lib
, stdenv
, fetchFromGitHub
, kernel
, nixosTests
2021-02-10 02:37:24 +03:00
}:
let
tag = "0.3.7";
in
2021-02-10 02:37:24 +03:00
stdenv.mkDerivation {
pname = "apfs";
version = "${tag}-${kernel.version}";
2021-02-10 02:37:24 +03:00
src = fetchFromGitHub {
owner = "linux-apfs";
repo = "linux-apfs-rw";
rev = "v${tag}";
hash = "sha256-LmUaIKZ1Msc4yAXNMzyDhPCPsQYeYnUbRF6pA9WvHYk=";
2021-02-10 02:37:24 +03:00
};
hardeningDisable = [ "pic" ];
nativeBuildInputs = kernel.moduleBuildDependencies;
makeFlags = kernel.makeFlags ++ [
2021-02-10 02:37:24 +03:00
"KERNELRELEASE=${kernel.modDirVersion}"
"KERNEL_DIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
"INSTALL_MOD_PATH=$(out)"
];
passthru.tests.apfs = nixosTests.apfs;
2021-02-10 02:37:24 +03:00
meta = with lib; {
description = "APFS module for linux";
longDescription = ''
The Apple File System (APFS) is the copy-on-write filesystem currently
used on all Apple devices. This module provides a degree of experimental
support on Linux.
If you make use of the write support, expect data corruption.
Read-only support is somewhat more complete, with sealed volumes,
snapshots, and all the missing compression algorithms recently added.
Encryption is still not in the works though.
'';
2021-02-10 02:37:24 +03:00
homepage = "https://github.com/linux-apfs/linux-apfs-rw";
license = licenses.gpl2Only;
platforms = platforms.linux;
maintainers = with maintainers; [ Luflosi ];
};
}