summaryrefslogtreecommitdiff
path: root/dev-python/pyxattr
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-02-24 19:58:07 +0000
committerV3n3RiX <venerix@redcorelinux.org>2018-02-24 19:58:07 +0000
commit99abbc5e5a6ecd3fc981b45646fd8cb5d320377b (patch)
treeda76713365257a445f3ae3b95470917f59d46728 /dev-python/pyxattr
parent4935506e9a5cbfabd37c64093eac5f36c2ff0017 (diff)
gentoo resync : 24.02.2018
Diffstat (limited to 'dev-python/pyxattr')
-rw-r--r--dev-python/pyxattr/Manifest2
-rw-r--r--dev-python/pyxattr/files/pyxattr-0.6.0-xattr_header.patch53
-rw-r--r--dev-python/pyxattr/pyxattr-0.6.0-r1.ebuild59
3 files changed, 114 insertions, 0 deletions
diff --git a/dev-python/pyxattr/Manifest b/dev-python/pyxattr/Manifest
index 79a19b25b944..dc5ef29da0aa 100644
--- a/dev-python/pyxattr/Manifest
+++ b/dev-python/pyxattr/Manifest
@@ -1,6 +1,8 @@
+AUX pyxattr-0.6.0-xattr_header.patch 1780 BLAKE2B 43244b281bec7166d539155c66e604c907f2e74197414422c9486c93bec84ba8f4515afd20eb6bdcb898207200da4d1071489a7390a14e835531816a5b458865 SHA512 24531ff4fb116c69b8ab3e432753bad2d0b704c86ec21efe69741f2d34ced24c6a580872acab0e063f3be3dfad4f91199bf61fb8d1485d1c86a9266f7c163cd9
DIST pyxattr-0.5.5.tar.gz 26718 BLAKE2B b8d599ed0194fec4809ebdb8277fa4023e932ed49a8a6253a7c6a879250a73330334bd8a72b0c9d9bfd828cac1454659d23b55b5e608bfe0109392988709beb8 SHA512 77b732a7e524a7c31a0511df2c96c18b214f93c6ac47276ecdf12ed95133ee506fa882b2532a7159aa2f4e02a7128e33bb8883ea632a5394297d98fb28898327
DIST pyxattr-0.6.0.tar.gz 31057 BLAKE2B cf6e99c499dbcc74305970413803e5cf59508e7ee1bf247afe42e576c2dfaf118a374ad6f8721b9d9c482f8be0c222d26b82997dc1ccc79248d5f52b2064ed8d SHA512 c56bf57729b5f8c8e3e19e29fd903b7365c6644abe3dcebf57ffc2f97a1e92d0e22cdc0a967c5abee3a74ba61a2a379e31a1734f45449095bdb7895b8357a9bb
EBUILD pyxattr-0.5.5.ebuild 1436 BLAKE2B 649f53a6aca91cdbc443ba0bd461bc81742be9bbe4c1a3440c79957c4a562e1b3b1e3d12611636d272cfe67cd956e9eb9b6aa5f219386891eac99d1b21ad5dd6 SHA512 f468797e54126048d73e709c2df49eaa15e7585995e906d8aade168d51289acfc11f201ac9010ece8bfef5080ae305f3a61ba393389041bf25b9884e75c6d830
+EBUILD pyxattr-0.6.0-r1.ebuild 1510 BLAKE2B 1aec5f33077c7669dac2a4796813609a6ab7d8163f77815126201ebf6624f783ad4eee385ecfdcf2ea97b7d9700f543c0090118bd51e03c813a95d51a5300e64 SHA512 584d67aecb3e2a90fc0c82e885334e7969dad3397fa46c9ff7509cbe6d8668e9317d77b0276d9a24ef31ca222f58feed14cc35150863f6aeb9321431551ec552
EBUILD pyxattr-0.6.0.ebuild 1451 BLAKE2B 69cdd159994721dffb0d80b62f2790767cc4270bbeea09037b3e5a9e20e699cafa57fd0863f98d819bf9eb7171505193ca4cc4f88462c0d105c9f898681cea43 SHA512 8aa97fc46e8eb5df5faf1df7f6560749bfb1c6fedb42e6dab01a2f9f0549af095ea37f9d7bfd2a76bee321621632754c6a5d4545b44d3f0ffe3a7d25b117c3cf
EBUILD pyxattr-9999.ebuild 890 BLAKE2B 23eb16242d8e29c6f2c12baa620b2c6c2642049afbbb60667ab9166193829f27fd20baab59a9f3c84a48968e2e234b87e2181a83293cf6e76245c128290bf6ba SHA512 2a1bcc94699a19d51aaf914a728e69ef0c38a4ca08b1d151e5de5067bffbf24b4e8f35b1c4ebc934763676fb2065e27cdf9dc0769fc152bea1b0d8d596fc2402
MISC metadata.xml 609 BLAKE2B 8f3429390129e4438c5bb4c8d82ae11e9824863d4b200a57d660d0ae93692711b96c6cbcfd9e7e8ad46848beba86dd2ee971acde59c08c9fc6f317283358157f SHA512 8a18175143b319bf6f623304ad8f534ad34eaf8b67c57ee1addb8886e34d79bd3a74723bce4f66fb5e9e3dad4768aaf253cec8fb8e97365f152d0b8f772d7df6
diff --git a/dev-python/pyxattr/files/pyxattr-0.6.0-xattr_header.patch b/dev-python/pyxattr/files/pyxattr-0.6.0-xattr_header.patch
new file mode 100644
index 000000000000..89b18730c3d9
--- /dev/null
+++ b/dev-python/pyxattr/files/pyxattr-0.6.0-xattr_header.patch
@@ -0,0 +1,53 @@
+From cc0bc63b291ee1a831f07c81946149dbe8c8146d Mon Sep 17 00:00:00 2001
+From: Lars Wendler <polynomial-c@gentoo.org>
+Date: Wed, 10 Jan 2018 11:45:35 +0100
+Subject: [PATCH] xattr.c: There is no more attr/xattr.h with >=attr-2.4.48
+
+See also:
+http://git.savannah.nongnu.org/cgit/attr.git/commit/?id=7921157890d07858d092f4003ca4c6bae9fd2c38
+---
+ xattr.c | 13 +++----------
+ 1 file changed, 3 insertions(+), 10 deletions(-)
+
+diff --git a/xattr.c b/xattr.c
+index 111cec1..c82ee32 100644
+--- a/xattr.c
++++ b/xattr.c
+@@ -23,10 +23,8 @@
+
+ #define PY_SSIZE_T_CLEAN
+ #include <Python.h>
+-#if defined(__APPLE__)
++#if defined(__APPLE__) || defined(__linux__)
+ #include <sys/xattr.h>
+-#elif defined(__linux__)
+-#include <attr/xattr.h>
+ #endif
+ #include <stdio.h>
+
+@@ -642,11 +640,7 @@ get_all(PyObject *self, PyObject *args, PyObject *keywds)
+ /* Now retrieve the attribute value */
+ nval = _generic_get(_get_obj, &tgt, s, &buf_val, &nalloc, &io_errno);
+ if (nval == -1) {
+- if (
+-#ifdef ENODATA
+- io_errno == ENODATA ||
+-#endif
+- io_errno == ENOATTR) {
++ if (io_errno == ENODATA) {
+ PyErr_Clear();
+ continue;
+ } else {
+@@ -1173,8 +1167,7 @@ static char __xattr_doc__[] = \
+ " a :exc:`EnvironmentError`; under\n"
+ " Linux, the following ``errno`` values are used:\n"
+ "\n"
+- " - ``ENOATTR`` and ``ENODATA`` mean that the attribute name is\n"
+- " invalid\n"
++ " - ``ENODATA`` means that the attribute name is\n invalid\n"
+ " - ``ENOTSUP`` and ``EOPNOTSUPP`` mean that the filesystem does not\n"
+ " support extended attributes, or that the namespace is invalid\n"
+ " - ``E2BIG`` mean that the attribute value is too big\n"
+--
+2.16.0.rc1
+
diff --git a/dev-python/pyxattr/pyxattr-0.6.0-r1.ebuild b/dev-python/pyxattr/pyxattr-0.6.0-r1.ebuild
new file mode 100644
index 000000000000..02c1ec7d7819
--- /dev/null
+++ b/dev-python/pyxattr/pyxattr-0.6.0-r1.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+PYTHON_COMPAT=( python2_7 python3_{4,5,6} pypy )
+
+inherit distutils-r1 eutils
+
+DESCRIPTION="Python interface to xattr"
+HOMEPAGE="http://pyxattr.k1024.org/"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz
+ http://pyxattr.k1024.org/downloads/${P}.tar.gz"
+
+LICENSE="LGPL-2.1"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~arm-linux ~x86-linux"
+IUSE="doc test"
+
+RDEPEND="sys-apps/attr"
+DEPEND="${RDEPEND}
+ dev-python/setuptools[${PYTHON_USEDEP}]
+ doc? ( >=dev-python/sphinx-1.3.1[${PYTHON_USEDEP}] )
+ test? ( dev-python/nose[${PYTHON_USEDEP}] )"
+
+PATCHES=(
+ "${FILESDIR}/${PN}-0.6.0-xattr_header.patch"
+)
+
+python_prepare_all() {
+ sed -i -e 's:, "-Werror"::' setup.py || die
+ # Bug 548486
+ sed -e "s:html_theme = 'default':html_theme = 'classic':" \
+ -i doc/conf.py || die
+
+ distutils-r1_python_prepare_all
+}
+
+python_compile_all() {
+ use doc && emake doc
+}
+
+src_test() {
+ # Perform the tests in /var/tmp; that location is more likely
+ # to have xattr support than /tmp which is often tmpfs.
+ export TESTDIR=/var/tmp
+
+ einfo 'Please note that the tests fail if xattrs are not supported'
+ einfo 'by the filesystem used for /var/tmp.'
+ distutils-r1_src_test
+}
+
+python_test() {
+ nosetests || die "Tests fail with ${EPYTHON}"
+}
+
+python_install_all() {
+ use doc && local HTML_DOCS=( doc/html/. )
+ distutils-r1_python_install_all
+}