2015-04-21 19:00:01 +01:00
|
|
|
# FIXME: remove gcc49 when the default gcc supports C++1y
|
|
|
|
{ stdenv, fetchFromGitHub, freetype, gcc49, imlib2, jbig2dec, libjpeg, libX11
|
|
|
|
, mujs, mupdf, ncurses, openjpeg, openssl }:
|
2015-01-14 22:31:47 +00:00
|
|
|
|
2015-04-21 19:00:01 +01:00
|
|
|
let
|
|
|
|
version = "0.5.1";
|
|
|
|
binaries = [ "jfbpdf" "jfbview" "jpdfcat" "jpdfgrep" ];
|
|
|
|
in
|
2015-01-14 22:31:47 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "jfbview-${version}";
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2015-04-21 19:00:01 +01:00
|
|
|
sha256 = "113bkf49q04k9rjps5l28ychmzsfjajp9cjhr433s9ld0972z01m";
|
|
|
|
rev = version;
|
2015-01-14 22:31:47 +00:00
|
|
|
repo = "JFBView";
|
|
|
|
owner = "jichu4n";
|
|
|
|
};
|
|
|
|
|
2015-04-21 19:00:01 +01:00
|
|
|
buildInputs = [ freetype gcc49 imlib2 jbig2dec libjpeg libX11 mujs mupdf
|
|
|
|
ncurses openjpeg openssl ];
|
2015-01-14 22:31:47 +00:00
|
|
|
|
2015-04-21 19:00:01 +01:00
|
|
|
buildFlags = binaries;
|
2015-01-14 22:31:47 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
2015-04-21 19:00:01 +01:00
|
|
|
install ${toString binaries} $out/bin
|
2015-01-14 22:31:47 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2015-04-21 19:00:01 +01:00
|
|
|
inherit version;
|
2015-01-14 22:31:47 +00:00
|
|
|
description = "PDF and image viewer for the Linux framebuffer";
|
|
|
|
longDescription = ''
|
2015-04-21 19:00:01 +01:00
|
|
|
A very fast PDF and image viewer for the Linux framebuffer with some
|
|
|
|
advanced and unique features, including:
|
|
|
|
- Reads PDFs (MuPDF) and common image formats (Imlib2)
|
|
|
|
- Supports arbitrary zoom (10% - 1000%) and rotation
|
|
|
|
- Table of Contents (TOC) viewer for PDF documents
|
|
|
|
- Multi-threaded rendering on multi-core machines
|
|
|
|
- Asynchronous background rendering of the next page
|
|
|
|
- Customizable multi-threaded caching
|
2015-01-14 22:31:47 +00:00
|
|
|
'';
|
|
|
|
homepage = http://seasonofcode.com/pages/jfbview.html;
|
|
|
|
license = with licenses; asl20;
|
|
|
|
platforms = with platforms; linux;
|
|
|
|
maintainers = with maintainers; [ nckx ];
|
|
|
|
};
|
|
|
|
}
|