!5 Update to 0.2.6
From: @starlet-dx Reviewed-by: @myeuler Signed-off-by: @myeuler
This commit is contained in:
commit
dd1462c955
@ -1,42 +0,0 @@
|
|||||||
diff --git a/_ruamel_yaml.c b/_ruamel_yaml.c
|
|
||||||
index c81694a..587853c 100644
|
|
||||||
--- a/_ruamel_yaml.c
|
|
||||||
+++ b/_ruamel_yaml.c
|
|
||||||
@@ -496,6 +496,13 @@ static CYTHON_INLINE void * PyThread_tss_get(Py_tss_t *key) {
|
|
||||||
#ifndef PySet_CheckExact
|
|
||||||
#define PySet_CheckExact(obj) (Py_TYPE(obj) == &PySet_Type)
|
|
||||||
#endif
|
|
||||||
+#if PY_VERSION_HEX >= 0x030900A4
|
|
||||||
+ #define __Pyx_SET_REFCNT(obj, refcnt) Py_SET_REFCNT(obj, refcnt)
|
|
||||||
+ #define __Pyx_SET_SIZE(obj, size) Py_SET_SIZE(obj, size)
|
|
||||||
+#else
|
|
||||||
+ #define __Pyx_SET_REFCNT(obj, refcnt) Py_SET_REFCNT(obj) =(refcnt)
|
|
||||||
+ #define __Pyx_SET_SIZE(obj, size) Py_SET_SIZE(obj) = (size)
|
|
||||||
+#endif
|
|
||||||
#if CYTHON_ASSUME_SAFE_MACROS
|
|
||||||
#define __Pyx_PySequence_SIZE(seq) Py_SIZE(seq)
|
|
||||||
#else
|
|
||||||
@@ -23874,9 +23881,9 @@ static void __pyx_tp_dealloc_12_ruamel_yaml_CParser(PyObject *o) {
|
|
||||||
{
|
|
||||||
PyObject *etype, *eval, *etb;
|
|
||||||
PyErr_Fetch(&etype, &eval, &etb);
|
|
||||||
- ++Py_REFCNT(o);
|
|
||||||
+ __Pyx_SET_REFCNT(o, PyREFCNT(o) + 1);
|
|
||||||
__pyx_pw_12_ruamel_yaml_7CParser_3__dealloc__(o);
|
|
||||||
- --Py_REFCNT(o);
|
|
||||||
+ __Pyx_SET_REFCNT(o, PyREFCNT(o) - 1);
|
|
||||||
PyErr_Restore(etype, eval, etb);
|
|
||||||
}
|
|
||||||
Py_CLEAR(p->stream);
|
|
||||||
@@ -24047,9 +24054,9 @@ static void __pyx_tp_dealloc_12_ruamel_yaml_CEmitter(PyObject *o) {
|
|
||||||
{
|
|
||||||
PyObject *etype, *eval, *etb;
|
|
||||||
PyErr_Fetch(&etype, &eval, &etb);
|
|
||||||
- ++Py_REFCNT(o);
|
|
||||||
+ __Pyx_SET_REFCNT(o, PyREFCNT(o) + 1);
|
|
||||||
__pyx_pw_12_ruamel_yaml_8CEmitter_3__dealloc__(o);
|
|
||||||
- --Py_REFCNT(o);
|
|
||||||
+ __Pyx_SET_REFCNT(o, PyREFCNT(o) - 1);
|
|
||||||
PyErr_Restore(etype, eval, etb);
|
|
||||||
}
|
|
||||||
Py_CLEAR(p->stream);
|
|
||||||
38
fix-typecasts-s390x.patch
Normal file
38
fix-typecasts-s390x.patch
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
diff -up ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pxd.s390x ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pxd
|
||||||
|
--- ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pxd.s390x 2022-05-11 17:33:41.727476439 +0200
|
||||||
|
+++ ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pxd 2022-05-11 17:34:34.197700039 +0200
|
||||||
|
@@ -86,10 +86,10 @@ cdef extern from "_ruamel_yaml.h":
|
||||||
|
YAML_MAPPING_END_EVENT
|
||||||
|
|
||||||
|
ctypedef int yaml_read_handler_t(void *data, char *buffer,
|
||||||
|
- int size, int *size_read) except 0
|
||||||
|
+ size_t size, size_t *size_read) except 0
|
||||||
|
|
||||||
|
ctypedef int yaml_write_handler_t(void *data, char *buffer,
|
||||||
|
- int size) except 0
|
||||||
|
+ size_t size) except 0
|
||||||
|
|
||||||
|
ctypedef struct yaml_mark_t:
|
||||||
|
int index
|
||||||
|
diff -up ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pyx.s390x ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pyx
|
||||||
|
--- ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pyx.s390x 2022-05-12 13:05:17.540913818 +0200
|
||||||
|
+++ ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/_ruamel_yaml.pyx 2022-05-12 13:06:38.211269280 +0200
|
||||||
|
@@ -904,7 +904,7 @@ cdef class CParser:
|
||||||
|
raise error
|
||||||
|
return 1
|
||||||
|
|
||||||
|
-cdef int input_handler(void *data, char *buffer, int size, int *read) except 0:
|
||||||
|
+cdef int input_handler(void *data, char *buffer, size_t size, size_t *read) except 0:
|
||||||
|
cdef CParser parser
|
||||||
|
parser = <CParser>data
|
||||||
|
if parser.stream_cache is None:
|
||||||
|
@@ -1514,7 +1514,7 @@ cdef class CEmitter:
|
||||||
|
self.ascend_resolver()
|
||||||
|
return 1
|
||||||
|
|
||||||
|
-cdef int output_handler(void *data, char *buffer, int size) except 0:
|
||||||
|
+cdef int output_handler(void *data, char *buffer, size_t size) except 0:
|
||||||
|
cdef CEmitter emitter
|
||||||
|
emitter = <CEmitter>data
|
||||||
|
if emitter.dump_unicode == 0:
|
||||||
|
diff -up ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/yaml.h.s390x ruamel-yaml-clib-code-85e484db2b7c37107e4edd2ae6fc380877bbc08e/yaml.h
|
||||||
@ -1,16 +1,16 @@
|
|||||||
%global pypi_name ruamel.yaml.clib
|
%global pypi_name ruamel.yaml.clib
|
||||||
%global pname ruamel-yaml-clib
|
%global pname ruamel-yaml-clib
|
||||||
|
%global hash 85e484db2b7c37107e4edd2ae6fc380877bbc08e
|
||||||
|
|
||||||
Name: python-%{pname}
|
Name: python-%{pname}
|
||||||
Version: 0.1.2
|
Version: 0.2.6
|
||||||
Release: 2
|
Release: 1
|
||||||
Summary: C version of reader, parser and emitter for ruamel.yaml derived from libyaml
|
Summary: C version of reader, parser and emitter for ruamel.yaml derived from libyaml
|
||||||
License: MIT
|
License: MIT
|
||||||
URL: https://bitbucket.org/ruamel/yaml.clib
|
URL: https://bitbucket.org/ruamel/yaml.clib
|
||||||
Source0: %{pypi_source}
|
Source0: https://sourceforge.net/code-snapshots/hg/r/ru/ruamel-yaml-clib/code/ruamel-yaml-clib-code-%{hash}.zip
|
||||||
|
|
||||||
#https://github.com/ruamel/yaml.clib/commit/4777d4333f17c16f40
|
Patch0: fix-typecasts-s390x.patch
|
||||||
Patch0: Fix-Need-lvalue-for-increment-and-decrement-operand.patch
|
|
||||||
|
|
||||||
BuildRequires: gcc libyaml-devel python3-devel python3-setuptools
|
BuildRequires: gcc libyaml-devel python3-devel python3-setuptools
|
||||||
|
|
||||||
@ -19,7 +19,7 @@ It is the C based reader/scanner and emitter for ruamel.yaml.
|
|||||||
|
|
||||||
%package -n python3-%{pname}
|
%package -n python3-%{pname}
|
||||||
Summary: %{summary}
|
Summary: %{summary}
|
||||||
Requires: python3-setuptools
|
Requires: python3-setuptools python3-ruamel-yaml
|
||||||
|
|
||||||
%description -n python3-%{pname}
|
%description -n python3-%{pname}
|
||||||
It is the C based reader/scanner and emitter for ruamel.yaml.
|
It is the C based reader/scanner and emitter for ruamel.yaml.
|
||||||
@ -27,7 +27,7 @@ It is the C based reader/scanner and emitter for ruamel.yaml.
|
|||||||
%package_help
|
%package_help
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -n %{pypi_name}-%{version} -p1
|
%autosetup -n %{pname}-code-%{hash} -p1
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%py3_build
|
%py3_build
|
||||||
@ -38,13 +38,16 @@ It is the C based reader/scanner and emitter for ruamel.yaml.
|
|||||||
%files -n python3-%{pname}
|
%files -n python3-%{pname}
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
%{python3_sitearch}/_ruamel_yaml.cpython-*
|
%{python3_sitearch}/_ruamel_yaml.cpython-*
|
||||||
%{python3_sitearch}/%{pypi_name}-%{version}-py*.egg-info
|
%{python3_sitearch}/%{pypi_name}-%{version}-py%{python3_version}.egg-info
|
||||||
|
|
||||||
%files help
|
%files help
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%doc README.rst
|
%doc README.rst
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri May 20 2022 yaoxin <yaoxin30@h-partners.com> - 0.2.6-1
|
||||||
|
- Update to 0.2.6
|
||||||
|
|
||||||
* Mon Mar 28 2022 xu_ping <xuping33@huawei.com> - 0.1.2-2
|
* Mon Mar 28 2022 xu_ping <xuping33@huawei.com> - 0.1.2-2
|
||||||
- Fix need Lvalue for increment and decrement operand
|
- Fix need Lvalue for increment and decrement operand
|
||||||
|
|
||||||
|
|||||||
Binary file not shown.
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user