about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/pygtksourceview
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/pygtksourceview')
-rw-r--r--nixpkgs/pkgs/development/python-modules/pygtksourceview/codegendir.patch25
-rw-r--r--nixpkgs/pkgs/development/python-modules/pygtksourceview/default.nix22
2 files changed, 47 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/pygtksourceview/codegendir.patch b/nixpkgs/pkgs/development/python-modules/pygtksourceview/codegendir.patch
new file mode 100644
index 000000000000..783c5e2d4671
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/pygtksourceview/codegendir.patch
@@ -0,0 +1,25 @@
+diff -Nur pygtksourceview-2.10.1-orig/configure pygtksourceview-2.10.1/configure
+--- pygtksourceview-2.10.1-orig/configure	2010-04-18 15:29:55.000000000 +0200
++++ pygtksourceview-2.10.1/configure	2015-01-30 20:36:31.784541887 +0100
+@@ -12950,7 +12950,7 @@
+ 
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pygtk codegen" >&5
+ $as_echo_n "checking for pygtk codegen... " >&6; }
+-CODEGENDIR=`$PKG_CONFIG --variable=codegendir pygtk-2.0`
++CODEGENDIR=`$PKG_CONFIG --variable=codegendir pygobject-2.0`
+ echo $CODEGENDIR
+ if test -f $CODEGENDIR/codegen.py; then
+ 	CODEGEN=$CODEGENDIR/codegen.py
+diff -Nur pygtksourceview-2.10.1-orig/configure.ac pygtksourceview-2.10.1/configure.ac
+--- pygtksourceview-2.10.1-orig/configure.ac	2010-04-18 15:28:39.000000000 +0200
++++ pygtksourceview-2.10.1/configure.ac	2015-01-30 20:36:42.781648830 +0100
+@@ -116,7 +116,7 @@
+ 
+ dnl codegen
+ AC_MSG_CHECKING(for pygtk codegen)
+-CODEGENDIR=`$PKG_CONFIG --variable=codegendir pygtk-2.0`
++CODEGENDIR=`$PKG_CONFIG --variable=codegendir pygobject-2.0`
+ echo $CODEGENDIR
+ if test -f $CODEGENDIR/codegen.py; then
+ 	CODEGEN=$CODEGENDIR/codegen.py
+
diff --git a/nixpkgs/pkgs/development/python-modules/pygtksourceview/default.nix b/nixpkgs/pkgs/development/python-modules/pygtksourceview/default.nix
new file mode 100644
index 000000000000..a03be0ac04df
--- /dev/null
+++ b/nixpkgs/pkgs/development/python-modules/pygtksourceview/default.nix
@@ -0,0 +1,22 @@
+{ lib, fetchurl, python, buildPythonPackage, pkgconfig, pygobject2, glib, pygtk, gnome2 }:
+
+buildPythonPackage rec {
+  pname = "pygtksourceview";
+  format = "other";
+  version = "2.10.1";
+  name = pname + "-" + version;
+
+  src = fetchurl {
+    url = "http://ftp.gnome.org/pub/gnome/sources/pygtksourceview/2.10/pygtksourceview-${version}.tar.bz2";
+    sha256 = "0x2r9k547ad68sfddr5am341ap6zvy8k0rh3rd0n38k7xdd7rd5l";
+  };
+
+  patches = [ ./codegendir.patch ];
+
+  nativeBuildInputs = [ pkgconfig ];
+  buildInputs = [ python pygobject2 glib pygtk gnome2.gtksourceview ];
+
+  meta = {
+    platforms = lib.platforms.unix;
+  };
+}