maintainers: remove email for amuckstot30 (#360059)
[NixPkgs.git] / pkgs / os-specific / linux / freefall / default.nix
blobbad4849ca0bfd3c91af07a7b08e7002cf1a3e466
1 { lib, stdenv, kernel }:
3 stdenv.mkDerivation {
4   inherit (kernel) version src;
6   pname = "freefall";
8   postPatch = ''
9     cd tools/laptop/freefall
11     # Default time-out is a little low, probably because the AC/lid status
12     # functions were never implemented. Because no-one still uses HDDs, right?
13     substituteInPlace freefall.c --replace "alarm(2)" "alarm(5)"
14   '';
16   makeFlags = [ "PREFIX=$(out)" ];
18   meta = with lib; {
19     inherit (kernel.meta) homepage license;
21     description = "Free-fall protection for spinning HP/Dell laptop hard drives";
22     mainProgram = "freefall";
23     longDescription = ''
24       Provides a shock protection facility in modern laptops with spinning hard
25       drives, by stopping all input/output operations on the internal hard drive
26       and parking its heads on the ramp when critical situations are anticipated.
27       Requires support for the ATA/ATAPI-7 IDLE IMMEDIATE command with unload
28       feature, which should cause the drive to switch to idle mode and unload the
29       disk heads, and an accelerometer device. It has no effect on SSD devices!
30     '';
32     platforms = platforms.linux;
33   };