nixpkgs/pkgs/tools/misc/xflux/default.nix
Eelco Dolstra 460df30bd8
Revert "Merge pull request #28557 from obsidiansystems/binutils-wrapper"
This reverts commit 0a944b345e, reversing
changes made to 61733ed6cc.

I dislike these massive stdenv changes with unclear motivation,
especially when they involve gratuitous mass renames like NIX_CC ->
NIX_BINUTILS. The previous such rename (NIX_GCC -> NIX_CC) caused
months of pain, so let's not do that again.

(cherry picked from commit ec8d41f08c)
2017-09-07 12:53:33 +02:00

39 lines
1.1 KiB
Nix

{stdenv, fetchurl, libXxf86vm, libXext, libX11, libXrandr, gcc}:
stdenv.mkDerivation {
name = "xflux-2013-09-01";
src = fetchurl {
url = https://justgetflux.com/linux/xflux64.tgz;
sha256 = "cc50158fabaeee58c331f006cc1c08fd2940a126e99d37b76c8e878ef20c2021";
};
libPath = stdenv.lib.makeLibraryPath [
gcc.cc
libXxf86vm
libXext
libX11
libXrandr
];
unpackPhase = ''
unpackFile $src;
'';
installPhase = ''
mkdir -p "$out/bin"
cp xflux "$out/bin"
'';
postFixup = ''
patchelf --set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) --set-rpath "$libPath" "$out/bin/xflux"
'';
meta = {
description = "Adjusts your screen to emit warmer light at night";
longDescription = ''
xflux changes the color temperature of your screen to be much warmer
when the sun sets, and then changes it back its colder temperature
when the sun rises.
'';
homepage = https://justgetflux.com/;
license = stdenv.lib.licenses.unfree;
platforms = stdenv.lib.platforms.linux;
maintainers = [ stdenv.lib.maintainers.paholg ];
};
}