Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{lib, stdenv, fetchurl, zlib}: 2 3stdenv.mkDerivation rec { 4 pname = "cramfsswap"; 5 version = "1.4.2"; 6 7 src = fetchurl { 8 url = "mirror://debian/pool/main/c/cramfsswap/${pname}_${version}.tar.xz"; 9 sha256 = "10mj45zx71inaa3l1d81g64f7yn1xcprvq4v4yzpdwbxqmqaikw1"; 10 }; 11 # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=996964 12 patches = [ ./parallel-make.patch ]; 13 14 # Needed for cross-compilation 15 postPatch = '' 16 substituteInPlace Makefile --replace 'strip ' '$(STRIP) ' 17 ''; 18 19 buildInputs = [zlib]; 20 21 installPhase = '' 22 install --target $out/bin -D cramfsswap 23 ''; 24 25 meta = with lib; { 26 description = "Swap endianess of a cram filesystem (cramfs)"; 27 homepage = "https://packages.debian.org/sid/utils/cramfsswap"; 28 license = licenses.gpl2Only; 29 platforms = platforms.linux; 30 }; 31}