2021-01-11 08:54:33 +01:00
|
|
|
{ lib, stdenv, fetchurl }:
|
2021-01-31 03:50:16 +01:00
|
|
|
let
|
|
|
|
db = fetchurl {
|
2020-04-01 03:11:51 +02:00
|
|
|
url = "mirror://savannah/hddtemp/hddtemp.db";
|
2010-07-28 13:55:54 +02:00
|
|
|
sha256 = "1fr6qgns6qv7cr40lic5yqwkkc7yjmmgx8j0z6d93csg3smzhhya";
|
|
|
|
};
|
2013-02-28 16:00:49 +01:00
|
|
|
|
2021-01-31 03:50:16 +01:00
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "hddtemp";
|
|
|
|
version = "0.3-beta15";
|
|
|
|
|
2008-01-30 18:20:48 +01:00
|
|
|
src = fetchurl {
|
2021-01-31 03:50:16 +01:00
|
|
|
url = "mirror://savannah/hddtemp/hddtemp-${version}.tar.bz2";
|
|
|
|
sha256 = "sha256-YYVBWEBUCT1TvootnoHJcXTzDwCvkcuHAKl+RC1571s=";
|
2007-12-10 23:36:52 +01:00
|
|
|
};
|
|
|
|
|
2013-02-28 16:00:49 +01:00
|
|
|
# from Gentoo
|
|
|
|
patches = [ ./byteswap.patch ./dontwake.patch ./execinfo.patch ./satacmds.patch ];
|
|
|
|
|
2021-01-31 03:50:16 +01:00
|
|
|
configureFlags = [
|
|
|
|
"--with-db-path=${placeholder "out"}/share/${pname}/hddtemp.db"
|
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
install -Dm444 ${db} $out/share/${pname}/hddtemp.db
|
|
|
|
'';
|
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
2007-12-10 23:36:52 +01:00
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2010-07-28 13:55:54 +02:00
|
|
|
description = "Tool for displaying hard disk temperature";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://savannah.nongnu.org/projects/hddtemp/";
|
2016-03-16 01:13:00 +01:00
|
|
|
license = licenses.gpl2Plus;
|
2021-01-31 03:50:16 +01:00
|
|
|
maintainers = with maintainers; [ peterhoeg ];
|
2016-03-16 01:13:00 +01:00
|
|
|
platforms = platforms.linux;
|
2007-12-10 23:36:52 +01:00
|
|
|
};
|
|
|
|
}
|