2021-01-11 07:54:33 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
stdenv,
|
|
|
|
fetchurl,
|
|
|
|
zlib,
|
|
|
|
}:
|
2007-03-24 12:01:50 +00:00
|
|
|
|
2020-07-31 16:01:40 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "cramfsswap";
|
2021-08-21 09:45:44 +00:00
|
|
|
version = "1.4.2";
|
2020-07-31 16:01:40 +00:00
|
|
|
|
2007-03-24 12:01:50 +00:00
|
|
|
src = fetchurl {
|
2021-08-21 09:45:44 +00:00
|
|
|
url = "mirror://debian/pool/main/c/cramfsswap/${pname}_${version}.tar.xz";
|
|
|
|
sha256 = "10mj45zx71inaa3l1d81g64f7yn1xcprvq4v4yzpdwbxqmqaikw1";
|
2007-03-24 12:01:50 +00:00
|
|
|
};
|
2021-10-21 17:19:09 +00:00
|
|
|
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=996964
|
|
|
|
patches = [ ./parallel-make.patch ];
|
2007-03-24 12:01:50 +00:00
|
|
|
|
2021-08-21 09:45:44 +00:00
|
|
|
# Needed for cross-compilation
|
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace Makefile --replace 'strip ' '$(STRIP) '
|
|
|
|
'';
|
|
|
|
|
2007-03-24 12:01:50 +00:00
|
|
|
buildInputs = [ zlib ];
|
2016-08-02 16:06:29 +00:00
|
|
|
|
2020-07-31 16:01:40 +00:00
|
|
|
installPhase = ''
|
|
|
|
install --target $out/bin -D cramfsswap
|
|
|
|
'';
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2020-07-31 16:01:40 +00:00
|
|
|
description = "Swap endianess of a cram filesystem (cramfs)";
|
2024-03-19 02:14:51 +00:00
|
|
|
mainProgram = "cramfsswap";
|
2018-08-15 18:19:36 +00:00
|
|
|
homepage = "https://packages.debian.org/sid/utils/cramfsswap";
|
2021-08-21 09:45:44 +00:00
|
|
|
license = licenses.gpl2Only;
|
2018-08-15 18:19:36 +00:00
|
|
|
platforms = platforms.linux;
|
2016-08-02 16:06:29 +00:00
|
|
|
};
|
2007-03-24 12:01:50 +00:00
|
|
|
}
|