2013-10-26 19:15:57 +02:00
|
|
|
{ fetchurl, stdenv, libX11, libXrandr, libXxf86vm, libxcb, pkgconfig, python
|
|
|
|
, randrproto, xcbutil, xf86vidmodeproto, autoconf, automake, gettext, glib
|
2013-10-29 16:23:24 +01:00
|
|
|
, GConf, dbus, dbus_glib, makeWrapper, gtk, pygtk, pyxdg, geoclue }:
|
2011-01-25 00:52:22 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2013-10-26 19:15:57 +02:00
|
|
|
version = "1.8";
|
|
|
|
name = "redshift-${version}";
|
2011-01-25 00:52:22 +01:00
|
|
|
src = fetchurl {
|
2013-10-26 19:15:57 +02:00
|
|
|
url = "https://github.com/jonls/redshift/archive/v${version}.tar.gz";
|
|
|
|
sha256 = "1srj2dwy32h71iqikb4ysv5ipclym80i9lys2ns8vjmclg7hj3vi";
|
2011-01-25 00:52:22 +01:00
|
|
|
};
|
|
|
|
|
2013-10-26 19:15:57 +02:00
|
|
|
buildInputs = [
|
|
|
|
libX11 libXrandr libXxf86vm libxcb pkgconfig python randrproto xcbutil
|
|
|
|
xf86vidmodeproto autoconf automake gettext glib GConf dbus dbus_glib
|
2013-10-29 16:23:24 +01:00
|
|
|
makeWrapper gtk pygtk pyxdg geoclue
|
2013-10-26 19:15:57 +02:00
|
|
|
];
|
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
./bootstrap
|
|
|
|
'';
|
|
|
|
|
|
|
|
preInstall = ''
|
|
|
|
substituteInPlace src/redshift-gtk/redshift-gtk python --replace "/usr/bin/env python" "${python}/bin/${python.executable}"
|
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
wrapProgram "$out/bin/redshift-gtk" --prefix PYTHONPATH : $PYTHONPATH:${pygtk}/lib/${python.libPrefix}/site-packages/gtk-2.0:${pyxdg}/lib/${python.libPrefix}/site-packages/pyxdg:$out/lib/${python.libPrefix}/site-packages
|
|
|
|
'';
|
2011-01-25 00:52:22 +01:00
|
|
|
|
2013-11-03 01:03:45 +01:00
|
|
|
meta = with stdenv.lib; {
|
2011-01-25 00:52:22 +01:00
|
|
|
description = "changes the color temperature of your screen gradually";
|
|
|
|
longDescription = ''
|
|
|
|
The color temperature is set according to the position of the
|
|
|
|
sun. A different color temperature is set during night and
|
|
|
|
daytime. During twilight and early morning, the color
|
|
|
|
temperature transitions smoothly from night to daytime
|
|
|
|
temperature to allow your eyes to slowly adapt.
|
|
|
|
'';
|
2014-06-19 06:19:00 +02:00
|
|
|
license = stdenv.lib.licenses.gpl3Plus;
|
2014-09-13 13:51:39 +02:00
|
|
|
homepage = http://jonls.dk/redshift;
|
2013-11-03 01:03:45 +01:00
|
|
|
platforms = platforms.linux;
|
2014-09-13 13:51:39 +02:00
|
|
|
maintainers = [ maintainers.mornfall ];
|
2011-01-25 00:52:22 +01:00
|
|
|
};
|
2013-06-07 02:13:54 +02:00
|
|
|
}
|