From ffeb95502deeb819e3a2234323a57398a6269f13 Mon Sep 17 00:00:00 2001 From: "Yury G. Kudryashov" Date: Thu, 20 Sep 2007 19:40:22 +0000 Subject: [PATCH] Added dbus variant with X support Default is the old variant (without X). svn path=/nixpkgs/trunk/; revision=9350 --- pkgs/development/libraries/dbus_x/default.nix | 13 +++++++++++++ pkgs/top-level/all-packages.nix | 14 +++++++++++++- 2 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 pkgs/development/libraries/dbus_x/default.nix diff --git a/pkgs/development/libraries/dbus_x/default.nix b/pkgs/development/libraries/dbus_x/default.nix new file mode 100644 index 000000000000..dfe3ea0ee7e9 --- /dev/null +++ b/pkgs/development/libraries/dbus_x/default.nix @@ -0,0 +1,13 @@ +args: with args; + +stdenv.mkDerivation { + name = "dbus-1.0.2"; + src = fetchurl { + url = http://dbus.freedesktop.org/releases/dbus/dbus-1.0.2.tar.gz; + sha256 = "1jn652zb81mczsx4rdcwrrzj3lfhx9d107zjfnasc4l5yljl204a"; + }; + buildInputs = [pkgconfig expat libX11 libICE libSM]; + + configureFlags = "--with-x --disable-static --localstatedir=/var --with-session-socket-dir=/tmp"; + patchPhase = "sed -e /mkinstalldirs.*localstatedir/d -i bus/Makefile.in"; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 42c7ac59dcc9..5b93f83d1b28 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -1466,8 +1466,20 @@ rec { inherit fetchurl stdenv; }; - dbus = import ../development/libraries/dbus { + # I think, this is a bad practice to use getVersion for various build + # variants, but it's 5 o'clock now... + dbus = getVersion "dbus" dbus_alts; + + dbus_alts = rec + { + noX11 = import ../development/libraries/dbus { inherit fetchurl stdenv pkgconfig expat; + }; + withX11 = import ../development/libraries/dbus_x { + inherit fetchurl stdenv pkgconfig expat; + inherit (xlibs) libX11 libICE libSM; + }; + default = noX11; }; dbus_glib = import ../development/libraries/dbus-glib {