3
0
Fork 0
forked from mirrors/nixpkgs

gnome2.gnome_python: use standard build system

This commit is contained in:
Nikolay Amiantov 2016-12-21 00:36:41 +03:00
parent 800020446e
commit c22b243b3b

View file

@ -1,9 +1,9 @@
{ stdenv, fetchurl, pythonPackages, pkgconfig, libgnome, GConf, glib, gtk, gnome_vfs}:
{ stdenv, fetchurl, python2, pkgconfig, libgnome, GConf, glib, gtk, gnome_vfs }:
with stdenv.lib;
let
inherit (pythonPackages) python pygobject2 pygtk dbus-python;
inherit (python2.pkgs) python pygobject2 pygtk dbus-python;
in stdenv.mkDerivation rec {
version = "2.28";
name = "gnome-python-${version}.1";
@ -13,30 +13,21 @@ in stdenv.mkDerivation rec {
sha256 = "759ce9344cbf89cf7f8449d945822a0c9f317a494f56787782a901e4119b96d8";
};
phases = "unpackPhase configurePhase buildPhase installPhase";
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ python glib gtk GConf libgnome gnome_vfs ];
propagatedBuildInputs = [ pygobject2 pygtk dbus-python ];
# 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
# gnome-python expects that .pth file is already installed by PyGTK in the
# same directory. This is not the case for Nix.
postInstall = ''
echo "gtk-2.0" > $out/${python2.sitePackages}/${name}.pth
'';
buildPhase = ''
python waf build
'';
installPhase = ''
python waf install
cp bonobo/*.{py,defs} $out/share/pygtk/2.0/defs/
'';
buildInputs = [ python pkgconfig pygobject2 pygtk glib gtk GConf libgnome dbus-python gnome_vfs ];
doCheck = false;
meta = {
homepage = "http://projects.gnome.org/gconf/";
description = "Python wrapper for gconf";
maintainers = [ stdenv.lib.maintainers.qknight ];
meta = with stdenv.lib; {
homepage = "http://pygtk.org/";
description = "Python wrapper for GNOME libraries";
platforms = platforms.linux;
licenses = licenses.lgpl2;
maintainers = with maintainers; [ qknight ];
};
}