Gentoo Archives: gentoo-commits

From: Tim Harder <radhermit@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/appdirs/, dev-python/appdirs/files/
Date: Wed, 25 Jan 2017 07:23:49
Message-Id: 1485329000.89cd543cc1143287106cb4ab907cd5a5b90a78ed.radhermit@gentoo
1 commit: 89cd543cc1143287106cb4ab907cd5a5b90a78ed
2 Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
3 AuthorDate: Wed Jan 25 07:20:15 2017 +0000
4 Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
5 CommitDate: Wed Jan 25 07:23:20 2017 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=89cd543c
7
8 dev-python/appdirs: force usage of distutils instead of setuptools
9
10 In order to break a cyclic dependency with setuptools since appdirs is
11 required by setuptools and isn't vendored anymore.
12
13 dev-python/appdirs/appdirs-1.4.0-r1.ebuild | 30 ++++++++++++++++++++++
14 .../appdirs/files/appdirs-1.4.0-distutils.patch | 22 ++++++++++++++++
15 2 files changed, 52 insertions(+)
16
17 diff --git a/dev-python/appdirs/appdirs-1.4.0-r1.ebuild b/dev-python/appdirs/appdirs-1.4.0-r1.ebuild
18 new file mode 100644
19 index 00000000..fc2827a
20 --- /dev/null
21 +++ b/dev-python/appdirs/appdirs-1.4.0-r1.ebuild
22 @@ -0,0 +1,30 @@
23 +# Copyright 1999-2017 Gentoo Foundation
24 +# Distributed under the terms of the GNU General Public License v2
25 +# $Id$
26 +
27 +EAPI=6
28 +
29 +PYTHON_COMPAT=( python2_7 python3_{4,5} pypy pypy3 )
30 +
31 +inherit distutils-r1
32 +
33 +DESCRIPTION="Module for determining appropriate platform-specific dirs"
34 +HOMEPAGE="https://github.com/ActiveState/appdirs"
35 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
36 +
37 +LICENSE="MIT"
38 +SLOT="0"
39 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
40 +IUSE=""
41 +
42 +# api.doctests is missing in the dist zipfile
43 +# and the 'internal' doctest does nothing
44 +RESTRICT=test
45 +
46 +PATCHES=( "${FILESDIR}"/${P}-distutils.patch )
47 +
48 +python_test() {
49 + cd test || die
50 + "${PYTHON}" test.py \
51 + || die "Tests fail with ${EPYTHON}"
52 +}
53
54 diff --git a/dev-python/appdirs/files/appdirs-1.4.0-distutils.patch b/dev-python/appdirs/files/appdirs-1.4.0-distutils.patch
55 new file mode 100644
56 index 00000000..eb0cf82
57 --- /dev/null
58 +++ b/dev-python/appdirs/files/appdirs-1.4.0-distutils.patch
59 @@ -0,0 +1,22 @@
60 +Force setup.py to use distutils in order to break setuptools cyclic dependency.
61 +
62 +--- appdirs-1.4.0/setup.py
63 ++++ appdirs-1.4.0/setup.py
64 +@@ -2,7 +2,7 @@
65 + import sys
66 + import os
67 + import os.path
68 +-from setuptools import setup
69 ++from distutils.core import setup
70 + import appdirs
71 +
72 + tests_require = []
73 +@@ -38,8 +38,6 @@
74 + Programming Language :: Python :: 3.2
75 + Topic :: Software Development :: Libraries :: Python Modules
76 + """.split('\n') if c.strip()],
77 +- test_suite='test.test_api',
78 +- tests_require=tests_require,
79 + keywords='application directory log cache user',
80 + author='Trent Mick',
81 + author_email='trentm@×××××.com',