Compare commits
No commits in common. "c8" and "f30e380f9166691a732c2ae6de2d765057c630f5" have entirely different histories.
c8
...
f30e380f91
7
.gitignore
vendored
7
.gitignore
vendored
@ -1 +1,6 @@
|
|||||||
SOURCES/pyxattr-0.5.3.tar.gz
|
/pyxattr-0.5.1.tar.gz
|
||||||
|
/pyxattr-0.5.3.tar.gz
|
||||||
|
/pyxattr-0.5.6.tar.gz
|
||||||
|
/pyxattr-0.6.1.tar.gz
|
||||||
|
/pyxattr-0.7.1.tar.gz
|
||||||
|
/pyxattr-0.7.2.tar.gz
|
||||||
|
@ -1 +1 @@
|
|||||||
b403951d3b987b0fa1203377fcab8165aaa29ac0 SOURCES/pyxattr-0.5.3.tar.gz
|
45be5c539112a57b56723892587bc11c680198d0 pyxattr-0.7.2.tar.gz
|
||||||
|
@ -1,127 +0,0 @@
|
|||||||
From 50f7c251523f6be3be3426aa6499e5495a18b442 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Mark Hamzy <hamzy@us.ibm.com>
|
|
||||||
Date: Wed, 6 Aug 2014 14:06:45 -0500
|
|
||||||
Subject: [PATCH] use Py_ssize_t
|
|
||||||
|
|
||||||
>Starting with Python 2.5 the type of the length argument can be controlled by
|
|
||||||
>defining the macro PY_SSIZE_T_CLEAN before including Python.h. If the macro is
|
|
||||||
>defined, length is a Py_ssize_t rather than an int.
|
|
||||||
|
|
||||||
dmalcolm@redhat.com says:
|
|
||||||
"and IIRC that *does* in fact affect "et#" and the other hash-suffixed codes
|
|
||||||
i.e. PyArg_ParseTupleAndKeywords was expecting bufsize to be a Py_ssize_t, not an int."
|
|
||||||
|
|
||||||
So, changing size_t to Py_ssize_t and ints used as sizes to Py_ssize_t.
|
|
||||||
|
|
||||||
---
|
|
||||||
xattr.c | 24 ++++++++++++------------
|
|
||||||
1 file changed, 12 insertions(+), 12 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/xattr.c b/xattr.c
|
|
||||||
index cc1fa44..2529e90 100644
|
|
||||||
--- a/xattr.c
|
|
||||||
+++ b/xattr.c
|
|
||||||
@@ -193,7 +193,7 @@ static int merge_ns(const char *ns, const char *name,
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
-static ssize_t _list_obj(target_t *tgt, char *list, size_t size) {
|
|
||||||
+static Py_ssize_t _list_obj(target_t *tgt, char *list, Py_ssize_t size) {
|
|
||||||
if(tgt->type == T_FD)
|
|
||||||
return flistxattr(tgt->fd, list, size);
|
|
||||||
else if (tgt->type == T_LINK)
|
|
||||||
@@ -202,8 +202,8 @@ static ssize_t _list_obj(target_t *tgt, char *list, size_t size) {
|
|
||||||
return listxattr(tgt->name, list, size);
|
|
||||||
}
|
|
||||||
|
|
||||||
-static ssize_t _get_obj(target_t *tgt, const char *name, void *value,
|
|
||||||
- size_t size) {
|
|
||||||
+static Py_ssize_t _get_obj(target_t *tgt, const char *name, void *value,
|
|
||||||
+ Py_ssize_t size) {
|
|
||||||
if(tgt->type == T_FD)
|
|
||||||
return fgetxattr(tgt->fd, name, value, size);
|
|
||||||
else if (tgt->type == T_LINK)
|
|
||||||
@@ -213,7 +213,7 @@ static ssize_t _get_obj(target_t *tgt, const char *name, void *value,
|
|
||||||
}
|
|
||||||
|
|
||||||
static int _set_obj(target_t *tgt, const char *name,
|
|
||||||
- const void *value, size_t size, int flags) {
|
|
||||||
+ const void *value, Py_ssize_t size, int flags) {
|
|
||||||
if(tgt->type == T_FD)
|
|
||||||
return fsetxattr(tgt->fd, name, value, size, flags);
|
|
||||||
else if (tgt->type == T_LINK)
|
|
||||||
@@ -242,7 +242,7 @@ static int _remove_obj(target_t *tgt, const char *name) {
|
|
||||||
|
|
||||||
*/
|
|
||||||
const char *matches_ns(const char *ns, const char *name) {
|
|
||||||
- size_t ns_size;
|
|
||||||
+ Py_ssize_t ns_size;
|
|
||||||
if (ns == NULL || *ns == '\0')
|
|
||||||
return name;
|
|
||||||
ns_size = strlen(ns);
|
|
||||||
@@ -275,7 +275,7 @@ pygetxattr(PyObject *self, PyObject *args)
|
|
||||||
int nofollow = 0;
|
|
||||||
char *attrname = NULL;
|
|
||||||
char *buf;
|
|
||||||
- ssize_t nalloc, nret;
|
|
||||||
+ Py_ssize_t nalloc, nret;
|
|
||||||
PyObject *res;
|
|
||||||
|
|
||||||
/* Parse the arguments */
|
|
||||||
@@ -352,7 +352,7 @@ xattr_get(PyObject *self, PyObject *args, PyObject *keywds)
|
|
||||||
const char *fullname;
|
|
||||||
char *buf;
|
|
||||||
const char *ns = NULL;
|
|
||||||
- ssize_t nalloc, nret;
|
|
||||||
+ Py_ssize_t nalloc, nret;
|
|
||||||
PyObject *res;
|
|
||||||
static char *kwlist[] = {"item", "name", "nofollow", "namespace", NULL};
|
|
||||||
|
|
||||||
@@ -451,7 +451,7 @@ get_all(PyObject *self, PyObject *args, PyObject *keywds)
|
|
||||||
const char *ns = NULL;
|
|
||||||
char *buf_list, *buf_val;
|
|
||||||
const char *s;
|
|
||||||
- ssize_t nalloc, nlist, nval;
|
|
||||||
+ Py_ssize_t nalloc, nlist, nval;
|
|
||||||
PyObject *mylist;
|
|
||||||
target_t tgt;
|
|
||||||
static char *kwlist[] = {"item", "nofollow", "namespace", NULL};
|
|
||||||
@@ -604,7 +604,7 @@ pysetxattr(PyObject *self, PyObject *args)
|
|
||||||
int nofollow = 0;
|
|
||||||
char *attrname = NULL;
|
|
||||||
char *buf = NULL;
|
|
||||||
- int bufsize;
|
|
||||||
+ Py_ssize_t bufsize;
|
|
||||||
int nret;
|
|
||||||
int flags = 0;
|
|
||||||
target_t tgt;
|
|
||||||
@@ -670,7 +670,7 @@ xattr_set(PyObject *self, PyObject *args, PyObject *keywds)
|
|
||||||
int nofollow = 0;
|
|
||||||
char *attrname = NULL;
|
|
||||||
char *buf = NULL;
|
|
||||||
- int bufsize;
|
|
||||||
+ Py_ssize_t bufsize;
|
|
||||||
int nret;
|
|
||||||
int flags = 0;
|
|
||||||
target_t tgt;
|
|
||||||
@@ -856,7 +856,7 @@ pylistxattr(PyObject *self, PyObject *args)
|
|
||||||
{
|
|
||||||
char *buf;
|
|
||||||
int nofollow=0;
|
|
||||||
- ssize_t nalloc, nret;
|
|
||||||
+ Py_ssize_t nalloc, nret;
|
|
||||||
PyObject *myarg;
|
|
||||||
PyObject *mylist;
|
|
||||||
Py_ssize_t nattrs;
|
|
||||||
@@ -956,7 +956,7 @@ xattr_list(PyObject *self, PyObject *args, PyObject *keywds)
|
|
||||||
{
|
|
||||||
char *buf;
|
|
||||||
int nofollow = 0;
|
|
||||||
- ssize_t nalloc, nret;
|
|
||||||
+ Py_ssize_t nalloc, nret;
|
|
||||||
PyObject *myarg;
|
|
||||||
PyObject *res;
|
|
||||||
const char *ns = NULL;
|
|
||||||
--
|
|
||||||
2.0.0
|
|
||||||
|
|
@ -1,31 +0,0 @@
|
|||||||
From 3efd44125a6f64fba786d08254e9d1bb6f08abde Mon Sep 17 00:00:00 2001
|
|
||||||
From: Milind Changire <mchangir@redhat.com>
|
|
||||||
Date: Sat, 4 Aug 2018 17:51:25 +0530
|
|
||||||
Subject: [PATCH 2/2] add workaround for undefined ENOATTR
|
|
||||||
|
|
||||||
define ENOATTR as ENODATA
|
|
||||||
fixes bz#1610029
|
|
||||||
|
|
||||||
Signed-off-by: Milind Changire <mchangir@redhat.com>
|
|
||||||
---
|
|
||||||
xattr.c | 4 ++++
|
|
||||||
1 file changed, 4 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/xattr.c b/xattr.c
|
|
||||||
index 2529e90..ac248cd 100644
|
|
||||||
--- a/xattr.c
|
|
||||||
+++ b/xattr.c
|
|
||||||
@@ -97,6 +97,10 @@ typedef int Py_ssize_t;
|
|
||||||
multi-operations */
|
|
||||||
#define ESTIMATE_ATTR_SIZE 256
|
|
||||||
|
|
||||||
+#if !defined(ENOATTR)
|
|
||||||
+#define ENOATTR ENODATA
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
typedef enum {T_FD, T_PATH, T_LINK} target_e;
|
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
--
|
|
||||||
2.17.1
|
|
||||||
|
|
75
key.asc
Normal file
75
key.asc
Normal file
@ -0,0 +1,75 @@
|
|||||||
|
-----BEGIN PGP PUBLIC KEY BLOCK-----
|
||||||
|
|
||||||
|
mQINBEoSXQEBEACbnpKK4Er2m50OsiKOO8UDTLvaP95Vzi34pYSMB5HelvUJy1NU
|
||||||
|
QV372A2N4PyiMXuD0ZUkUWdJ64GxHwzB5788hutXa3XIsQuYzmth2Dd1p+dMu0VX
|
||||||
|
JwJ50nHhMnApJToNV/rtd++mPkPtpwuyImdNsEM1/ThxirEPW6ii9+npImlnLlkY
|
||||||
|
kNZFaD96UTm2/hJZJ2n+i9yuhj4hM6Gw/uyRG54UmXoS9ZsCdZLVH6Mmrr42mtGv
|
||||||
|
ejhrlOlOsxsJ0kOtxMGxFqds/+MLBekywBLSk+tDpt7sbBZsTvkSDQGfscgoFcCB
|
||||||
|
w2mlU9D4ZpjgKxiXftKME94FuFJ6y291Y+e4q6FrjpqLFWr5BVIY1F/k49oPHQbH
|
||||||
|
ihIeDkRlfldHHde5ZpERQbf7Xmf2W/m8AzLwu5IFXFBaQFN0NmzrNRFCZfVp8IAG
|
||||||
|
7BTrurEhZzY7PLYdNjXd5H7A6xfZPOTbBTxUQIWirPHs1z6nHznl+I/lJIz9ouFh
|
||||||
|
Z3MNKR4MCsOdDL7JOtLv2wLaC5KSbbdnJ9alo3K8+hYcVbzr4GEGHABOLIbiBLfT
|
||||||
|
H3iFvttWPjYqK1bYsMbS7MWUxAxc2zdR8Y9qR0JWRGTKlM0hz3BlFK+71sEjhWVC
|
||||||
|
7h3DYEi4FjqLaryU+5Z0Rn4jrf3DnwN8VNNERLj4B524uWPuYZZHdqg35QARAQAB
|
||||||
|
tBxJdXN0aW4gUG9wIDxpdXN0eUBrMTAyNC5vcmc+iQI3BBMBCgAhAhsDBQsJCAcD
|
||||||
|
BRUKCQgLBRYCAwEAAh4BAheABQJXQ00xAAoJEPZuPkGfhPTeUWoP/i/alr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MSo71SLNbKVPP4MB/iNX+fvMRS0uu72
|
||||||
|
FAmy2OdCDcMpF7wfSLjlM/Js5/2MP1AZ7bUHAXLx+0zUTMGJTEpzpZue5o/AfoOO
|
||||||
|
/5kKVtVf/8GPly5kxjHBkRfs4HPzGZgnMlCkiad+MBsP1Vzg+uEpVaBINYi5Wu7+
|
||||||
|
SKon6XS56NPnq6H8ORTeZjFwiUCzALM4QwARAQABiQIfBBgBCgAJBQJKE91WAhsM
|
||||||
|
AAoJEPZuPkGfhPTebAkP/2zEFnp7lZumZIFLu6XsUUCLDY+PWYcIuihp8y+P6FvY
|
||||||
|
oRO9Xdr51VYu7a3SgFnQNmwhuL6B/079yDbjsWqI74uxXI48hLxP7KxJMW2Fct3V
|
||||||
|
u5ZGgm3SL5WSA+/1ybL2caZ22OdDC863POThLRzYS0MUJRb9L8ha5WxFONj7ltFb
|
||||||
|
3ZNey0j2NSRN+jxtpcfUG6yT2/4vVUOsmBoL/wANp4bWc3HrjzOV7ml2O3lf+tGP
|
||||||
|
wxnPrnpdQtu72Evv7wHRmhkR9RVeLoNclYjAerElZaaXYrFPP81lodoL9mMi8cQy
|
||||||
|
TCr8ltUdPWp+is67DaK5Y1n7pGEdUu7dcT8l4vW+oFbUjoM4i647fgdLTQyGZOon
|
||||||
|
OezH36ohyF6RHv55FaA0FpqHQ1Uj7h6sGHnhAQPKrCtA6J76f80VWVBGSD8sV3+M
|
||||||
|
YdjCRmQwd+05cUyV8uwzPqwBlxaHh57OutPiQNY2KO31h0STsHiV7Je4AVsRHr2q
|
||||||
|
ExiIOhv1VntMOhSCu1a5ATvKIKeb31nfntA3+/0iVq1MMH1Wvlnyr84doNGrwZsR
|
||||||
|
r6Hgymg8an6tpf4meT1dy57GakhAjZN5ejiygFhgfHGAJtj/RKmVMgZqfWd6C/5H
|
||||||
|
CbpxLmHREbWIkUtpf6yPEUzzty+uyP61h8OaPa788jsdRjP7q/pZTW/MzvLEQFiv
|
||||||
|
=PJyc
|
||||||
|
-----END PGP PUBLIC KEY BLOCK-----
|
16
pyxattr-0.7.2.tar.gz.asc
Normal file
16
pyxattr-0.7.2.tar.gz.asc
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
-----BEGIN PGP SIGNATURE-----
|
||||||
|
|
||||||
|
iQIzBAABCgAdFiEEy5TjqjsXVdYeuxml9m4+QZ+E9N4FAl/D+d8ACgkQ9m4+QZ+E
|
||||||
|
9N6Hfg//amV/is8xZQb1tvXLRpTfPM4rWym4mRkufU5zMuEhO42ebHMetpTnbexY
|
||||||
|
HOPVSSIIiFSlqp1e4SOw8esQYjB6s28/4PXNK/wFUn6Meh6+YF7p7CTADb2goW25
|
||||||
|
CRxeLkens7Mso6GBrpmSR0AqZB7jMpXd4dmnCjRdR1NUNw3ui+yMnAMKD6zfQNzY
|
||||||
|
CIufV77EEe2uvJw33i6jHLnpd61bkN+V/r0BN9FA4i8uZMOHzGmtX4siEXDmwAJc
|
||||||
|
fLCJY2KmEAplDZl6RTgwiTFJJvRQDjhankz3pcUJk1oJa7HTCT4Uq0rOcYBtkNsv
|
||||||
|
u97GL5Mq9wsTv23v5/L3C1CbTIiAaEkmEexVgDledzr9KS24rzkxMo8D6mBzS1tx
|
||||||
|
y/hoUqbphsP/QVe8Yhbmy4x+E8dq5SlrPtpS+7xrr3AjLZJAk5l13yWcCEomNGva
|
||||||
|
alucUhWgylOSIVK9Z4TVxcZgeR/mDuDPBFxw8Cy+EkNpGbA1LVubLIdwo7+zx2r4
|
||||||
|
OM9TFu+4r9OQXzFOQhBmMbfUJfDO5wTuk3XuG8QlNH0mnOe8lL9fIHxTy+uQySbt
|
||||||
|
3t/8wAcIp499xwsWHkzZOgKEd9OSxZAzPdJjGsg+nwWlS5TQJQySHAHXup3vc+t0
|
||||||
|
8X4X76nX2CSqYoM5+3VAzn+YfBh3IQB3phVqrIltBM2otihgNdQ=
|
||||||
|
=Mm6V
|
||||||
|
-----END PGP SIGNATURE-----
|
@ -1,120 +1,118 @@
|
|||||||
%global with_python3 1
|
|
||||||
|
|
||||||
%if 0%{?rhel} > 7
|
|
||||||
# Disable python2 build by default
|
|
||||||
%global with_python2 0
|
|
||||||
%else
|
|
||||||
%global with_python2 1
|
|
||||||
%endif
|
|
||||||
|
|
||||||
Name: pyxattr
|
Name: pyxattr
|
||||||
Summary: Extended attributes library wrapper for Python
|
Summary: Extended attributes library wrapper for Python
|
||||||
Version: 0.5.3
|
Version: 0.7.2
|
||||||
Release: 18%{?dist}
|
Release: 4%{?dist}
|
||||||
License: LGPLv2+
|
License: LGPLv2+
|
||||||
Group: Development/Libraries
|
URL: https://pyxattr.k1024.org/
|
||||||
URL: http://pyxattr.k1024.org/
|
Source0: %{URL}/downloads/%{name}-%{version}.tar.gz
|
||||||
Source: https://pypi.python.org/packages/source/p/%{name}/%{name}-%{version}.tar.gz
|
Source1: %{URL}/downloads/%{name}-%{version}.tar.gz.asc
|
||||||
Patch0: 0001-use-Py_ssize_t.patch
|
Source2: https://k1024.org/files/key.asc
|
||||||
Patch1: 0002-add-workaround-for-undefined-ENOATTR.patch
|
|
||||||
BuildRequires: libattr-devel
|
|
||||||
%if %{?with_python2}
|
|
||||||
BuildRequires: python2-devel, python2-setuptools
|
|
||||||
%endif
|
|
||||||
%if %{?with_python3}
|
|
||||||
BuildRequires: python3-devel, python3-setuptools
|
|
||||||
%endif # with_python3
|
|
||||||
|
|
||||||
%global _description\
|
BuildRequires: gcc
|
||||||
Python extension module wrapper for libattr. It allows to query, list,\
|
BuildRequires: libattr-devel
|
||||||
add and remove extended attributes from files and directories.
|
BuildRequires: python3-devel
|
||||||
|
BuildRequires: python3-setuptools
|
||||||
|
BuildRequires: gnupg2
|
||||||
|
BuildRequires: %{py3_dist pytest}
|
||||||
|
|
||||||
|
%global _description %{expand:
|
||||||
|
Python extension module wrapper for libattr. It allows to query, list,
|
||||||
|
add and remove extended attributes from files and directories.}
|
||||||
|
|
||||||
%description %_description
|
%description %_description
|
||||||
|
|
||||||
%if %{?with_python2}
|
|
||||||
%package -n python2-%{name}
|
|
||||||
Summary: %summary
|
|
||||||
%{?python_provide:%python_provide python2-%{name}}
|
|
||||||
# Remove before F30
|
|
||||||
Provides: pyxattr = %{version}-%{release}
|
|
||||||
Provides: pyxattr%{?_isa} = %{version}-%{release}
|
|
||||||
Obsoletes: pyxattr < %{version}-%{release}
|
|
||||||
|
|
||||||
%description -n python2-%{name} %_description
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%if %{?with_python3}
|
|
||||||
%package -n python3-%{name}
|
%package -n python3-%{name}
|
||||||
Summary: Extended attributes library wrapper for Python 3
|
Summary: %{summary}
|
||||||
|
%{?python_provide:%python_provide python3-%{name}}
|
||||||
|
|
||||||
%description -n python3-%{name}
|
%description -n python3-%{name} %_description
|
||||||
Python extension module wrapper for libattr. It allows to query, list,
|
|
||||||
add and remove extended attributes from files and directories.
|
|
||||||
|
|
||||||
Python 3 version.
|
|
||||||
%endif # with_python3
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%{gpgverify} --keyring='%{SOURCE2}' --signature='%{SOURCE1}' --data='%{SOURCE0}'
|
||||||
%patch0 -p1
|
%autosetup
|
||||||
%patch1 -p1
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if %{?with_python2}
|
%py3_build
|
||||||
CFLAGS="%{optflags}" %{__python2} setup.py build
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
|
||||||
CFLAGS="%{optflags}" %{__python3} setup.py build
|
|
||||||
%endif # with_python3
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%if %{?with_python2}
|
%py3_install
|
||||||
%{__python2} setup.py install --root="%{buildroot}" --prefix="%{_prefix}"
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
|
||||||
%{__python3} setup.py install --root="%{buildroot}" --prefix="%{_prefix}"
|
|
||||||
%endif # with_python3
|
|
||||||
|
|
||||||
%check
|
%check
|
||||||
# selinux in koji produces unexpected xattrs for tests
|
# selinux in koji produces unexpected xattrs for tests
|
||||||
export TEST_IGNORE_XATTRS=security.selinux
|
export TEST_IGNORE_XATTRS=security.selinux
|
||||||
|
# the module is just a C extension => need to add the installed destination to
|
||||||
|
# PYTHONPATH, otherwise it won't be found
|
||||||
|
export PYTHONPATH=%{buildroot}%{python3_sitearch}:$PYTHONPATH
|
||||||
|
python3 -m pytest tests
|
||||||
|
|
||||||
%if %{?with_python2}
|
|
||||||
%{__python2} setup.py test
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
|
||||||
%{__python3} setup.py test
|
|
||||||
%endif # with_python3
|
|
||||||
|
|
||||||
%if %{?with_python2}
|
|
||||||
%files -n python2-%{name}
|
|
||||||
%defattr(0644,root,root,0755)
|
|
||||||
%{python2_sitearch}/xattr.so
|
|
||||||
%{python2_sitearch}/*egg-info
|
|
||||||
%{!?_licensedir:%global license %%doc}
|
|
||||||
%license COPYING
|
|
||||||
%doc NEWS README
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%if %{?with_python3}
|
|
||||||
%files -n python3-%{name}
|
%files -n python3-%{name}
|
||||||
%defattr(0644,root,root,0755)
|
%{python3_sitearch}/xattr.cpython-%{python3_version_nodots}*
|
||||||
%{python3_sitearch}/xattr.cpython-??m*
|
|
||||||
%{python3_sitearch}/*egg-info
|
%{python3_sitearch}/*egg-info
|
||||||
%{!?_licensedir:%global license %%doc}
|
|
||||||
%license COPYING
|
%license COPYING
|
||||||
%doc NEWS README
|
%doc NEWS README.md
|
||||||
%endif # with_python3
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Sat Aug 04 2018 Milind Changire <mchangir@redhat.com> - 0.5.3-18
|
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 0.7.2-4
|
||||||
- fixes bz#1610029
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
||||||
|
Related: rhbz#1991688
|
||||||
|
|
||||||
* Tue Jun 26 2018 Lumír Balhar <lbalhar@redhat.com> - 0.5.3-17
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 0.7.2-3
|
||||||
- Python 2 subpackage disable by default
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
||||||
|
|
||||||
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.2-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Dec 1 2020 Dan Čermák <dan.cermak@cgc-instruments.com> - 0.7.2-1
|
||||||
|
- New upstream release 0.7.2
|
||||||
|
|
||||||
|
* Wed Jul 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.1-6
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Jun 23 2020 Dan Čermák <dan.cermak@cgc-instruments.com> - 0.7.1-5
|
||||||
|
- BuildRequire python3-setuptools besides python3-devel
|
||||||
|
(see https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/thread/GCPGM34ZGEOVUHSBGZTRYR5XKHTIJ3T7/)
|
||||||
|
|
||||||
|
* Fri May 22 2020 Miro Hrončok <mhroncok@redhat.com> - 0.7.1-4
|
||||||
|
- Rebuilt for Python 3.9
|
||||||
|
|
||||||
|
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.7.1-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Dec 03 2019 Marcin Zajaczkowski <mszpak ATT wp DOTT pl> - 0.7.1-2
|
||||||
|
- Backport RPM specification improvements from sister project pylibacl
|
||||||
|
|
||||||
|
* Tue Nov 26 2019 Dan Čermák <dan.cermak@cgc-instruments.com> - 0.7.1-1
|
||||||
|
- Update to 0.7.1
|
||||||
|
- Drop python2 subpackage
|
||||||
|
- Add gpg signature check
|
||||||
|
|
||||||
|
* Thu Aug 15 2019 Miro Hrončok <mhroncok@redhat.com> - 0.6.1-3
|
||||||
|
- Rebuilt for Python 3.8
|
||||||
|
|
||||||
|
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.6.1-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||||
|
|
||||||
|
* Sun Jul 14 2019 Dan Čermák <dan.cermak@cgc-instruments.com> - 0.6.1-1
|
||||||
|
- Bump version to 0.6.1
|
||||||
|
- Simplify spec file
|
||||||
|
|
||||||
|
* Sat Feb 02 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.6-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Jul 24 2018 Marcin Zajaczkowski <mszpak ATT wp DOTT pl> - 0.5.6-2
|
||||||
|
- Backport patch from 0.6.1 to fix issues with missing ENOATTR in libatttr 2.4.48
|
||||||
|
in Fedora 28/29 (#1603242, related to #1601482) - 0.5.6-1 was broken also in F28
|
||||||
|
|
||||||
|
* Thu Jul 19 2018 Marcin Zajaczkowski <mszpak ATT wp DOTT pl> - 0.5.6-1
|
||||||
|
- Upgrade to 0.5.6 (transitional step before 0.6.x for Fedora <29)
|
||||||
|
- Drop Py_ssize_t patch applied upstream
|
||||||
|
- Update download URL
|
||||||
|
|
||||||
|
* Thu Jul 12 2018 Marcin Zajaczkowski <mszpak ATT wp DOTT pl> - 0.5.3-18
|
||||||
|
- Add gcc to BuildRequires - https://fedoraproject.org/wiki/Changes/Remove_GCC_from_BuildRoot
|
||||||
|
|
||||||
|
* Fri Jun 15 2018 Miro Hrončok <mhroncok@redhat.com> - 0.5.3-17
|
||||||
|
- Rebuilt for Python 3.7
|
||||||
|
|
||||||
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.3-16
|
* Fri Feb 09 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.5.3-16
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
Loading…
Reference in New Issue
Block a user