summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>2010-12-06 14:37:30 +0000
committerArfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>2010-12-06 14:37:30 +0000
commit490532704fde7a58165cd9cd96f088319b145b59 (patch)
tree4873a4b5caa26e7c32a2af8cf8616f0d3441e420 /dev-python/logilab-common
parentDelete older ebuild. (diff)
downloadgentoo-2-490532704fde7a58165cd9cd96f088319b145b59.tar.gz
gentoo-2-490532704fde7a58165cd9cd96f088319b145b59.tar.bz2
gentoo-2-490532704fde7a58165cd9cd96f088319b145b59.zip
Version bump.
(Portage version: 2.2.0_alpha7_p1/cvs/Linux x86_64)
Diffstat (limited to 'dev-python/logilab-common')
-rw-r--r--dev-python/logilab-common/ChangeLog9
-rw-r--r--dev-python/logilab-common/files/logilab-common-0.53.0-fix_indentation.patch40
-rw-r--r--dev-python/logilab-common/logilab-common-0.53.0.ebuild79
3 files changed, 127 insertions, 1 deletions
diff --git a/dev-python/logilab-common/ChangeLog b/dev-python/logilab-common/ChangeLog
index b1a830ac7fa7..60936004201f 100644
--- a/dev-python/logilab-common/ChangeLog
+++ b/dev-python/logilab-common/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for dev-python/logilab-common
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-python/logilab-common/ChangeLog,v 1.79 2010/12/06 14:02:24 arfrever Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-python/logilab-common/ChangeLog,v 1.80 2010/12/06 14:37:30 arfrever Exp $
+
+*logilab-common-0.53.0 (06 Dec 2010)
+
+ 06 Dec 2010; Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>
+ -logilab-common-0.52.0.ebuild, +logilab-common-0.53.0.ebuild,
+ +files/logilab-common-0.53.0-fix_indentation.patch:
+ Version bump.
06 Dec 2010; Arfrever Frehtes Taifersar Arahesis <arfrever@gentoo.org>
logilab-common-0.52.1.ebuild:
diff --git a/dev-python/logilab-common/files/logilab-common-0.53.0-fix_indentation.patch b/dev-python/logilab-common/files/logilab-common-0.53.0-fix_indentation.patch
new file mode 100644
index 000000000000..dfb7337f14f9
--- /dev/null
+++ b/dev-python/logilab-common/files/logilab-common-0.53.0-fix_indentation.patch
@@ -0,0 +1,40 @@
+http://hg.logilab.org/logilab/common/rev/2029eb2dd071
+
+--- optparser.py
++++ optparser.py
+@@ -46,11 +46,11 @@
+ self.min_args, self.max_args = 0, 1
+
+ def add_command(self, name, mod_or_funcs, help=''):
+- """name of the command
+- name of module or tuple of functions (run, add_options)
+- """
++ """name of the command, name of module or tuple of functions
++ (run, add_options)
++ """
+ assert isinstance(mod_or_funcs, str) or isinstance(mod_or_funcs, tuple), \
+- "mod_or_funcs has to be a module name or a tuple of functions"
++ "mod_or_funcs has to be a module name or a tuple of functions"
+ self._commands[name] = (mod_or_funcs, help)
+
+ def print_main_help(self):
+@@ -64,7 +64,7 @@
+ self.print_main_help()
+ sys.exit(1)
+ cmd = args[0]
+- args = args[1:]
++ args = args[1:]
+ if cmd not in self._commands:
+ if cmd in ('-h', '--help'):
+ self.print_main_help()
+@@ -79,8 +79,8 @@
+ self.description = help
+ if isinstance(mod_or_f, str):
+ exec 'from %s import run, add_options' % mod_or_f
+- else:
+- run, add_options = mod_or_f
++ else:
++ run, add_options = mod_or_f
+ add_options(self)
+ (options, args) = self.parse_args(args)
+ if not (self.min_args <= len(args) <= self.max_args):
diff --git a/dev-python/logilab-common/logilab-common-0.53.0.ebuild b/dev-python/logilab-common/logilab-common-0.53.0.ebuild
new file mode 100644
index 000000000000..c0ead88fa217
--- /dev/null
+++ b/dev-python/logilab-common/logilab-common-0.53.0.ebuild
@@ -0,0 +1,79 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-python/logilab-common/logilab-common-0.53.0.ebuild,v 1.1 2010/12/06 14:37:30 arfrever Exp $
+
+EAPI="3"
+SUPPORT_PYTHON_ABIS="1"
+
+inherit distutils eutils
+
+DESCRIPTION="Useful miscellaneous modules used by Logilab projects"
+HOMEPAGE="http://www.logilab.org/projects/common/ http://pypi.python.org/pypi/logilab-common"
+SRC_URI="ftp://ftp.logilab.org/pub/common/${P}.tar.gz mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~amd64 ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~ia64-linux ~x86-linux ~x64-macos ~x86-macos"
+IUSE="test"
+
+RDEPEND="dev-python/setuptools"
+# Tests using dev-python/psycopg are skipped when dev-python/psycopg isn't installed.
+# dev-python/unittest2 is not required with Python >=3.2.
+DEPEND="${RDEPEND}
+ test? (
+ dev-python/egenix-mx-base
+ dev-python/unittest2
+ !dev-python/psycopg[-mxdatetime]
+ )"
+
+DISTUTILS_USE_SEPARATE_SOURCE_DIRECTORIES="1"
+
+PYTHON_MODNAME="logilab"
+
+src_prepare() {
+ epatch "${FILESDIR}/${P}-fix_indentation.patch"
+ distutils_src_prepare
+
+ conversion() {
+ [[ "${PYTHON_ABI}" == 2.* ]] && return
+ find -name "*.py" ! -name "setup.py" -print | xargs 2to3-${PYTHON_ABI} -nw --no-diffs
+
+ # Ignore errors during transformation of data of tests.
+ :
+ }
+ python_execute_function -s conversion
+}
+
+src_test() {
+ testing() {
+ # Install temporarily.
+ local tpath="${T}/test-${PYTHON_ABI}"
+ local spath="${tpath}$(python_get_sitedir)"
+
+ "$(PYTHON)" setup.py install --root="${tpath}" || die "Installation for tests failed with $(python_get_implementation) $(python_get_version)"
+
+ # pytest uses tests placed relatively to the current directory.
+ pushd "${spath}" > /dev/null || return 1
+ if [[ "${PYTHON_ABI}" == 3.* ]]; then
+ # Support for Python 3 is experimental. Many tests are known to fail.
+ PYTHONPATH="${spath}" "$(PYTHON)" "${tpath}/usr/bin/pytest" -v
+ else
+ PYTHONPATH="${spath}" "$(PYTHON)" "${tpath}/usr/bin/pytest" -v || return 1
+ fi
+ popd > /dev/null || return 1
+ }
+ python_execute_function -s testing
+}
+
+src_install() {
+ distutils_src_install
+
+ python_generate_wrapper_scripts -E -f -q "${ED}usr/bin/pytest"
+
+ doman doc/pytest.1 || die "doman failed"
+
+ delete_tests() {
+ rm -fr "${ED}$(python_get_sitedir)/${PN/-//}/test"
+ }
+ python_execute_function -q delete_tests
+}