3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/graphics/feh/default.nix
2016-05-31 12:48:40 +01:00

40 lines
1.1 KiB
Nix

{ stdenv, makeWrapper, fetchurl, xlibsWrapper, imlib2, libjpeg, libpng
, libXinerama, curl, libexif, perlPackages }:
stdenv.mkDerivation rec {
name = "feh-2.15.4";
src = fetchurl {
url = "http://feh.finalrewind.org/${name}.tar.bz2";
sha256 = "b8a9c29f37b1349228b19866f712b677e2a150837bc46be8c5d6348dd4850758";
};
outputs = [ "out" "doc" ];
nativeBuildInputs = [ makeWrapper ];
buildInputs = [ xlibsWrapper imlib2 libjpeg libpng libXinerama curl libexif ]
++ stdenv.lib.optional doCheck [ perlPackages.TestCommand perlPackages.TestHarness ];
preBuild = ''
makeFlags="PREFIX=$out exif=1"
'';
postInstall = ''
wrapProgram "$out/bin/feh" --prefix PATH : "${libjpeg.bin}/bin" \
--add-flags '--theme=feh'
'';
checkPhase = ''
PERL5LIB="${perlPackages.TestCommand}/lib/perl5/site_perl" make test
'';
doCheck = true;
meta = {
description = "A light-weight image viewer";
homepage = https://derf.homelinux.org/projects/feh/;
license = stdenv.lib.licenses.mit;
maintainers = with stdenv.lib.maintainers; [viric];
platforms = with stdenv.lib.platforms; unix;
};
}