Merge pull request #69375 from cko/thinkfan-1.0.2
thinkfan: 0.9.3 -> 1.0.2 (replaces #55895)
This commit is contained in:
commit
aab7e12a87
@ -1,34 +1,46 @@
|
|||||||
{ stdenv, fetchurl, cmake
|
{ stdenv, fetchFromGitHub, cmake, libyamlcpp, pkgconfig
|
||||||
, smartSupport ? false, libatasmart }:
|
, smartSupport ? false, libatasmart }:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "thinkfan";
|
pname = "thinkfan";
|
||||||
version = "0.9.3";
|
version = "1.0.2";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchFromGitHub {
|
||||||
url = "mirror://sourceforge/thinkfan/thinkfan-${version}.tar.gz";
|
owner = "vmatare";
|
||||||
sha256 = "0nz4c48f0i0dljpk5y33c188dnnwg8gz82s4grfl8l64jr4n675n";
|
repo = "thinkfan";
|
||||||
|
rev = version;
|
||||||
|
sha256 = "107vw0962hrwva3wra9n3hxlbfzg82ldc10qssv3dspja88g8psr";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake ];
|
cmakeFlags = [
|
||||||
|
"-DCMAKE_INSTALL_DOCDIR=share/doc/${pname}"
|
||||||
|
"-DUSE_NVML=OFF"
|
||||||
|
] ++ stdenv.lib.optional smartSupport "-DUSE_ATASMART=ON";
|
||||||
|
|
||||||
buildInputs = stdenv.lib.optional smartSupport libatasmart;
|
nativeBuildInputs = [ cmake pkgconfig ];
|
||||||
|
|
||||||
cmakeFlags = stdenv.lib.optional smartSupport "-DUSE_ATASMART=ON";
|
buildInputs = [ libyamlcpp ] ++ stdenv.lib.optional smartSupport libatasmart;
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
|
runHook preInstall
|
||||||
|
|
||||||
install -Dm755 {.,$out/bin}/thinkfan
|
install -Dm755 {.,$out/bin}/thinkfan
|
||||||
|
|
||||||
cd "$NIX_BUILD_TOP"; cd "$sourceRoot" # attempt to be a bit robust
|
cd "$NIX_BUILD_TOP"; cd "$sourceRoot" # attempt to be a bit robust
|
||||||
install -Dm644 {.,$out/share/doc/thinkfan}/README
|
install -Dm644 {.,$out/share/doc/thinkfan}/README
|
||||||
cp -R examples $out/share/doc/thinkfan
|
cp -R examples $out/share/doc/thinkfan
|
||||||
install -Dm644 {src,$out/share/man/man1}/thinkfan.1
|
install -Dm644 {src,$out/share/man/man1}/thinkfan.1
|
||||||
|
|
||||||
|
runHook postInstall
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = {
|
meta = with stdenv.lib; {
|
||||||
license = stdenv.lib.licenses.gpl3;
|
description = "A minimalist fan control program. Originally designed
|
||||||
homepage = http://thinkfan.sourceforge.net/;
|
specifically for IBM/Lenovo Thinkpads, it now supports any kind of system via
|
||||||
maintainers = with stdenv.lib.maintainers; [ domenkozar ];
|
the sysfs hwmon interface (/sys/class/hwmon).";
|
||||||
platforms = stdenv.lib.platforms.linux;
|
license = licenses.gpl3;
|
||||||
|
homepage = "https://github.com/vmatare/thinkfan";
|
||||||
|
maintainers = with maintainers; [ domenkozar ];
|
||||||
|
platforms = platforms.linux;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user