diff options
Diffstat (limited to 'pkgs/misc/ghostscript/default.nix')
-rw-r--r-- | pkgs/misc/ghostscript/default.nix | 27 |
1 files changed, 15 insertions, 12 deletions
diff --git a/pkgs/misc/ghostscript/default.nix b/pkgs/misc/ghostscript/default.nix index 5fe1d680b2b0..64cd8b9f6ac5 100644 --- a/pkgs/misc/ghostscript/default.nix +++ b/pkgs/misc/ghostscript/default.nix @@ -1,6 +1,7 @@ -{ stdenv, fetchurl, libjpeg, libpng, libtiff, zlib, pkgconfig, fontconfig, openssl -, lcms, freetype, libpaper, jbig2dec, expat, libiconvOrEmpty -, x11Support, x11 ? null +{ stdenv, fetchurl, pkgconfig, zlib, expat, openssl +, libjpeg, libpng, libtiff, freetype, fontconfig, lcms2, libpaper, jbig2dec +, libiconvOrEmpty +, x11Support ? false, x11 ? null , cupsSupport ? false, cups ? null , gnuFork ? true }: @@ -40,10 +41,10 @@ let }; mainlineSrc = rec { - name = "ghostscript-9.06"; + name = "ghostscript-9.09"; src = fetchurl { url = "http://downloads.ghostscript.com/public/${name}.tar.bz2"; - sha256 = "014f10rxn4ihvcr1frby4szd1jvkrwvmdhnbivpp55c9fssx3b05"; + sha256 = "1xwn4zlfb9jz0vrda0vd42qwfqddiav7rdkga0q94jc2q1qddzx6"; }; meta = meta_common // { homepage = "http://www.ghostscript.com/"; @@ -51,7 +52,7 @@ let }; preConfigure = '' - rm -R libpng jpeg lcms{,2} tiff freetype jbig2dec expat jasper openjpeg + rm -R libpng jpeg lcms{,2} tiff freetype jbig2dec expat openjpeg substituteInPlace base/unix-aux.mak --replace "INCLUDE=/usr/include" "INCLUDE=/no-such-path" sed "s@if ( test -f \$(INCLUDE)[^ ]* )@if ( true )@" -i base/unix-aux.mak @@ -79,9 +80,9 @@ stdenv.mkDerivation rec { ]; buildInputs = [ - libjpeg libpng libtiff zlib pkgconfig fontconfig openssl lcms - libpaper jbig2dec expat - ] ++ stdenv.lib.optionals x11Support [x11 freetype] + pkgconfig zlib expat openssl + libjpeg libpng libtiff freetype fontconfig lcms2 libpaper jbig2dec + ] ++ stdenv.lib.optional x11Support x11 ++ stdenv.lib.optional cupsSupport cups ++ libiconvOrEmpty # [] # maybe sometimes jpeg2000 support @@ -101,9 +102,11 @@ stdenv.mkDerivation rec { makeFlagsArray=(CUPSSERVERBIN=$out/lib/cups CUPSSERVERROOT=$out/etc/cups CUPSDATA=$out/share/cups) '' + stdenv.lib.optionalString (variant ? preConfigure) variant.preConfigure; - configureFlags = [ "--with-system-libtiff" ] ++ - (if x11Support then [ "--with-x" ] else [ "--without-x" ]) ++ - (if cupsSupport then [ "--enable-cups" "--with-install-cups" ] else [ "--disable-cups" ]); + configureFlags = [ + "--with-system-libtiff" + (if x11Support then "--with-x" else "--without-x") + (if cupsSupport then "--enable-cups" else "--disable-cups") + ]; doCheck = true; |