graphviz: simplify and add a missing X library

This commit is contained in:
Vladimír Čunát 2015-10-15 19:00:25 +02:00
parent 31d9263159
commit 74d4fc7959

View File

@ -1,4 +1,4 @@
{ stdenv, fetchurl, pkgconfig, libpng, libjpeg, expat, libXaw
{ stdenv, fetchurl, pkgconfig, libpng, libjpeg, expat
, yacc, libtool, fontconfig, pango, gd, xorg, gts, libdevil, gettext, cairo
, flex
}:
@ -22,21 +22,14 @@ stdenv.mkDerivation rec {
buildInputs =
[ pkgconfig libpng libjpeg expat yacc libtool fontconfig gd gts libdevil flex
] ++ stdenv.lib.optionals (xorg != null) [ xorg.xlibsWrapper xorg.libXrender pango libXaw ]
] ++ stdenv.lib.optionals (xorg != null)
(with xorg; [ xlibsWrapper libXrender pango libXaw libXpm ])
++ stdenv.lib.optional (stdenv.system == "x86_64-darwin") gettext;
CPPFLAGS = stdenv.lib.optionalString (xorg != null && stdenv.system == "x86_64-darwin")
"-I${cairo.dev}/include/cairo";
configureFlags =
[ "--with-pngincludedir=${libpng}/include"
"--with-pnglibdir=${libpng}/lib"
"--with-jpegincludedir=${libjpeg}/include"
"--with-jpeglibdir=${libjpeg}/lib"
"--with-expatincludedir=${expat}/include"
"--with-expatlibdir=${expat}/lib"
]
++ stdenv.lib.optional (xorg == null) "--without-x";
configureFlags = stdenv.lib.optional (xorg == null) "--without-x";
preBuild = ''
sed -e 's@am__append_5 *=.*@am_append_5 =@' -i lib/gvc/Makefile