summary refs log tree commit diff
path: root/pkgs/desktops/gnome-2/bindings/gnome-python/default.nix
blob: ed794715ff8d9d328af421b9ec71097519973bfa (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
{ stdenv, fetchurl, python, pkgconfig, libgnome, GConf, pygobject, pygtk, glib, gtk, pythonDBus}:

with stdenv.lib;

stdenv.mkDerivation rec {
  version = "2.28";
  name = "gnome-python-${version}.1";

  src = fetchurl {
    url = "mirror://gnome/sources/gnome-python/${version}/${name}.tar.bz2";
    sha256 = "759ce9344cbf89cf7f8449d945822a0c9f317a494f56787782a901e4119b96d8";
  };

  phases = "unpackPhase configurePhase buildPhase installPhase";

  # WAF is probably the biggest crap on this planet, btw i removed the /gtk-2.0 path thingy
  configurePhase = ''
    sed -e "s@{PYTHONDIR}/gtk-2.0@{PYTHONDIR}/@" -i gconf/wscript
    python waf configure --prefix=$out
  '';

  buildPhase = ''
    python waf build
  '';

  installPhase = ''
    python waf install
    cp bonobo/*.{py,defs} $out/share/pygtk/2.0/defs/
  '';

  buildInputs = [ python pkgconfig pygobject pygtk glib gtk GConf libgnome pythonDBus ];

  doCheck = false;

  meta = {
    homepage = "http://projects.gnome.org/gconf/";
    description = "Python wrapper for gconf";
    maintainers = [ stdenv.lib.maintainers.qknight ];
  };
}