[dev-python/pygobject*] drop older releases
This commit is contained in:
@@ -1,6 +1 @@
|
||||
DIST pygobject-3.0.4.tar.xz 547180 SHA256 f457b1d7f6b8bfa727593c3696d2b405da66b4a8d34cd7d3362ebda1221f0661
|
||||
DIST pygobject-3.2.0.tar.xz 561820 SHA256 1a2140c4c4ce0c1a5d7abe74eeb7a7040f426cb17943c3ae7e57695b355151c3 SHA512 f3f381b43efeefee0187da39178d3c51fcf317c5ba7adc3fa95ad6145d84f72ccb006ad6d08fd4aac5b506599f69b47eb3c599d7f99f57ee22e82ae993465199 WHIRLPOOL c0d1eff36cd3b4c1a1ac945a3d82f54112ee4052698e3ec78f5305173f452a0672811c5cc1231e95002462147e5bedea230c379c663601dec8d95cb99ca51e42
|
||||
DIST pygobject-3.2.1.tar.xz 550392 SHA256 0f07401289fa33e8caee7a9342f5c838bb44cd0a386cb99093505edb5e42817a
|
||||
DIST pygobject-3.2.2.tar.xz 564712 SHA256 4653790baaff0176fd814b88cfb5378c45906a120b25d01be2554f423b726eb0 SHA512 b22c8fd4bcff0d110a08d7f0927df086d4e1e11546e3d7aa08f4e5ec66643d1ba88ac199b0354dca145bf06532c8ab8a427ea9450751ee52b914f355a6d7e9e7 WHIRLPOOL f3e4aaafadfeae5e6fafd0e173c856c2f8c937eb097732760c21ccaced6c7c96e36e5b683d729e78b0043302fafa92818ea90fa845fe266caf5e2d0a8ae8ff8f
|
||||
DIST pygobject-3.4.2.tar.xz 615032 SHA256 2b87ef3170be3a20a53fbdb348ae4ecb41a72a17ec6531baa67147c3437d2aad SHA512 ff22d2825896246564230949b93e6d6075f885cbe4c633b8fdd6505287bc167dd50d3c3a3f4ed9ff690c0b70a81fb893a9fbf947ed9ff043ad61a61af192412d WHIRLPOOL df50588c9da9b56b50370530b1b70a10addc1d89e44ede7efbbcc7e9039e35816c105477c9e33caa52bbae9d6bd33b6532e6a0b8df3b8de0aab6f838bf00a10f
|
||||
DIST pygobject-3.8.2.tar.xz 654092 SHA256 caa6507edb8cca56e781bf927d88ce99581e1df9978b59a3360cfb74bd9c15f5 SHA512 63295e2f5dd2cc6a8909f68884b7e9e055344f4ab341e310c54c90151aa54cb902e0f80c1522ec5227ad4dd33b236ecf75e0ab5a9334cb62a85070f5a51be608 WHIRLPOOL e445afd80e858dd8e698faf631fdbd04e9741dd7d5720ca6d57bee099b557a902e4da23caf44117ec24a4cb071b38e23c35b6dba4bfd7fe545f1f199babd4b97
|
||||
|
||||
@@ -1,72 +0,0 @@
|
||||
From b5c4b8b97a1ccb9a4c63ab726ea9c84d81ef51ca Mon Sep 17 00:00:00 2001
|
||||
From: Gilles Dartiguelongue <eva@gentoo.org>
|
||||
Date: Fri, 5 Nov 2010 23:39:08 +0100
|
||||
Subject: [PATCH 2/3] Do not build tests unless needed
|
||||
|
||||
[Alexandre Rostovtsev <tetromino@gmail.com>: port to 2.90.1]
|
||||
---
|
||||
tests/Makefile.am | 10 ++++------
|
||||
tests/runtests.py | 3 +++
|
||||
2 files changed, 7 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/tests/Makefile.am b/tests/Makefile.am
|
||||
index 4ec6477..c52cb9d 100644
|
||||
--- a/tests/Makefile.am
|
||||
+++ b/tests/Makefile.am
|
||||
@@ -1,5 +1,5 @@
|
||||
CLEANFILES =
|
||||
-noinst_LTLIBRARIES = libregress.la libgimarshallingtests.la
|
||||
+check_LTLIBRARIES = libregress.la libgimarshallingtests.la
|
||||
|
||||
nodist_libregress_la_SOURCES = $(GI_DATADIR)/tests/regress.c $(GI_DATADIR)/tests/regress.h
|
||||
libregress_la_CFLAGS = $(GIO_CFLAGS) $(PYCAIRO_CFLAGS)
|
||||
@@ -43,7 +43,7 @@ gschemas.compiled: org.gnome.test.gschema.xml
|
||||
|
||||
CLEANFILES += Regress-1.0.gir Regress-1.0.typelib GIMarshallingTests-1.0.gir GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
|
||||
-noinst_LTLIBRARIES += testhelper.la
|
||||
+check_LTLIBRARIES += testhelper.la
|
||||
|
||||
testhelper_la_CFLAGS = -I$(top_srcdir)/gi/_gobject -I$(top_srcdir)/gi/_glib $(PYTHON_INCLUDES) $(GLIB_CFLAGS)
|
||||
testhelper_la_LDFLAGS = -module -avoid-version
|
||||
@@ -63,8 +63,6 @@ testhelper.la: $(testhelper_la_OBJECTS) $(testhelper_la_DEPENDENCIES)
|
||||
test -L $@ || $(LN_S) .libs/$@ $@
|
||||
|
||||
|
||||
-all: $(LTLIBRARIES:.la=.so)
|
||||
-
|
||||
TEST_FILES_STATIC = \
|
||||
test_gobject.py \
|
||||
test_interface.py \
|
||||
@@ -97,7 +95,7 @@ EXTRA_DIST = \
|
||||
EXTRA_DIST += $(TEST_FILES_STATIC) $(TEST_FILES_GI)
|
||||
|
||||
clean-local:
|
||||
- rm -f $(LTLIBRARIES:.la=.so) file.txt~
|
||||
+ rm -f $(check_LTLIBRARIES:.la=.so) file.txt~
|
||||
|
||||
DBUS_LAUNCH=$(shell which dbus-launch)
|
||||
RUN_TESTS_ENV_VARS= \
|
||||
@@ -108,7 +106,7 @@ RUN_TESTS_ENV_VARS= \
|
||||
TESTS_BUILDDIR=$(builddir)
|
||||
RUN_TESTS_LAUNCH=$(RUN_TESTS_ENV_VARS) $(DBUS_LAUNCH) $(EXEC_NAME) $(PYTHON) $(srcdir)/runtests.py
|
||||
|
||||
-check-local: $(LTLIBRARIES:.la=.so) Regress-1.0.typelib GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
+check-local: $(check_LTLIBRARIES:.la=.so) Regress-1.0.typelib GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
TEST_FILES="$(TEST_FILES_STATIC)" $(RUN_TESTS_LAUNCH)
|
||||
TEST_FILES="$(TEST_FILES_GI)" $(RUN_TESTS_LAUNCH)
|
||||
|
||||
diff --git a/tests/runtests.py b/tests/runtests.py
|
||||
index 2a8ecf4..dc9fb03 100755
|
||||
--- a/tests/runtests.py
|
||||
+++ b/tests/runtests.py
|
||||
@@ -7,6 +7,9 @@ import sys
|
||||
|
||||
import unittest
|
||||
|
||||
+# Some tests fail with translated messages.
|
||||
+os.environ["LC_ALL"] = "C"
|
||||
+
|
||||
if '--help' in sys.argv:
|
||||
print("Usage: ./runtests.py <testfiles>")
|
||||
sys.exit(0)
|
||||
-85
@@ -1,85 +0,0 @@
|
||||
From 228ce7f0f99d2f5fa7d4ac86784d4e81032f9a3a Mon Sep 17 00:00:00 2001
|
||||
From: Gilles Dartiguelongue <eva@gentoo.org>
|
||||
Date: Fri, 8 Apr 2011 15:43:39 +0200
|
||||
Subject: [PATCH 2/3] Enable support to build against multiple version of
|
||||
python
|
||||
|
||||
---
|
||||
gi/Makefile.am | 2 +-
|
||||
gi/_glib/Makefile.am | 14 +++++++-------
|
||||
gi/_gobject/Makefile.am | 2 +-
|
||||
3 files changed, 9 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/gi/Makefile.am b/gi/Makefile.am
|
||||
index 0584cc9..9abb61d 100644
|
||||
--- a/gi/Makefile.am
|
||||
+++ b/gi/Makefile.am
|
||||
@@ -83,7 +83,7 @@ _gi_la_CPPFLAGS = \
|
||||
_gi_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(GI_LIBS) \
|
||||
- $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+ $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
_gi_la_LDFLAGS = \
|
||||
$(extension_ldflags) \
|
||||
-export-symbols-regex "init_gi|PyInit__gi"
|
||||
diff --git a/gi/_glib/Makefile.am b/gi/_glib/Makefile.am
|
||||
index 3cf2593..eaa0ce9 100644
|
||||
--- a/gi/_glib/Makefile.am
|
||||
+++ b/gi/_glib/Makefile.am
|
||||
@@ -27,24 +27,24 @@ pyglib_PYTHON = \
|
||||
__init__.py \
|
||||
option.py
|
||||
|
||||
-lib_LTLIBRARIES = libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+lib_LTLIBRARIES = libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_SOURCES = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_SOURCES = \
|
||||
pyglib.c \
|
||||
pyglib.h \
|
||||
pyglib-private.h \
|
||||
pyglib-python-compat.h
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_CPPFLAGS = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_CPPFLAGS = \
|
||||
$(extension_cppflags)
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_CFLAGS = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_CFLAGS = \
|
||||
$(GLIB_CFLAGS)
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_LIBADD = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(FFI_LIBS) \
|
||||
$(GLIB_LIBS)
|
||||
|
||||
if OS_WIN32
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_LDFLAGS = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_LDFLAGS = \
|
||||
-no-undefined
|
||||
endif
|
||||
|
||||
@@ -73,7 +73,7 @@ _glib_la_CPPFLAGS = \
|
||||
_glib_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(GLIB_LIBS) \
|
||||
- libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+ libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
_glib_la_LDFLAGS = \
|
||||
$(extension_ldflags) \
|
||||
-export-symbols-regex "_glib|PyInit__glib"
|
||||
diff --git a/gi/_gobject/Makefile.am b/gi/_gobject/Makefile.am
|
||||
index 6bddcf7..023907f 100644
|
||||
--- a/gi/_gobject/Makefile.am
|
||||
+++ b/gi/_gobject/Makefile.am
|
||||
@@ -65,7 +65,7 @@ _gobject_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(GLIB_LIBS) \
|
||||
$(FFI_LIBS) \
|
||||
- $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+ $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
_gobject_la_LDFLAGS = \
|
||||
$(extension_ldflags) \
|
||||
-export-symbols-regex "_gobject|PyInit__gobject"
|
||||
--
|
||||
1.7.6.1
|
||||
|
||||
@@ -1,29 +0,0 @@
|
||||
Disable tests requiring an unreleased version of gobject-introspection.
|
||||
|
||||
diff --git a/tests/test_everything.py b/tests/test_everything.py
|
||||
index 19d345b..4a03890 100644
|
||||
--- a/tests/test_everything.py
|
||||
+++ b/tests/test_everything.py
|
||||
@@ -483,22 +483,3 @@ class TestAdvancedInterfaces(unittest.TestCase):
|
||||
self.assertEquals(ret[0], 51);
|
||||
self.assertEquals(ret[1], 61);
|
||||
self.assertEquals(ret[2], 32);
|
||||
-
|
||||
- def test_obj_skip_return_val_no_out(self):
|
||||
- obj = Everything.TestObj();
|
||||
- # raises an error for 0, succeeds for any other value
|
||||
- self.assertRaises(GLib.GError, obj.skip_return_val_no_out, 0)
|
||||
-
|
||||
- ret = obj.skip_return_val_no_out(1)
|
||||
- self.assertEquals(ret, None)
|
||||
-
|
||||
-class TestSignals(unittest.TestCase):
|
||||
- def test_object_param_signal(self):
|
||||
- obj = Everything.TestObj();
|
||||
-
|
||||
- def callback (obj_param):
|
||||
- self.assertEquals(obj_param.props.int, 3)
|
||||
- self.assertEquals(obj_param.__grefcount__, 2)
|
||||
-
|
||||
- obj.connect('sig-with-obj', callback)
|
||||
- obj.emit_sig_with_obj()
|
||||
@@ -1,69 +0,0 @@
|
||||
Disable tests requiring >=gobject-introspection-1.31
|
||||
|
||||
diff --git a/tests/test_everything.py b/tests/test_everything.py
|
||||
index 43735e5..ecfdef4 100644
|
||||
--- a/tests/test_everything.py
|
||||
+++ b/tests/test_everything.py
|
||||
@@ -507,22 +507,3 @@ class TestAdvancedInterfaces(unittest.TestCase):
|
||||
self.assertEquals(ret[0], 51);
|
||||
self.assertEquals(ret[1], 61);
|
||||
self.assertEquals(ret[2], 32);
|
||||
-
|
||||
- def test_obj_skip_return_val_no_out(self):
|
||||
- obj = Everything.TestObj();
|
||||
- # raises an error for 0, succeeds for any other value
|
||||
- self.assertRaises(GLib.GError, obj.skip_return_val_no_out, 0)
|
||||
-
|
||||
- ret = obj.skip_return_val_no_out(1)
|
||||
- self.assertEquals(ret, None)
|
||||
-
|
||||
-class TestSignals(unittest.TestCase):
|
||||
- def test_object_param_signal(self):
|
||||
- obj = Everything.TestObj();
|
||||
-
|
||||
- def callback (obj_param):
|
||||
- self.assertEquals(obj_param.props.int, 3)
|
||||
- self.assertEquals(obj_param.__grefcount__, 2)
|
||||
-
|
||||
- obj.connect('sig-with-obj', callback)
|
||||
- obj.emit_sig_with_obj()
|
||||
diff --git a/tests/test_gi.py b/tests/test_gi.py
|
||||
index 0a9b1b2..7e24778 100644
|
||||
--- a/tests/test_gi.py
|
||||
+++ b/tests/test_gi.py
|
||||
@@ -770,18 +770,6 @@ class TestArray(unittest.TestCase):
|
||||
def test_gstrv_inout(self):
|
||||
self.assertEquals(['-1', '0', '1', '2'], GIMarshallingTests.gstrv_inout(['0', '1', '2']))
|
||||
|
||||
- def test_array_gvariant_none_in(self):
|
||||
- v = [GLib.Variant("i", 27), GLib.Variant("s", "Hello")]
|
||||
- self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
-
|
||||
- def test_array_gvariant_container_in(self):
|
||||
- v = [GLib.Variant("i", 27), GLib.Variant("s", "Hello")]
|
||||
- self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
-
|
||||
- def test_array_gvariant_full_in(self):
|
||||
- v = [GLib.Variant("i", 27), GLib.Variant("s", "Hello")]
|
||||
- self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
-
|
||||
def test_bytearray_gvariant(self):
|
||||
v = GLib.Variant.new_bytestring("foo")
|
||||
self.assertEquals(v.get_bytestring(), "foo")
|
||||
@@ -1651,16 +1639,6 @@ class TestPythonGObject(unittest.TestCase):
|
||||
def do_method_not_a_vfunc(self):
|
||||
pass
|
||||
|
||||
- def test_subsubobject(self):
|
||||
- class SubSubSubObject(GIMarshallingTests.SubSubObject):
|
||||
- def do_method_deep_hierarchy(self, num):
|
||||
- self.props.int = num * 2
|
||||
-
|
||||
- sub_sub_sub_object = SubSubSubObject()
|
||||
- GIMarshallingTests.SubSubObject.do_method_deep_hierarchy(sub_sub_sub_object, 5)
|
||||
- self.assertEqual(sub_sub_sub_object.props.int, 5)
|
||||
-
|
||||
-
|
||||
class TestMultiOutputArgs(unittest.TestCase):
|
||||
|
||||
def test_int_out_out(self):
|
||||
@@ -1,70 +0,0 @@
|
||||
From 00030bc6f0fb961c716ed692144cd8e4bb9be7d0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Sebastian=20P=C3=B6lsterl?= <sebp@k-d-w.org>
|
||||
Date: Sat, 10 Dec 2011 12:51:45 +0100
|
||||
Subject: [PATCH] Fixed bug where GObject.property did not respect minimum and
|
||||
maximum values
|
||||
|
||||
https://bugzilla.gnome.org/show_bug.cgi?id=664864
|
||||
---
|
||||
gi/_gobject/propertyhelper.py | 2 +-
|
||||
tests/test_properties.py | 31 +++++++++++++++++++++++++++++++
|
||||
2 files changed, 32 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/gi/_gobject/propertyhelper.py b/gi/_gobject/propertyhelper.py
|
||||
index 4635350..9208a0b 100644
|
||||
--- a/gi/_gobject/propertyhelper.py
|
||||
+++ b/gi/_gobject/propertyhelper.py
|
||||
@@ -298,7 +298,7 @@ class property(object):
|
||||
ptype = self.type
|
||||
if ptype in [TYPE_INT, TYPE_UINT, TYPE_LONG, TYPE_ULONG,
|
||||
TYPE_INT64, TYPE_UINT64, TYPE_FLOAT, TYPE_DOUBLE]:
|
||||
- args = self._get_minimum(), self._get_maximum(), self.default
|
||||
+ args = self.minimum, self.maximum, self.default
|
||||
elif (ptype == TYPE_STRING or ptype == TYPE_BOOLEAN or
|
||||
ptype.is_a(TYPE_ENUM)):
|
||||
args = (self.default,)
|
||||
diff --git a/tests/test_properties.py b/tests/test_properties.py
|
||||
index 3521647..75aacff 100644
|
||||
--- a/tests/test_properties.py
|
||||
+++ b/tests/test_properties.py
|
||||
@@ -367,6 +367,37 @@ class TestProperty(unittest.TestCase):
|
||||
GObject.property, type=gtype, minimum=min,
|
||||
maximum=max+1)
|
||||
|
||||
+ def testMinMax(self):
|
||||
+ class C(GObject.GObject):
|
||||
+ prop_int = GObject.property(type=int, minimum=1, maximum=100, default=1)
|
||||
+ prop_float = GObject.property(type=float, minimum=0.1, maximum=10.5, default=1.1)
|
||||
+
|
||||
+ def __init__(self):
|
||||
+ GObject.GObject.__init__(self)
|
||||
+
|
||||
+ o = C()
|
||||
+ self.assertEqual(o.prop_int, 1)
|
||||
+
|
||||
+ o.prop_int = 5
|
||||
+ self.assertEqual(o.prop_int, 5)
|
||||
+
|
||||
+ o.prop_int = 0
|
||||
+ self.assertEqual(o.prop_int, 5)
|
||||
+
|
||||
+ o.prop_int = 101
|
||||
+ self.assertEqual(o.prop_int, 5)
|
||||
+
|
||||
+ self.assertEqual(o.prop_float, 1.1)
|
||||
+
|
||||
+ o.prop_float = 7.75
|
||||
+ self.assertEqual(o.prop_float, 7.75)
|
||||
+
|
||||
+ o.prop_float = 0.09
|
||||
+ self.assertEqual(o.prop_float, 7.75)
|
||||
+
|
||||
+ o.prop_float = 10.51
|
||||
+ self.assertEqual(o.prop_float, 7.75)
|
||||
+
|
||||
def testMultipleInstances(self):
|
||||
class C(GObject.GObject):
|
||||
prop = GObject.property(type=str, default='default')
|
||||
--
|
||||
1.7.8.1
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
From 8d88283688797b8fc70a7cbccd42a71b8518098d Mon Sep 17 00:00:00 2001
|
||||
From: Alexandre Rostovtsev <tetromino@gentoo.org>
|
||||
Date: Mon, 26 Dec 2011 00:44:56 -0500
|
||||
Subject: [PATCH] Fix bytearray test compatibility with python3
|
||||
|
||||
https://bugs.gentoo.org/show_bug.cgi?id=321879
|
||||
---
|
||||
tests/test_gi.py | 4 ++--
|
||||
1 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/tests/test_gi.py b/tests/test_gi.py
|
||||
index 0a9b1b2..8726187 100644
|
||||
--- a/tests/test_gi.py
|
||||
+++ b/tests/test_gi.py
|
||||
@@ -783,8 +783,8 @@ class TestArray(unittest.TestCase):
|
||||
self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
|
||||
def test_bytearray_gvariant(self):
|
||||
- v = GLib.Variant.new_bytestring("foo")
|
||||
- self.assertEquals(v.get_bytestring(), "foo")
|
||||
+ v = GLib.Variant.new_bytestring(b"foo")
|
||||
+ self.assertEquals(v.get_bytestring(), b"foo")
|
||||
|
||||
class TestGArray(unittest.TestCase):
|
||||
|
||||
--
|
||||
1.7.8.1
|
||||
|
||||
@@ -1,84 +0,0 @@
|
||||
From d0885d5757f02f53dbc8036054a1ced7f727eb08 Mon Sep 17 00:00:00 2001
|
||||
From: Gilles Dartiguelongue <eva@gentoo.org>
|
||||
Date: Fri, 5 Nov 2010 23:39:08 +0100
|
||||
Subject: [PATCH] Do not build tests unless needed
|
||||
|
||||
[Alexandre Rostovtsev <tetromino@gmail.com>: port to 2.90.1]
|
||||
---
|
||||
tests/Makefile.am | 12 ++++++------
|
||||
tests/runtests.py | 3 +++
|
||||
2 files changed, 9 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/tests/Makefile.am b/tests/Makefile.am
|
||||
index 7a619bf..a3cbf57 100644
|
||||
--- a/tests/Makefile.am
|
||||
+++ b/tests/Makefile.am
|
||||
@@ -1,5 +1,5 @@
|
||||
CLEANFILES =
|
||||
-noinst_LTLIBRARIES = libgimarshallingtests.la
|
||||
+check_LTLIBRARIES = libgimarshallingtests.la
|
||||
test_typelibs = GIMarshallingTests-1.0.typelib
|
||||
|
||||
nodist_libgimarshallingtests_la_SOURCES = $(GI_DATADIR)/tests/gimarshallingtests.c $(GI_DATADIR)/tests/gimarshallingtests.h
|
||||
@@ -23,7 +23,7 @@ GIMarshallingTests-1.0.typelib: GIMarshallingTests-1.0.gir Makefile
|
||||
|
||||
# regress.c needs cairo
|
||||
if ENABLE_CAIRO
|
||||
-noinst_LTLIBRARIES += libregress.la
|
||||
+check_LTLIBRARIES += libregress.la
|
||||
test_typelibs += Regress-1.0.typelib
|
||||
nodist_libregress_la_SOURCES = $(GI_DATADIR)/tests/regress.c $(GI_DATADIR)/tests/regress.h
|
||||
libregress_la_CFLAGS = $(GIO_CFLAGS) $(CAIRO_CFLAGS)
|
||||
@@ -52,7 +52,7 @@ gschemas.compiled: org.gnome.test.gschema.xml
|
||||
|
||||
CLEANFILES += Regress-1.0.gir Regress-1.0.typelib GIMarshallingTests-1.0.gir GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
|
||||
-noinst_LTLIBRARIES += testhelper.la
|
||||
+check_LTLIBRARIES += testhelper.la
|
||||
|
||||
testhelper_la_CFLAGS = -I$(top_srcdir)/gi/_gobject -I$(top_srcdir)/gi/_glib $(PYTHON_INCLUDES) $(GLIB_CFLAGS)
|
||||
testhelper_la_LDFLAGS = -module -avoid-version
|
||||
@@ -72,7 +72,7 @@ testhelper.la: $(testhelper_la_OBJECTS) $(testhelper_la_DEPENDENCIES)
|
||||
test -L $@ || $(LN_S) .libs/$@ $@
|
||||
|
||||
|
||||
-all: $(LTLIBRARIES:.la=.so)
|
||||
+all: $(check_LTLIBRARIES:.la=.so)
|
||||
|
||||
EXTRA_DIST = \
|
||||
compathelper.py \
|
||||
@@ -112,7 +112,7 @@ EXTRA_DIST = \
|
||||
$(NULL)
|
||||
|
||||
clean-local:
|
||||
- rm -f $(LTLIBRARIES:.la=.so) file.txt~
|
||||
+ rm -f $(check_LTLIBRARIES:.la=.so) file.txt~
|
||||
|
||||
DBUS_LAUNCH=$(shell which dbus-launch)
|
||||
RUN_TESTS_ENV_VARS= \
|
||||
@@ -123,7 +123,7 @@ RUN_TESTS_ENV_VARS= \
|
||||
MALLOC_PERTURB_=85 \
|
||||
TESTS_BUILDDIR=$(builddir)
|
||||
|
||||
-check-local: $(LTLIBRARIES:.la=.so) $(test_typelibs) gschemas.compiled
|
||||
+check-local: $(check_LTLIBRARIES:.la=.so) $(test_typelibs) gschemas.compiled
|
||||
@echo " CHECK Pyflakes"
|
||||
@if type pyflakes >/dev/null 2>&1; then pyflakes $(top_srcdir); else echo "skipped, pyflakes not installed"; fi
|
||||
@echo " CHECK PEP8"
|
||||
diff --git a/tests/runtests.py b/tests/runtests.py
|
||||
index c518fcc..35bb5c4 100755
|
||||
--- a/tests/runtests.py
|
||||
+++ b/tests/runtests.py
|
||||
@@ -34,6 +34,9 @@ if sys.version_info[:2] == (2, 6):
|
||||
unittest.TestCase.assertGreater = assertGreater
|
||||
unittest.TestCase.assertIsInstance = assertIsInstance
|
||||
|
||||
+# Some tests fail with translated messages.
|
||||
+os.environ["LC_ALL"] = "C"
|
||||
+
|
||||
if '--help' in sys.argv:
|
||||
print("Usage: ./runtests.py <testfiles>")
|
||||
sys.exit(0)
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
@@ -1,124 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-base}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
# XXX: Is the alternatives stuff needed anymore?
|
||||
inherit alternatives autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND=">=dev-libs/glib-2.24.0:2
|
||||
>=dev-libs/gobject-introspection-1.29
|
||||
virtual/libffi"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
test? (
|
||||
media-fonts/font-cursor-misc
|
||||
media-fonts/font-misc-misc
|
||||
>=dev-libs/gobject-introspection-1.29.17 )
|
||||
>=dev-util/pkgconfig-0.12"
|
||||
# docs disabled for now per upstream default since they are very out of date
|
||||
# doc? (
|
||||
# app-text/docbook-xml-dtd:4.1.2
|
||||
# dev-libs/libxslt
|
||||
# >=app-text/docbook-xsl-stylesheets-1.70.1 )
|
||||
|
||||
# We now disable introspection support in slot 2 per upstream recommendation
|
||||
# (see https://bugzilla.gnome.org/show_bug.cgi?id=642048#c9); however,
|
||||
# older versions of slot 2 installed their own site-packages/gi, and
|
||||
# slot 3 will collide with them.
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
DOCS="AUTHORS ChangeLog* NEWS README"
|
||||
# Hard-enable libffi support since both gobject-introspection and
|
||||
# glib-2.29.x rdepend on it anyway
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--disable-cairo
|
||||
$(use_enable threads thread)"
|
||||
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/${REAL_PN}-2.90.1-make_check.patch"
|
||||
|
||||
# Support installation for multiple Python versions, upstream bug #648292
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.0.0-support_multiple_python_versions.patch"
|
||||
|
||||
# Disable tests that fail
|
||||
#epatch "${FILESDIR}/${REAL_PN}-2.28.3-disable-failing-tests.patch"
|
||||
|
||||
# FIXME: disable tests that require >=gobject-introspection-1.31
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.0.3-disable-new-gi-tests.patch"
|
||||
|
||||
# https://bugzilla.gnome.org/show_bug.cgi?id=666852
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.0.3-tests-python3.patch"
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
# FIXME: With python multiple ABI support, tests return 1 even when they pass
|
||||
src_test() {
|
||||
unset DBUS_SESSION_BUS_ADDRESS
|
||||
export GIO_USE_VFS="local" # prevents odd issues with deleting ${T}/.gvfs
|
||||
|
||||
testing() {
|
||||
export XDG_CACHE_HOME="${T}/$(PYTHON --ABI)"
|
||||
Xemake check PYTHON=$(PYTHON -a)
|
||||
unset XDG_CACHE_HOME
|
||||
}
|
||||
python_execute_function -s testing
|
||||
unset GIO_USE_VFS
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}
|
||||
doins -r examples
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,114 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-base}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND=">=dev-libs/glib-2.31.0:2
|
||||
>=dev-libs/gobject-introspection-1.31.20
|
||||
virtual/libffi"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
test? (
|
||||
media-fonts/font-cursor-misc
|
||||
media-fonts/font-misc-misc
|
||||
>=dev-libs/gobject-introspection-1.29.17 )
|
||||
>=dev-util/pkgconfig-0.12"
|
||||
# docs disabled for now per upstream default since they are very out of date
|
||||
# doc? (
|
||||
# app-text/docbook-xml-dtd:4.1.2
|
||||
# dev-libs/libxslt
|
||||
# >=app-text/docbook-xsl-stylesheets-1.70.1 )
|
||||
|
||||
# We now disable introspection support in slot 2 per upstream recommendation
|
||||
# (see https://bugzilla.gnome.org/show_bug.cgi?id=642048#c9); however,
|
||||
# older versions of slot 2 installed their own site-packages/gi, and
|
||||
# slot 3 will collide with them.
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
DOCS="AUTHORS ChangeLog* NEWS README"
|
||||
# Hard-enable libffi support since both gobject-introspection and
|
||||
# glib-2.29.x rdepend on it anyway
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--disable-cairo
|
||||
$(use_enable threads thread)"
|
||||
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/pygobject-2.90.1-make_check.patch"
|
||||
|
||||
# Disable tests that fail
|
||||
#epatch "${FILESDIR}/${PN}-2.28.3-disable-failing-tests.patch
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
# FIXME: With python multiple ABI support, tests return 1 even when they pass
|
||||
src_test() {
|
||||
unset DBUS_SESSION_BUS_ADDRESS
|
||||
export GIO_USE_VFS="local" # prevents odd issues with deleting ${T}/.gvfs
|
||||
|
||||
testing() {
|
||||
export XDG_CACHE_HOME="${T}/$(PYTHON --ABI)"
|
||||
Xemake check PYTHON=$(PYTHON -a)
|
||||
unset XDG_CACHE_HOME
|
||||
}
|
||||
python_execute_function -s testing
|
||||
unset GIO_USE_VFS
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}
|
||||
doins -r examples
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,114 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-base}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND=">=dev-libs/glib-2.31.0:2
|
||||
>=dev-libs/gobject-introspection-1.31.20
|
||||
virtual/libffi"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
test? (
|
||||
media-fonts/font-cursor-misc
|
||||
media-fonts/font-misc-misc
|
||||
>=dev-libs/gobject-introspection-1.29.17 )
|
||||
>=dev-util/pkgconfig-0.12"
|
||||
# docs disabled for now per upstream default since they are very out of date
|
||||
# doc? (
|
||||
# app-text/docbook-xml-dtd:4.1.2
|
||||
# dev-libs/libxslt
|
||||
# >=app-text/docbook-xsl-stylesheets-1.70.1 )
|
||||
|
||||
# We now disable introspection support in slot 2 per upstream recommendation
|
||||
# (see https://bugzilla.gnome.org/show_bug.cgi?id=642048#c9); however,
|
||||
# older versions of slot 2 installed their own site-packages/gi, and
|
||||
# slot 3 will collide with them.
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
DOCS="AUTHORS ChangeLog* NEWS README"
|
||||
# Hard-enable libffi support since both gobject-introspection and
|
||||
# glib-2.29.x rdepend on it anyway
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--disable-cairo
|
||||
$(use_enable threads thread)"
|
||||
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/pygobject-2.90.1-make_check.patch"
|
||||
|
||||
# Disable tests that fail
|
||||
#epatch "${FILESDIR}/${PN}-2.28.3-disable-failing-tests.patch
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
# FIXME: With python multiple ABI support, tests return 1 even when they pass
|
||||
src_test() {
|
||||
unset DBUS_SESSION_BUS_ADDRESS
|
||||
export GIO_USE_VFS="local" # prevents odd issues with deleting ${T}/.gvfs
|
||||
|
||||
testing() {
|
||||
export XDG_CACHE_HOME="${T}/$(PYTHON --ABI)"
|
||||
Xemake check PYTHON=$(PYTHON -a)
|
||||
unset XDG_CACHE_HOME
|
||||
}
|
||||
python_execute_function -s testing
|
||||
unset GIO_USE_VFS
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}
|
||||
doins -r examples
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,114 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-base}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND=">=dev-libs/glib-2.31.0:2
|
||||
>=dev-libs/gobject-introspection-1.31.20
|
||||
virtual/libffi"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
test? (
|
||||
media-fonts/font-cursor-misc
|
||||
media-fonts/font-misc-misc
|
||||
>=dev-libs/gobject-introspection-1.29.17 )
|
||||
>=dev-util/pkgconfig-0.12"
|
||||
# docs disabled for now per upstream default since they are very out of date
|
||||
# doc? (
|
||||
# app-text/docbook-xml-dtd:4.1.2
|
||||
# dev-libs/libxslt
|
||||
# >=app-text/docbook-xsl-stylesheets-1.70.1 )
|
||||
|
||||
# We now disable introspection support in slot 2 per upstream recommendation
|
||||
# (see https://bugzilla.gnome.org/show_bug.cgi?id=642048#c9); however,
|
||||
# older versions of slot 2 installed their own site-packages/gi, and
|
||||
# slot 3 will collide with them.
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
DOCS="AUTHORS ChangeLog* NEWS README"
|
||||
# Hard-enable libffi support since both gobject-introspection and
|
||||
# glib-2.29.x rdepend on it anyway
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--disable-cairo
|
||||
$(use_enable threads thread)"
|
||||
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/pygobject-2.90.1-make_check.patch"
|
||||
|
||||
# Disable tests that fail
|
||||
#epatch "${FILESDIR}/${PN}-2.28.3-disable-failing-tests.patch
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
# FIXME: With python multiple ABI support, tests return 1 even when they pass
|
||||
src_test() {
|
||||
unset DBUS_SESSION_BUS_ADDRESS
|
||||
export GIO_USE_VFS="local" # prevents odd issues with deleting ${T}/.gvfs
|
||||
|
||||
testing() {
|
||||
export XDG_CACHE_HOME="${T}/$(PYTHON --ABI)"
|
||||
Xemake check PYTHON=$(PYTHON -a)
|
||||
unset XDG_CACHE_HOME
|
||||
}
|
||||
python_execute_function -s testing
|
||||
unset GIO_USE_VFS
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}
|
||||
doins -r examples
|
||||
fi
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,100 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="5"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
PYTHON_COMPAT=( python{2_6,2_7,3_1,3_2,3_3} )
|
||||
|
||||
REAL_PN="${PN/-base}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit autotools eutils gnome2 python-r1 virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1+"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND=">=dev-libs/glib-2.31.0:2
|
||||
>=dev-libs/gobject-introspection-1.34.1.1
|
||||
virtual/libffi:=
|
||||
${PYTHON_DEPS}"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
virtual/pkgconfig
|
||||
test? (
|
||||
dev-libs/atk[introspection]
|
||||
media-fonts/font-cursor-misc
|
||||
media-fonts/font-misc-misc
|
||||
x11-libs/gdk-pixbuf:2[introspection]
|
||||
x11-libs/gtk+:3[introspection]
|
||||
x11-libs/pango[introspection] )"
|
||||
|
||||
# We now disable introspection support in slot 2 per upstream recommendation
|
||||
# (see https://bugzilla.gnome.org/show_bug.cgi?id=642048#c9); however,
|
||||
# older versions of slot 2 installed their own site-packages/gi, and
|
||||
# slot 3 will collide with them.
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
src_prepare() {
|
||||
DOCS="AUTHORS ChangeLog* NEWS README"
|
||||
# Hard-enable libffi support since both gobject-introspection and
|
||||
# glib-2.29.x rdepend on it anyway
|
||||
# docs disabled by upstream default since they are very out of date
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--disable-cairo
|
||||
$(use_enable threads thread)"
|
||||
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.4.1.1-make_check.patch"
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_foreach_impl run_in_build_dir gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_foreach_impl run_in_build_dir gnome2_src_compile
|
||||
}
|
||||
|
||||
# FIXME: With python multiple ABI support, tests return 1 even when they pass
|
||||
src_test() {
|
||||
unset DBUS_SESSION_BUS_ADDRESS
|
||||
export GIO_USE_VFS="local" # prevents odd issues with deleting ${T}/.gvfs
|
||||
|
||||
testing() {
|
||||
export XDG_CACHE_HOME="${T}/${EPYTHON}"
|
||||
run_in_build_dir Xemake check
|
||||
unset XDG_CACHE_HOME
|
||||
}
|
||||
python_foreach_impl testing
|
||||
unset GIO_USE_VFS
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_foreach_impl run_in_build_dir gnome2_src_install
|
||||
|
||||
if use examples; then
|
||||
insinto /usr/share/doc/${PF}
|
||||
doins -r examples
|
||||
fi
|
||||
}
|
||||
|
||||
run_in_build_dir() {
|
||||
pushd "${BUILD_DIR}" > /dev/null || die
|
||||
"$@"
|
||||
popd > /dev/null
|
||||
}
|
||||
@@ -1,6 +1 @@
|
||||
DIST pygobject-3.0.4.tar.xz 547180 SHA256 f457b1d7f6b8bfa727593c3696d2b405da66b4a8d34cd7d3362ebda1221f0661
|
||||
DIST pygobject-3.2.0.tar.xz 561820 SHA256 1a2140c4c4ce0c1a5d7abe74eeb7a7040f426cb17943c3ae7e57695b355151c3 SHA512 f3f381b43efeefee0187da39178d3c51fcf317c5ba7adc3fa95ad6145d84f72ccb006ad6d08fd4aac5b506599f69b47eb3c599d7f99f57ee22e82ae993465199 WHIRLPOOL c0d1eff36cd3b4c1a1ac945a3d82f54112ee4052698e3ec78f5305173f452a0672811c5cc1231e95002462147e5bedea230c379c663601dec8d95cb99ca51e42
|
||||
DIST pygobject-3.2.1.tar.xz 550392 SHA256 0f07401289fa33e8caee7a9342f5c838bb44cd0a386cb99093505edb5e42817a SHA512 84d69b9015044d5cd2919de8a69afa79880bf72cecd923830dc31aa4fe269d6fbe9c79bec5e10a201426667ebfbb625d38cd1016fadbfa93c351aee3a51fdd3f WHIRLPOOL 89c124695206753296d68cc75e7e59a13985160ca37ceb6aed8e6c028a6d0a1787c5af0c1fdc8fa88b7c6a9a43ef08d1c264d7f7eab766936bf35d49b43468e3
|
||||
DIST pygobject-3.2.2.tar.xz 564712 SHA256 4653790baaff0176fd814b88cfb5378c45906a120b25d01be2554f423b726eb0 SHA512 b22c8fd4bcff0d110a08d7f0927df086d4e1e11546e3d7aa08f4e5ec66643d1ba88ac199b0354dca145bf06532c8ab8a427ea9450751ee52b914f355a6d7e9e7 WHIRLPOOL f3e4aaafadfeae5e6fafd0e173c856c2f8c937eb097732760c21ccaced6c7c96e36e5b683d729e78b0043302fafa92818ea90fa845fe266caf5e2d0a8ae8ff8f
|
||||
DIST pygobject-3.4.2.tar.xz 615032 SHA256 2b87ef3170be3a20a53fbdb348ae4ecb41a72a17ec6531baa67147c3437d2aad SHA512 ff22d2825896246564230949b93e6d6075f885cbe4c633b8fdd6505287bc167dd50d3c3a3f4ed9ff690c0b70a81fb893a9fbf947ed9ff043ad61a61af192412d WHIRLPOOL df50588c9da9b56b50370530b1b70a10addc1d89e44ede7efbbcc7e9039e35816c105477c9e33caa52bbae9d6bd33b6532e6a0b8df3b8de0aab6f838bf00a10f
|
||||
DIST pygobject-3.8.2.tar.xz 654092 SHA256 caa6507edb8cca56e781bf927d88ce99581e1df9978b59a3360cfb74bd9c15f5 SHA512 63295e2f5dd2cc6a8909f68884b7e9e055344f4ab341e310c54c90151aa54cb902e0f80c1522ec5227ad4dd33b236ecf75e0ab5a9334cb62a85070f5a51be608 WHIRLPOOL e445afd80e858dd8e698faf631fdbd04e9741dd7d5720ca6d57bee099b557a902e4da23caf44117ec24a4cb071b38e23c35b6dba4bfd7fe545f1f199babd4b97
|
||||
|
||||
@@ -1,72 +0,0 @@
|
||||
From b5c4b8b97a1ccb9a4c63ab726ea9c84d81ef51ca Mon Sep 17 00:00:00 2001
|
||||
From: Gilles Dartiguelongue <eva@gentoo.org>
|
||||
Date: Fri, 5 Nov 2010 23:39:08 +0100
|
||||
Subject: [PATCH 2/3] Do not build tests unless needed
|
||||
|
||||
[Alexandre Rostovtsev <tetromino@gmail.com>: port to 2.90.1]
|
||||
---
|
||||
tests/Makefile.am | 10 ++++------
|
||||
tests/runtests.py | 3 +++
|
||||
2 files changed, 7 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/tests/Makefile.am b/tests/Makefile.am
|
||||
index 4ec6477..c52cb9d 100644
|
||||
--- a/tests/Makefile.am
|
||||
+++ b/tests/Makefile.am
|
||||
@@ -1,5 +1,5 @@
|
||||
CLEANFILES =
|
||||
-noinst_LTLIBRARIES = libregress.la libgimarshallingtests.la
|
||||
+check_LTLIBRARIES = libregress.la libgimarshallingtests.la
|
||||
|
||||
nodist_libregress_la_SOURCES = $(GI_DATADIR)/tests/regress.c $(GI_DATADIR)/tests/regress.h
|
||||
libregress_la_CFLAGS = $(GIO_CFLAGS) $(PYCAIRO_CFLAGS)
|
||||
@@ -43,7 +43,7 @@ gschemas.compiled: org.gnome.test.gschema.xml
|
||||
|
||||
CLEANFILES += Regress-1.0.gir Regress-1.0.typelib GIMarshallingTests-1.0.gir GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
|
||||
-noinst_LTLIBRARIES += testhelper.la
|
||||
+check_LTLIBRARIES += testhelper.la
|
||||
|
||||
testhelper_la_CFLAGS = -I$(top_srcdir)/gi/_gobject -I$(top_srcdir)/gi/_glib $(PYTHON_INCLUDES) $(GLIB_CFLAGS)
|
||||
testhelper_la_LDFLAGS = -module -avoid-version
|
||||
@@ -63,8 +63,6 @@ testhelper.la: $(testhelper_la_OBJECTS) $(testhelper_la_DEPENDENCIES)
|
||||
test -L $@ || $(LN_S) .libs/$@ $@
|
||||
|
||||
|
||||
-all: $(LTLIBRARIES:.la=.so)
|
||||
-
|
||||
TEST_FILES_STATIC = \
|
||||
test_gobject.py \
|
||||
test_interface.py \
|
||||
@@ -97,7 +95,7 @@ EXTRA_DIST = \
|
||||
EXTRA_DIST += $(TEST_FILES_STATIC) $(TEST_FILES_GI)
|
||||
|
||||
clean-local:
|
||||
- rm -f $(LTLIBRARIES:.la=.so) file.txt~
|
||||
+ rm -f $(check_LTLIBRARIES:.la=.so) file.txt~
|
||||
|
||||
DBUS_LAUNCH=$(shell which dbus-launch)
|
||||
RUN_TESTS_ENV_VARS= \
|
||||
@@ -108,7 +106,7 @@ RUN_TESTS_ENV_VARS= \
|
||||
TESTS_BUILDDIR=$(builddir)
|
||||
RUN_TESTS_LAUNCH=$(RUN_TESTS_ENV_VARS) $(DBUS_LAUNCH) $(EXEC_NAME) $(PYTHON) $(srcdir)/runtests.py
|
||||
|
||||
-check-local: $(LTLIBRARIES:.la=.so) Regress-1.0.typelib GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
+check-local: $(check_LTLIBRARIES:.la=.so) Regress-1.0.typelib GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
TEST_FILES="$(TEST_FILES_STATIC)" $(RUN_TESTS_LAUNCH)
|
||||
TEST_FILES="$(TEST_FILES_GI)" $(RUN_TESTS_LAUNCH)
|
||||
|
||||
diff --git a/tests/runtests.py b/tests/runtests.py
|
||||
index 2a8ecf4..dc9fb03 100755
|
||||
--- a/tests/runtests.py
|
||||
+++ b/tests/runtests.py
|
||||
@@ -7,6 +7,9 @@ import sys
|
||||
|
||||
import unittest
|
||||
|
||||
+# Some tests fail with translated messages.
|
||||
+os.environ["LC_ALL"] = "C"
|
||||
+
|
||||
if '--help' in sys.argv:
|
||||
print("Usage: ./runtests.py <testfiles>")
|
||||
sys.exit(0)
|
||||
-85
@@ -1,85 +0,0 @@
|
||||
From 228ce7f0f99d2f5fa7d4ac86784d4e81032f9a3a Mon Sep 17 00:00:00 2001
|
||||
From: Gilles Dartiguelongue <eva@gentoo.org>
|
||||
Date: Fri, 8 Apr 2011 15:43:39 +0200
|
||||
Subject: [PATCH 2/3] Enable support to build against multiple version of
|
||||
python
|
||||
|
||||
---
|
||||
gi/Makefile.am | 2 +-
|
||||
gi/_glib/Makefile.am | 14 +++++++-------
|
||||
gi/_gobject/Makefile.am | 2 +-
|
||||
3 files changed, 9 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/gi/Makefile.am b/gi/Makefile.am
|
||||
index 0584cc9..9abb61d 100644
|
||||
--- a/gi/Makefile.am
|
||||
+++ b/gi/Makefile.am
|
||||
@@ -83,7 +83,7 @@ _gi_la_CPPFLAGS = \
|
||||
_gi_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(GI_LIBS) \
|
||||
- $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+ $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
_gi_la_LDFLAGS = \
|
||||
$(extension_ldflags) \
|
||||
-export-symbols-regex "init_gi|PyInit__gi"
|
||||
diff --git a/gi/_glib/Makefile.am b/gi/_glib/Makefile.am
|
||||
index 3cf2593..eaa0ce9 100644
|
||||
--- a/gi/_glib/Makefile.am
|
||||
+++ b/gi/_glib/Makefile.am
|
||||
@@ -27,24 +27,24 @@ pyglib_PYTHON = \
|
||||
__init__.py \
|
||||
option.py
|
||||
|
||||
-lib_LTLIBRARIES = libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+lib_LTLIBRARIES = libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_SOURCES = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_SOURCES = \
|
||||
pyglib.c \
|
||||
pyglib.h \
|
||||
pyglib-private.h \
|
||||
pyglib-python-compat.h
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_CPPFLAGS = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_CPPFLAGS = \
|
||||
$(extension_cppflags)
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_CFLAGS = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_CFLAGS = \
|
||||
$(GLIB_CFLAGS)
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_LIBADD = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(FFI_LIBS) \
|
||||
$(GLIB_LIBS)
|
||||
|
||||
if OS_WIN32
|
||||
-libpyglib_gi_2_0_@PYTHON_BASENAME@_la_LDFLAGS = \
|
||||
+libpyglib_gi_2_0_@PYTHON_BASENAME@@PYTHON_VERSION@_la_LDFLAGS = \
|
||||
-no-undefined
|
||||
endif
|
||||
|
||||
@@ -73,7 +73,7 @@ _glib_la_CPPFLAGS = \
|
||||
_glib_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(GLIB_LIBS) \
|
||||
- libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+ libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
_glib_la_LDFLAGS = \
|
||||
$(extension_ldflags) \
|
||||
-export-symbols-regex "_glib|PyInit__glib"
|
||||
diff --git a/gi/_gobject/Makefile.am b/gi/_gobject/Makefile.am
|
||||
index 6bddcf7..023907f 100644
|
||||
--- a/gi/_gobject/Makefile.am
|
||||
+++ b/gi/_gobject/Makefile.am
|
||||
@@ -65,7 +65,7 @@ _gobject_la_LIBADD = \
|
||||
$(extension_libadd) \
|
||||
$(GLIB_LIBS) \
|
||||
$(FFI_LIBS) \
|
||||
- $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@.la
|
||||
+ $(top_builddir)/gi/_glib/libpyglib-gi-2.0-@PYTHON_BASENAME@@PYTHON_VERSION@.la
|
||||
_gobject_la_LDFLAGS = \
|
||||
$(extension_ldflags) \
|
||||
-export-symbols-regex "_gobject|PyInit__gobject"
|
||||
--
|
||||
1.7.6.1
|
||||
|
||||
@@ -1,69 +0,0 @@
|
||||
Disable tests requiring >=gobject-introspection-1.31
|
||||
|
||||
diff --git a/tests/test_everything.py b/tests/test_everything.py
|
||||
index 43735e5..ecfdef4 100644
|
||||
--- a/tests/test_everything.py
|
||||
+++ b/tests/test_everything.py
|
||||
@@ -507,22 +507,3 @@ class TestAdvancedInterfaces(unittest.TestCase):
|
||||
self.assertEquals(ret[0], 51);
|
||||
self.assertEquals(ret[1], 61);
|
||||
self.assertEquals(ret[2], 32);
|
||||
-
|
||||
- def test_obj_skip_return_val_no_out(self):
|
||||
- obj = Everything.TestObj();
|
||||
- # raises an error for 0, succeeds for any other value
|
||||
- self.assertRaises(GLib.GError, obj.skip_return_val_no_out, 0)
|
||||
-
|
||||
- ret = obj.skip_return_val_no_out(1)
|
||||
- self.assertEquals(ret, None)
|
||||
-
|
||||
-class TestSignals(unittest.TestCase):
|
||||
- def test_object_param_signal(self):
|
||||
- obj = Everything.TestObj();
|
||||
-
|
||||
- def callback (obj_param):
|
||||
- self.assertEquals(obj_param.props.int, 3)
|
||||
- self.assertEquals(obj_param.__grefcount__, 2)
|
||||
-
|
||||
- obj.connect('sig-with-obj', callback)
|
||||
- obj.emit_sig_with_obj()
|
||||
diff --git a/tests/test_gi.py b/tests/test_gi.py
|
||||
index 0a9b1b2..7e24778 100644
|
||||
--- a/tests/test_gi.py
|
||||
+++ b/tests/test_gi.py
|
||||
@@ -770,18 +770,6 @@ class TestArray(unittest.TestCase):
|
||||
def test_gstrv_inout(self):
|
||||
self.assertEquals(['-1', '0', '1', '2'], GIMarshallingTests.gstrv_inout(['0', '1', '2']))
|
||||
|
||||
- def test_array_gvariant_none_in(self):
|
||||
- v = [GLib.Variant("i", 27), GLib.Variant("s", "Hello")]
|
||||
- self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
-
|
||||
- def test_array_gvariant_container_in(self):
|
||||
- v = [GLib.Variant("i", 27), GLib.Variant("s", "Hello")]
|
||||
- self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
-
|
||||
- def test_array_gvariant_full_in(self):
|
||||
- v = [GLib.Variant("i", 27), GLib.Variant("s", "Hello")]
|
||||
- self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
-
|
||||
def test_bytearray_gvariant(self):
|
||||
v = GLib.Variant.new_bytestring("foo")
|
||||
self.assertEquals(v.get_bytestring(), "foo")
|
||||
@@ -1651,16 +1639,6 @@ class TestPythonGObject(unittest.TestCase):
|
||||
def do_method_not_a_vfunc(self):
|
||||
pass
|
||||
|
||||
- def test_subsubobject(self):
|
||||
- class SubSubSubObject(GIMarshallingTests.SubSubObject):
|
||||
- def do_method_deep_hierarchy(self, num):
|
||||
- self.props.int = num * 2
|
||||
-
|
||||
- sub_sub_sub_object = SubSubSubObject()
|
||||
- GIMarshallingTests.SubSubObject.do_method_deep_hierarchy(sub_sub_sub_object, 5)
|
||||
- self.assertEqual(sub_sub_sub_object.props.int, 5)
|
||||
-
|
||||
-
|
||||
class TestMultiOutputArgs(unittest.TestCase):
|
||||
|
||||
def test_int_out_out(self):
|
||||
@@ -1,70 +0,0 @@
|
||||
From 00030bc6f0fb961c716ed692144cd8e4bb9be7d0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Sebastian=20P=C3=B6lsterl?= <sebp@k-d-w.org>
|
||||
Date: Sat, 10 Dec 2011 12:51:45 +0100
|
||||
Subject: [PATCH] Fixed bug where GObject.property did not respect minimum and
|
||||
maximum values
|
||||
|
||||
https://bugzilla.gnome.org/show_bug.cgi?id=664864
|
||||
---
|
||||
gi/_gobject/propertyhelper.py | 2 +-
|
||||
tests/test_properties.py | 31 +++++++++++++++++++++++++++++++
|
||||
2 files changed, 32 insertions(+), 1 deletions(-)
|
||||
|
||||
diff --git a/gi/_gobject/propertyhelper.py b/gi/_gobject/propertyhelper.py
|
||||
index 4635350..9208a0b 100644
|
||||
--- a/gi/_gobject/propertyhelper.py
|
||||
+++ b/gi/_gobject/propertyhelper.py
|
||||
@@ -298,7 +298,7 @@ class property(object):
|
||||
ptype = self.type
|
||||
if ptype in [TYPE_INT, TYPE_UINT, TYPE_LONG, TYPE_ULONG,
|
||||
TYPE_INT64, TYPE_UINT64, TYPE_FLOAT, TYPE_DOUBLE]:
|
||||
- args = self._get_minimum(), self._get_maximum(), self.default
|
||||
+ args = self.minimum, self.maximum, self.default
|
||||
elif (ptype == TYPE_STRING or ptype == TYPE_BOOLEAN or
|
||||
ptype.is_a(TYPE_ENUM)):
|
||||
args = (self.default,)
|
||||
diff --git a/tests/test_properties.py b/tests/test_properties.py
|
||||
index 3521647..75aacff 100644
|
||||
--- a/tests/test_properties.py
|
||||
+++ b/tests/test_properties.py
|
||||
@@ -367,6 +367,37 @@ class TestProperty(unittest.TestCase):
|
||||
GObject.property, type=gtype, minimum=min,
|
||||
maximum=max+1)
|
||||
|
||||
+ def testMinMax(self):
|
||||
+ class C(GObject.GObject):
|
||||
+ prop_int = GObject.property(type=int, minimum=1, maximum=100, default=1)
|
||||
+ prop_float = GObject.property(type=float, minimum=0.1, maximum=10.5, default=1.1)
|
||||
+
|
||||
+ def __init__(self):
|
||||
+ GObject.GObject.__init__(self)
|
||||
+
|
||||
+ o = C()
|
||||
+ self.assertEqual(o.prop_int, 1)
|
||||
+
|
||||
+ o.prop_int = 5
|
||||
+ self.assertEqual(o.prop_int, 5)
|
||||
+
|
||||
+ o.prop_int = 0
|
||||
+ self.assertEqual(o.prop_int, 5)
|
||||
+
|
||||
+ o.prop_int = 101
|
||||
+ self.assertEqual(o.prop_int, 5)
|
||||
+
|
||||
+ self.assertEqual(o.prop_float, 1.1)
|
||||
+
|
||||
+ o.prop_float = 7.75
|
||||
+ self.assertEqual(o.prop_float, 7.75)
|
||||
+
|
||||
+ o.prop_float = 0.09
|
||||
+ self.assertEqual(o.prop_float, 7.75)
|
||||
+
|
||||
+ o.prop_float = 10.51
|
||||
+ self.assertEqual(o.prop_float, 7.75)
|
||||
+
|
||||
def testMultipleInstances(self):
|
||||
class C(GObject.GObject):
|
||||
prop = GObject.property(type=str, default='default')
|
||||
--
|
||||
1.7.8.1
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
From 8d88283688797b8fc70a7cbccd42a71b8518098d Mon Sep 17 00:00:00 2001
|
||||
From: Alexandre Rostovtsev <tetromino@gentoo.org>
|
||||
Date: Mon, 26 Dec 2011 00:44:56 -0500
|
||||
Subject: [PATCH] Fix bytearray test compatibility with python3
|
||||
|
||||
https://bugs.gentoo.org/show_bug.cgi?id=321879
|
||||
---
|
||||
tests/test_gi.py | 4 ++--
|
||||
1 files changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/tests/test_gi.py b/tests/test_gi.py
|
||||
index 0a9b1b2..8726187 100644
|
||||
--- a/tests/test_gi.py
|
||||
+++ b/tests/test_gi.py
|
||||
@@ -783,8 +783,8 @@ class TestArray(unittest.TestCase):
|
||||
self.assertEquals([27, "Hello"], map(GLib.Variant.unpack, GIMarshallingTests.array_gvariant_none_in(v)))
|
||||
|
||||
def test_bytearray_gvariant(self):
|
||||
- v = GLib.Variant.new_bytestring("foo")
|
||||
- self.assertEquals(v.get_bytestring(), "foo")
|
||||
+ v = GLib.Variant.new_bytestring(b"foo")
|
||||
+ self.assertEquals(v.get_bytestring(), b"foo")
|
||||
|
||||
class TestGArray(unittest.TestCase):
|
||||
|
||||
--
|
||||
1.7.8.1
|
||||
|
||||
@@ -1,84 +0,0 @@
|
||||
From d0885d5757f02f53dbc8036054a1ced7f727eb08 Mon Sep 17 00:00:00 2001
|
||||
From: Gilles Dartiguelongue <eva@gentoo.org>
|
||||
Date: Fri, 5 Nov 2010 23:39:08 +0100
|
||||
Subject: [PATCH] Do not build tests unless needed
|
||||
|
||||
[Alexandre Rostovtsev <tetromino@gmail.com>: port to 2.90.1]
|
||||
---
|
||||
tests/Makefile.am | 12 ++++++------
|
||||
tests/runtests.py | 3 +++
|
||||
2 files changed, 9 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/tests/Makefile.am b/tests/Makefile.am
|
||||
index 7a619bf..a3cbf57 100644
|
||||
--- a/tests/Makefile.am
|
||||
+++ b/tests/Makefile.am
|
||||
@@ -1,5 +1,5 @@
|
||||
CLEANFILES =
|
||||
-noinst_LTLIBRARIES = libgimarshallingtests.la
|
||||
+check_LTLIBRARIES = libgimarshallingtests.la
|
||||
test_typelibs = GIMarshallingTests-1.0.typelib
|
||||
|
||||
nodist_libgimarshallingtests_la_SOURCES = $(GI_DATADIR)/tests/gimarshallingtests.c $(GI_DATADIR)/tests/gimarshallingtests.h
|
||||
@@ -23,7 +23,7 @@ GIMarshallingTests-1.0.typelib: GIMarshallingTests-1.0.gir Makefile
|
||||
|
||||
# regress.c needs cairo
|
||||
if ENABLE_CAIRO
|
||||
-noinst_LTLIBRARIES += libregress.la
|
||||
+check_LTLIBRARIES += libregress.la
|
||||
test_typelibs += Regress-1.0.typelib
|
||||
nodist_libregress_la_SOURCES = $(GI_DATADIR)/tests/regress.c $(GI_DATADIR)/tests/regress.h
|
||||
libregress_la_CFLAGS = $(GIO_CFLAGS) $(CAIRO_CFLAGS)
|
||||
@@ -52,7 +52,7 @@ gschemas.compiled: org.gnome.test.gschema.xml
|
||||
|
||||
CLEANFILES += Regress-1.0.gir Regress-1.0.typelib GIMarshallingTests-1.0.gir GIMarshallingTests-1.0.typelib gschemas.compiled
|
||||
|
||||
-noinst_LTLIBRARIES += testhelper.la
|
||||
+check_LTLIBRARIES += testhelper.la
|
||||
|
||||
testhelper_la_CFLAGS = -I$(top_srcdir)/gi/_gobject -I$(top_srcdir)/gi/_glib $(PYTHON_INCLUDES) $(GLIB_CFLAGS)
|
||||
testhelper_la_LDFLAGS = -module -avoid-version
|
||||
@@ -72,7 +72,7 @@ testhelper.la: $(testhelper_la_OBJECTS) $(testhelper_la_DEPENDENCIES)
|
||||
test -L $@ || $(LN_S) .libs/$@ $@
|
||||
|
||||
|
||||
-all: $(LTLIBRARIES:.la=.so)
|
||||
+all: $(check_LTLIBRARIES:.la=.so)
|
||||
|
||||
EXTRA_DIST = \
|
||||
compathelper.py \
|
||||
@@ -112,7 +112,7 @@ EXTRA_DIST = \
|
||||
$(NULL)
|
||||
|
||||
clean-local:
|
||||
- rm -f $(LTLIBRARIES:.la=.so) file.txt~
|
||||
+ rm -f $(check_LTLIBRARIES:.la=.so) file.txt~
|
||||
|
||||
DBUS_LAUNCH=$(shell which dbus-launch)
|
||||
RUN_TESTS_ENV_VARS= \
|
||||
@@ -123,7 +123,7 @@ RUN_TESTS_ENV_VARS= \
|
||||
MALLOC_PERTURB_=85 \
|
||||
TESTS_BUILDDIR=$(builddir)
|
||||
|
||||
-check-local: $(LTLIBRARIES:.la=.so) $(test_typelibs) gschemas.compiled
|
||||
+check-local: $(check_LTLIBRARIES:.la=.so) $(test_typelibs) gschemas.compiled
|
||||
@echo " CHECK Pyflakes"
|
||||
@if type pyflakes >/dev/null 2>&1; then pyflakes $(top_srcdir); else echo "skipped, pyflakes not installed"; fi
|
||||
@echo " CHECK PEP8"
|
||||
diff --git a/tests/runtests.py b/tests/runtests.py
|
||||
index c518fcc..35bb5c4 100755
|
||||
--- a/tests/runtests.py
|
||||
+++ b/tests/runtests.py
|
||||
@@ -34,6 +34,9 @@ if sys.version_info[:2] == (2, 6):
|
||||
unittest.TestCase.assertGreater = assertGreater
|
||||
unittest.TestCase.assertIsInstance = assertIsInstance
|
||||
|
||||
+# Some tests fail with translated messages.
|
||||
+os.environ["LC_ALL"] = "C"
|
||||
+
|
||||
if '--help' in sys.argv:
|
||||
print("Usage: ./runtests.py <testfiles>")
|
||||
sys.exit(0)
|
||||
--
|
||||
1.7.12.4
|
||||
|
||||
@@ -1,91 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-cairo}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit alternatives autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, Cairo Libraries"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+threads"
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=]
|
||||
>=dev-python/pycairo-1.10.0"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
sys-apps/findutils"
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--enable-cairo
|
||||
$(use_enable threads thread)"
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/${REAL_PN}-2.90.1-make_check.patch"
|
||||
|
||||
# Support installation for multiple Python versions, upstream bug #648292
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.0.0-support_multiple_python_versions.patch"
|
||||
|
||||
# Disable tests that fail
|
||||
#epatch "${FILESDIR}/${REAL_PN}-2.28.3-disable-failing-tests.patch"
|
||||
|
||||
# FIXME: disable tests that require >=gobject-introspection-1.31
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.0.3-disable-new-gi-tests.patch"
|
||||
|
||||
# https://bugzilla.gnome.org/show_bug.cgi?id=666852
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.0.3-tests-python3.patch"
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
# just keep /usr/$(get_libdir)/*/site-packages/gi/_gi_cairo.so
|
||||
# discard the rest
|
||||
rm $(find "${D}" -type f | grep -v "gi/_gi_cairo.so") \
|
||||
$(find "${D}" -type l | grep -v "gi/_gi_cairo.so") || die
|
||||
find "${D}" -depth -type d -empty -exec rmdir {} \; || die
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,79 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-cairo}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit alternatives autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, Cairo Libraries"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+threads"
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=]
|
||||
>=dev-python/pycairo-1.10.0"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
sys-apps/findutils"
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--enable-cairo
|
||||
$(use_enable threads thread)"
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/${REAL_PN}-2.90.1-make_check.patch"
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
# just keep /usr/$(get_libdir)/*/site-packages/gi/_gi_cairo.so
|
||||
# discard the rest
|
||||
rm $(find "${D}" -type f | grep -v "gi/_gi_cairo.so") \
|
||||
$(find "${D}" -type l | grep -v "gi/_gi_cairo.so") || die
|
||||
find "${D}" -depth -type d -empty -exec rmdir {} \; || die
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,79 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-cairo}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit alternatives autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, Cairo Libraries"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+threads"
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=]
|
||||
>=dev-python/pycairo-1.10.0"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
sys-apps/findutils"
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--enable-cairo
|
||||
$(use_enable threads thread)"
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/${REAL_PN}-2.90.1-make_check.patch"
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
# just keep /usr/$(get_libdir)/*/site-packages/gi/_gi_cairo.so
|
||||
# discard the rest
|
||||
rm $(find "${D}" -type f | grep -v "gi/_gi_cairo.so") \
|
||||
$(find "${D}" -type l | grep -v "gi/_gi_cairo.so") || die
|
||||
find "${D}" -depth -type d -empty -exec rmdir {} \; || die
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,79 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
SUPPORT_PYTHON_ABIS="1"
|
||||
PYTHON_DEPEND="2:2.6 3:3.1"
|
||||
RESTRICT_PYTHON_ABIS="2.4 2.5 3.0 *-jython *-pypy-*"
|
||||
|
||||
REAL_PN="${PN/-cairo}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit alternatives autotools eutils gnome2 python virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, Cairo Libraries"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+threads"
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=]
|
||||
>=dev-python/pycairo-1.10.0"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
sys-apps/findutils"
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
pkg_setup() {
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--enable-cairo
|
||||
$(use_enable threads thread)"
|
||||
python_pkg_setup
|
||||
}
|
||||
|
||||
src_prepare() {
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/${REAL_PN}-2.90.1-make_check.patch"
|
||||
|
||||
python_clean_py-compile_files
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_execute_function -s gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_src_compile
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_execute_function -s gnome2_src_install
|
||||
python_clean_installation_image
|
||||
# just keep /usr/$(get_libdir)/*/site-packages/gi/_gi_cairo.so
|
||||
# discard the rest
|
||||
rm $(find "${D}" -type f | grep -v "gi/_gi_cairo.so") \
|
||||
$(find "${D}" -type l | grep -v "gi/_gi_cairo.so") || die
|
||||
find "${D}" -depth -type d -empty -exec rmdir {} \; || die
|
||||
}
|
||||
|
||||
pkg_postinst() {
|
||||
python_mod_optimize gi
|
||||
}
|
||||
|
||||
pkg_postrm() {
|
||||
python_mod_cleanup gi
|
||||
}
|
||||
@@ -1,75 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="5"
|
||||
GCONF_DEBUG="no"
|
||||
GNOME2_LA_PUNT="yes"
|
||||
PYTHON_COMPAT=( python{2_6,2_7,3_1,3_2,3_3} )
|
||||
|
||||
REAL_PN="${PN/-cairo}"
|
||||
GNOME_ORG_MODULE="${REAL_PN}"
|
||||
|
||||
inherit autotools eutils gnome2 python-r1 virtualx
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, Cairo Libraries"
|
||||
HOMEPAGE="http://www.pygtk.org/"
|
||||
|
||||
LICENSE="LGPL-2.1+"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+threads"
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=]
|
||||
>=dev-python/pycairo-1.10.0
|
||||
${PYTHON_DEPS}"
|
||||
DEPEND="${COMMON_DEPEND}
|
||||
x11-libs/cairo[glib]
|
||||
sys-apps/findutils"
|
||||
RDEPEND="${COMMON_DEPEND}
|
||||
!<dev-python/pygtk-2.13
|
||||
!<dev-python/pygobject-2.28.6-r50:2[introspection]"
|
||||
|
||||
src_prepare() {
|
||||
DOCS="AUTHORS ChangeLog* NEWS README"
|
||||
# Hard-enable libffi support since both gobject-introspection and
|
||||
# glib-2.29.x rdepend on it anyway
|
||||
# docs disabled by upstream default since they are very out of date
|
||||
G2CONF="${G2CONF}
|
||||
--disable-dependency-tracking
|
||||
--with-ffi
|
||||
--enable-cairo
|
||||
$(use_enable threads thread)"
|
||||
|
||||
# Do not build tests if unneeded, bug #226345
|
||||
epatch "${FILESDIR}/${REAL_PN}-3.4.1.1-make_check.patch"
|
||||
|
||||
eautoreconf
|
||||
gnome2_src_prepare
|
||||
|
||||
python_copy_sources
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
python_foreach_impl run_in_build_dir gnome2_src_configure
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
python_foreach_impl run_in_build_dir gnome2_src_compile
|
||||
}
|
||||
|
||||
src_install() {
|
||||
python_foreach_impl run_in_build_dir gnome2_src_install
|
||||
# just keep /usr/$(get_libdir)/*/site-packages/gi/_gi_cairo.so
|
||||
# discard the rest
|
||||
rm $(find "${ED}" -type f | grep -v "gi/_gi_cairo.so") \
|
||||
$(find "${ED}" -type l | grep -v "gi/_gi_cairo.so") || die
|
||||
find "${ED}" -depth -type d -empty -exec rmdir {} \; || die
|
||||
}
|
||||
|
||||
run_in_build_dir() {
|
||||
pushd "${BUILD_DIR}" > /dev/null || die
|
||||
"$@"
|
||||
popd > /dev/null
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, meta package"
|
||||
HOMEPAGE="http://www.pygtk.org"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+cairo examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=,examples=,test=]
|
||||
cairo? ( ~dev-python/pygobject-cairo-${PV}[threads=] )"
|
||||
DEPEND="${COMMON_DEPEND}"
|
||||
RDEPEND="${COMMON_DEPEND}"
|
||||
@@ -1,19 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, meta package"
|
||||
HOMEPAGE="http://www.pygtk.org"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+cairo examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=,examples=,test=]
|
||||
cairo? ( ~dev-python/pygobject-cairo-${PV}[threads=] )"
|
||||
DEPEND="${COMMON_DEPEND}"
|
||||
RDEPEND="${COMMON_DEPEND}"
|
||||
@@ -1,19 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, meta package"
|
||||
HOMEPAGE="http://www.pygtk.org"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+cairo examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=,examples=,test=]
|
||||
cairo? ( ~dev-python/pygobject-cairo-${PV}[threads=] )"
|
||||
DEPEND="${COMMON_DEPEND}"
|
||||
RDEPEND="${COMMON_DEPEND}"
|
||||
@@ -1,19 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="4"
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, meta package"
|
||||
HOMEPAGE="http://www.pygtk.org"
|
||||
|
||||
LICENSE="LGPL-2.1"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+cairo examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=,examples=,test=]
|
||||
cairo? ( ~dev-python/pygobject-cairo-${PV}[threads=] )"
|
||||
DEPEND="${COMMON_DEPEND}"
|
||||
RDEPEND="${COMMON_DEPEND}"
|
||||
@@ -1,23 +0,0 @@
|
||||
# Copyright 1999-2012 Gentoo Foundation
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
# $Header: $
|
||||
|
||||
EAPI="5"
|
||||
|
||||
PYTHON_COMPAT=( python{2_6,2_7,3_1,3_2,3_3} )
|
||||
|
||||
inherit python-r1
|
||||
|
||||
DESCRIPTION="GLib's GObject library bindings for Python, meta package"
|
||||
HOMEPAGE="http://www.pygtk.org"
|
||||
|
||||
LICENSE="LGPL-2.1+"
|
||||
SLOT="3"
|
||||
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x64-solaris ~x86-solaris"
|
||||
IUSE="+cairo examples test +threads" # doc
|
||||
|
||||
COMMON_DEPEND="
|
||||
~dev-python/pygobject-base-${PV}[threads=,examples=,test=,${PYTHON_USEDEP}]
|
||||
cairo? ( ~dev-python/pygobject-cairo-${PV}[threads=,${PYTHON_USEDEP}] )"
|
||||
DEPEND="${COMMON_DEPEND}"
|
||||
RDEPEND="${COMMON_DEPEND}"
|
||||
Reference in New Issue
Block a user