2021-02-05 17:12:51 +00:00
|
|
|
{ lib, stdenv, fetchurl, autoreconfHook, pkg-config, cmocka, acl, libuuid, lzo, zlib, zstd }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "mtd-utils";
|
2021-03-12 07:09:13 +00:00
|
|
|
version = "2.1.2";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "ftp://ftp.infradead.org/pub/${pname}/${pname}-${version}.tar.bz2";
|
2021-03-12 07:09:13 +00:00
|
|
|
sha256 = "sha256-itTF80cW1AZGqihySi9WFtMlpvEZJU+RTiaXbx926dY=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
nativeBuildInputs = [ autoreconfHook pkg-config ] ++ lib.optional doCheck cmocka;
|
2020-04-24 23:36:52 +00:00
|
|
|
buildInputs = [ acl libuuid lzo zlib zstd ];
|
|
|
|
|
2021-03-12 07:09:13 +00:00
|
|
|
configureFlags = with lib; [
|
|
|
|
(enableFeature doCheck "unit-tests")
|
|
|
|
(enableFeature doCheck "tests")
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
doCheck = stdenv.hostPlatform == stdenv.buildPlatform;
|
|
|
|
|
2021-03-12 07:09:13 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Tools for MTD filesystems";
|
2021-03-12 07:09:13 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "http://www.linux-mtd.infradead.org/";
|
2021-03-12 07:09:13 +00:00
|
|
|
maintainers = with maintainers; [ viric superherointj ];
|
|
|
|
platforms = with platforms; linux;
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|