nixpkgs/pkgs/tools/misc/ddccontrol/default.nix
Vladimír Čunát f41f7a0bb9 ddccontrol*: cleanup
- remove doubled file for ddccontrol-db
- adding stdenv to buildInputs is pointless
- fix doubled http://
- whitespace, etc.
2015-03-16 21:47:06 +01:00

59 lines
1.2 KiB
Nix

{ stdenv
, fetchurl
, intltool
, libtool
, autoconf
, automake110x
, perl
, perlPackages
, libxml2
, pciutils
, pkgconfig
, gtk
, ddccontrol-db
}:
let version = "0.4.2"; in
stdenv.mkDerivation {
name = "ddccontrol-${version}";
src = fetchurl {
url = "mirror://sourceforge/ddccontrol/ddccontrol-${version}.tar.bz2";
sha1 = "fd5c53286315a61a18697a950e63ed0c8d5acff1";
};
buildInputs =
[
intltool
libtool
autoconf
automake110x
perl
perlPackages.libxml_perl
libxml2
pciutils
pkgconfig
gtk
ddccontrol-db
];
prePatch = ''
newPath=$(echo "${ddccontrol-db}/share/ddccontrol-db" | sed "s/\\//\\\\\\//g")
mv configure.ac configure.ac.old
oldPath="\$"
oldPath+="{datadir}\/ddccontrol-db"
sed "s/$oldPath/$newPath/" <configure.ac.old >configure.ac
rm configure.ac.old
'';
preConfigure = ''
autoreconf --install
'';
meta = with stdenv.lib; {
description = "A program used to control monitor parameters by software";
homepage = "http://ddccontrol.sourceforge.net/";
license = licenses.gpl2;
platforms = platforms.linux;
maintainers = [ stdenv.lib.maintainers.pakhfn ];
};
}