!4 Fix mainline build error due to need lvalue required as increment and decrement operand
From: @cherry530 Reviewed-by: @yangzhao_kl Signed-off-by: @yangzhao_kl
This commit is contained in:
commit
6abe5c1575
42
Fix-Need-lvalue-for-increment-and-decrement-operand.patch
Normal file
42
Fix-Need-lvalue-for-increment-and-decrement-operand.patch
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
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);
|
||||||
@ -3,12 +3,15 @@
|
|||||||
|
|
||||||
Name: python-%{pname}
|
Name: python-%{pname}
|
||||||
Version: 0.1.2
|
Version: 0.1.2
|
||||||
Release: 1
|
Release: 2
|
||||||
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: %{pypi_source}
|
||||||
|
|
||||||
|
#https://github.com/ruamel/yaml.clib/commit/4777d4333f17c16f40
|
||||||
|
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
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@ -35,12 +38,15 @@ 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*.egg-info
|
||||||
|
|
||||||
%files help
|
%files help
|
||||||
%defattr(-,root,root)
|
%defattr(-,root,root)
|
||||||
%doc README.rst
|
%doc README.rst
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Mar 28 2022 xu_ping <xuping33@huawei.com> - 0.1.2-2
|
||||||
|
- Fix need Lvalue for increment and decrement operand
|
||||||
|
|
||||||
* Mon Mar 2 2020 openEuler Buildteam <buildteam@openeuler.org> - 0.1.2-1
|
* Mon Mar 2 2020 openEuler Buildteam <buildteam@openeuler.org> - 0.1.2-1
|
||||||
- Package init
|
- Package init
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user