merge #1197: gnuplot darwin changes
This commit is contained in:
commit
c11747b3f5
|
@ -2,7 +2,7 @@
|
||||||
, pkgconfig, gtk, libXft, dbus, libpng, libjpeg, libungif
|
, pkgconfig, gtk, libXft, dbus, libpng, libjpeg, libungif
|
||||||
, libtiff, librsvg, texinfo, gconf, libxml2, imagemagick, gnutls
|
, libtiff, librsvg, texinfo, gconf, libxml2, imagemagick, gnutls
|
||||||
, alsaLib, cairo
|
, alsaLib, cairo
|
||||||
, withX ? true
|
, withX ? !stdenv.isDarwin
|
||||||
}:
|
}:
|
||||||
|
|
||||||
assert (libXft != null) -> libpng != null; # probably a bug
|
assert (libXft != null) -> libpng != null; # probably a bug
|
||||||
|
|
|
@ -6,6 +6,7 @@
|
||||||
, libXt ? null
|
, libXt ? null
|
||||||
, libXpm ? null
|
, libXpm ? null
|
||||||
, libXaw ? null
|
, libXaw ? null
|
||||||
|
, aquaterm ? false
|
||||||
, wxGTK ? null
|
, wxGTK ? null
|
||||||
, pango ? null
|
, pango ? null
|
||||||
, cairo ? null
|
, cairo ? null
|
||||||
|
@ -15,7 +16,9 @@
|
||||||
, coreutils ? null }:
|
, coreutils ? null }:
|
||||||
|
|
||||||
assert libX11 != null -> (fontconfig != null && gnused != null && coreutils != null);
|
assert libX11 != null -> (fontconfig != null && gnused != null && coreutils != null);
|
||||||
|
let
|
||||||
|
withX = libX11 != null && !aquaterm;
|
||||||
|
in
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
name = "gnuplot-4.6.3";
|
name = "gnuplot-4.6.3";
|
||||||
|
|
||||||
|
@ -25,14 +28,18 @@ stdenv.mkDerivation rec {
|
||||||
};
|
};
|
||||||
|
|
||||||
buildInputs =
|
buildInputs =
|
||||||
[ zlib gd texinfo readline emacs lua texLive libX11 libXt libXpm libXaw
|
[ zlib gd texinfo readline emacs lua texLive
|
||||||
pango cairo pkgconfig makeWrapper ]
|
pango cairo pkgconfig makeWrapper ]
|
||||||
|
++ stdenv.lib.optionals withX [ libX11 libXpm libXt libXaw ]
|
||||||
# compiling with wxGTK causes a malloc (double free) error on darwin
|
# compiling with wxGTK causes a malloc (double free) error on darwin
|
||||||
++ stdenv.lib.optional (!stdenv.isDarwin) wxGTK;
|
++ stdenv.lib.optional (!stdenv.isDarwin) wxGTK;
|
||||||
|
|
||||||
configureFlags = if libX11 != null then ["--with-x"] else ["--without-x"];
|
configureFlags =
|
||||||
|
(if withX then ["--with-x"] else ["--without-x"])
|
||||||
|
++ (if aquaterm then ["--with-aquaterm"] else ["--without-aquaterm"])
|
||||||
|
;
|
||||||
|
|
||||||
postInstall = stdenv.lib.optionalString (libX11 != null) ''
|
postInstall = stdenv.lib.optionalString withX ''
|
||||||
wrapProgram $out/bin/gnuplot \
|
wrapProgram $out/bin/gnuplot \
|
||||||
--prefix PATH : '${gnused}/bin' \
|
--prefix PATH : '${gnused}/bin' \
|
||||||
--prefix PATH : '${coreutils}/bin' \
|
--prefix PATH : '${coreutils}/bin' \
|
||||||
|
|
|
@ -1011,6 +1011,9 @@ let
|
||||||
else stdenv;
|
else stdenv;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# must have AquaTerm installed separately
|
||||||
|
gnuplot_aquaterm = gnuplot.override { aquaterm = true; };
|
||||||
|
|
||||||
gnused = callPackage ../tools/text/gnused { };
|
gnused = callPackage ../tools/text/gnused { };
|
||||||
|
|
||||||
gnutar = callPackage ../tools/archivers/gnutar { };
|
gnutar = callPackage ../tools/archivers/gnutar { };
|
||||||
|
|
Loading…
Reference in a new issue