pkgs/top-level/all-packages.nix: prefer makeOverridable over getPkgConfig to customize GNU plot
Changed 'gnuplot' expression to allow for argument overriding instead of relying on getPkgConfig. While I was at it, I also simplified the actual build expression a bit. svn path=/nixpkgs/trunk/; revision=21864
This commit is contained in:
@@ -10,16 +10,9 @@
|
||||
, pango ? null
|
||||
, cairo ? null
|
||||
, pkgconfig ? null
|
||||
, x11Support ? false
|
||||
, readline
|
||||
}:
|
||||
|
||||
assert x11Support -> ((libX11 != null) &&
|
||||
(libXt != null) && (libXpm != null) &&
|
||||
(libXaw != null));
|
||||
|
||||
assert (wxGTK != null) -> x11Support;
|
||||
|
||||
stdenv.mkDerivation {
|
||||
name = "gnuplot-4.4.0";
|
||||
src = fetchurl {
|
||||
@@ -27,9 +20,10 @@ stdenv.mkDerivation {
|
||||
sha256 = "0akb2lzxa3b0j4nr6anr0mhsk10b1fcnixk8vk9aa82rl1a2rph0";
|
||||
};
|
||||
|
||||
configureFlags = if x11Support then ["--with-x"] else ["--without-x"];
|
||||
configureFlags = if (libX11 != null) then ["--with-x"] else ["--without-x"];
|
||||
|
||||
buildInputs = [zlib gd texinfo readline emacs lua texLive] ++
|
||||
(if x11Support then [libX11 libXt libXpm libXaw] else []) ++
|
||||
(if wxGTK != null then [wxGTK pango cairo pkgconfig] else []);
|
||||
buildInputs = [
|
||||
zlib gd texinfo readline emacs lua texLive libX11 libXt libXpm libXaw
|
||||
wxGTK pango cairo pkgconfig
|
||||
];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user