Compare commits
No commits in common. "rawhide" and "f34" have entirely different histories.
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,5 +1,3 @@
|
|||||||
/python-poppler-qt5-0.24.2.tar.gz
|
/python-poppler-qt5-0.24.2.tar.gz
|
||||||
/python-poppler-qt5-0.74.0.tar.gz
|
/python-poppler-qt5-0.74.0.tar.gz
|
||||||
/python-poppler-qt5-0.75.0.tar.gz
|
/python-poppler-qt5-0.75.0.tar.gz
|
||||||
/python-poppler-qt5-21.1.0.tar.gz
|
|
||||||
/python-poppler-qt5-21.3.0.tar.gz
|
|
||||||
|
@ -1,113 +0,0 @@
|
|||||||
From 40e71ad88173d02648bceb2438bc0567e60dacd5 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Greiner <code@bnavigator.de>
|
|
||||||
Date: Tue, 23 Feb 2021 17:59:33 +0100
|
|
||||||
Subject: [PATCH] map type QVector< QPair<TYPE, TYPE> > for
|
|
||||||
FormFieldChoice::choicesWithExportValues()
|
|
||||||
|
|
||||||
---
|
|
||||||
types.sip | 93 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
|
|
||||||
1 file changed, 93 insertions(+)
|
|
||||||
|
|
||||||
diff --git a/types.sip b/types.sip
|
|
||||||
index 239b8c9..81cb283 100644
|
|
||||||
--- a/types.sip
|
|
||||||
+++ b/types.sip
|
|
||||||
@@ -331,5 +331,98 @@ template <TYPE>
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
+/**
|
|
||||||
+ * Convert QVector< QPair<TYPE, TYPE> >
|
|
||||||
+ * from and to a Python list of a 2-item tuple
|
|
||||||
+ */
|
|
||||||
+
|
|
||||||
+template<TYPE>
|
|
||||||
+%MappedType QVector< QPair<TYPE, TYPE> >
|
|
||||||
+{
|
|
||||||
+%TypeHeaderCode
|
|
||||||
+#include <qvector.h>
|
|
||||||
+#include <qpair.h>
|
|
||||||
+%End
|
|
||||||
+
|
|
||||||
+%ConvertFromTypeCode
|
|
||||||
+ // Create the list.
|
|
||||||
+ PyObject *l;
|
|
||||||
+
|
|
||||||
+ if ((l = PyList_New(sipCpp->size())) == NULL)
|
|
||||||
+ return NULL;
|
|
||||||
+
|
|
||||||
+ // Set the list elements.
|
|
||||||
+ for (int i = 0; i < sipCpp->size(); ++i)
|
|
||||||
+ {
|
|
||||||
+ QPair<TYPE, TYPE>* p = new QPair<TYPE, TYPE>(sipCpp->at(i));
|
|
||||||
+ PyObject *ptuple = PyTuple_New(2);
|
|
||||||
+ PyObject *pfirst;
|
|
||||||
+ PyObject *psecond;
|
|
||||||
+
|
|
||||||
+ TYPE *sfirst = new TYPE(p->first);
|
|
||||||
+ if ((pfirst = sipConvertFromType(sfirst, sipType_TYPE, sipTransferObj)) == NULL)
|
|
||||||
+ {
|
|
||||||
+ Py_DECREF(l);
|
|
||||||
+ Py_DECREF(ptuple);
|
|
||||||
+ return NULL;
|
|
||||||
+ }
|
|
||||||
+ PyTuple_SET_ITEM(ptuple, 0, pfirst);
|
|
||||||
+
|
|
||||||
+ TYPE *ssecond = new TYPE(p->second);
|
|
||||||
+ if ((psecond = sipConvertFromType(ssecond, sipType_TYPE, sipTransferObj)) == NULL)
|
|
||||||
+ {
|
|
||||||
+ Py_DECREF(l);
|
|
||||||
+ Py_DECREF(ptuple);
|
|
||||||
+ Py_DECREF(pfirst);
|
|
||||||
+ return NULL;
|
|
||||||
+ }
|
|
||||||
+ PyTuple_SET_ITEM(ptuple, 1, psecond);
|
|
||||||
+
|
|
||||||
+ PyList_SET_ITEM(l, i, ptuple);
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ return l;
|
|
||||||
+%End
|
|
||||||
+
|
|
||||||
+%ConvertToTypeCode
|
|
||||||
+ const sipTypeDef* qpair_type = sipFindType("QPair<TYPE, TYPE>");
|
|
||||||
+
|
|
||||||
+ // Check the type if that is all that is required.
|
|
||||||
+ if (sipIsErr == NULL)
|
|
||||||
+ {
|
|
||||||
+ if (!PySequence_Check(sipPy))
|
|
||||||
+ return 0;
|
|
||||||
+
|
|
||||||
+ for (int i = 0; i < PySequence_Size(sipPy); ++i)
|
|
||||||
+ if (!sipCanConvertToType(PySequence_ITEM(sipPy, i), qpair_type, SIP_NOT_NONE))
|
|
||||||
+ return 0;
|
|
||||||
+
|
|
||||||
+ return 1;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+
|
|
||||||
+ QVector< QPair<TYPE, TYPE> > *qv = new QVector< QPair<TYPE, TYPE> >;
|
|
||||||
+
|
|
||||||
+ for (int i = 0; i < PySequence_Size(sipPy); ++i)
|
|
||||||
+ {
|
|
||||||
+ int state;
|
|
||||||
+ QPair<TYPE, TYPE> * p = reinterpret_cast< QPair<TYPE, TYPE> * >(sipConvertToType(PySequence_ITEM(sipPy, i), qpair_type, sipTransferObj, SIP_NOT_NONE, &state, sipIsErr));
|
|
||||||
+
|
|
||||||
+ if (*sipIsErr)
|
|
||||||
+ {
|
|
||||||
+ sipReleaseType(p, qpair_type, state);
|
|
||||||
+ delete qv;
|
|
||||||
+ return 0;
|
|
||||||
+ }
|
|
||||||
+ qv->append(*p);
|
|
||||||
+ sipReleaseType(p, qpair_type, state);
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ *sipCppPtr = qv;
|
|
||||||
+ return sipGetState(sipTransferObj);
|
|
||||||
+%End
|
|
||||||
+
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
|
|
||||||
/* kate: indent-width 4; space-indent on; hl c++; indent-mode cstyle; */
|
|
@ -1,11 +0,0 @@
|
|||||||
--- setup.py~ 2021-01-07 09:30:52.000000000 -0600
|
|
||||||
+++ setup.py 2021-02-23 11:32:14.766853522 -0600
|
|
||||||
@@ -138,7 +138,7 @@
|
|
||||||
def initialize_options (self):
|
|
||||||
build_ext_base.initialize_options(self)
|
|
||||||
self.poppler_version = None
|
|
||||||
- self.qmake_bin = 'qmake'
|
|
||||||
+ self.qmake_bin = 'qmake-qt5'
|
|
||||||
self.sip_bin = None
|
|
||||||
self.qt_include_dir = None
|
|
||||||
self.pyqt_sip_dir = None
|
|
@ -1,19 +1,17 @@
|
|||||||
Name: python3-poppler-qt5
|
Name: python3-poppler-qt5
|
||||||
Version: 21.3.0
|
Version: 0.75.0
|
||||||
Release: 3%{?dist}
|
Release: 7%{?dist}
|
||||||
Summary: Python bindings for the Poppler PDF rendering library
|
Summary: Python bindings for the Poppler PDF rendering library
|
||||||
|
|
||||||
License: LGPLv2+
|
License: LGPLv2+
|
||||||
URL: https://github.com/frescobaldi/python-poppler-qt5
|
URL: https://github.com/frescobaldi/python-poppler-qt5
|
||||||
Source0: %{url}/archive/v%{version}.tar.gz#/python-poppler-qt5-%{version}.tar.gz
|
Source0: %{url}/archive/v%{version}.tar.gz#/python-poppler-qt5-%{version}.tar.gz
|
||||||
Patch0: binpaths.patch
|
|
||||||
Patch1: 40e71ad88173d02648bceb2438bc0567e60dacd5.patch
|
|
||||||
Requires: python3-qt5
|
Requires: python3-qt5
|
||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
BuildRequires: python3-setuptools
|
BuildRequires: python3-setuptools
|
||||||
BuildRequires: python3-qt5-devel
|
BuildRequires: python3-qt5-devel
|
||||||
BuildRequires: %{py3_dist sip} >= 5
|
BuildRequires: python3-sip-devel >= 4.9.1
|
||||||
BuildRequires: %{py3_dist PyQt-builder}
|
%{?_sip_api:Requires: python%{python3_pkgversion}-pyqt5-sip-api(%{_sip_api_major}) >= %{_sip_api}}
|
||||||
BuildRequires: pkgconfig(poppler-qt5)
|
BuildRequires: pkgconfig(poppler-qt5)
|
||||||
|
|
||||||
# we don't want to provide private python extension libs
|
# we don't want to provide private python extension libs
|
||||||
@ -30,52 +28,22 @@ run programs written in Python 3 and using Poppler set.
|
|||||||
%prep
|
%prep
|
||||||
%setup -qn python-poppler-qt5-%{version}
|
%setup -qn python-poppler-qt5-%{version}
|
||||||
|
|
||||||
%patch0 -p0
|
sed -i s/\'qmake\'/\'qmake-qt5\'/g setup.py
|
||||||
#%patch1 -p1
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
sip-build --qmake=%{_qt5_qmake} --verbose --no-make \
|
%py3_build
|
||||||
--qmake-setting 'QMAKE_CFLAGS_RELEASE="%{optflags}"' \
|
|
||||||
--qmake-setting 'QMAKE_CXXFLAGS_RELEASE="%{optflags}"' \
|
|
||||||
--qmake-setting 'QMAKE_LFLAGS_RELEASE="%{?__global_ldflags}"'
|
|
||||||
%make_build -C build
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%make_install INSTALL_ROOT=%{buildroot} -C build
|
%py3_install
|
||||||
chmod +x %{buildroot}/%{python3_sitearch}/*.so
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%license LICENSE
|
%license LICENSE
|
||||||
%doc README.rst
|
%doc README.rst
|
||||||
%{python3_sitearch}/popplerqt5.cpython-*.so
|
%{python3_sitearch}/popplerqt5.cpython-*.so
|
||||||
%{python3_sitearch}/python_poppler*
|
%{python3_sitearch}/python_poppler*
|
||||||
%{python3_sitearch}/PyQt5/bindings/popplerqt5
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 21.3.0-3
|
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
|
||||||
|
|
||||||
* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 21.3.0-2
|
|
||||||
- Rebuilt for Python 3.11
|
|
||||||
|
|
||||||
* Tue May 10 2022 Gwyn Ciesla <gwync@protonmail.com> - 21.3.0-1
|
|
||||||
- 21.3.0
|
|
||||||
|
|
||||||
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 21.1.0-5
|
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
|
||||||
|
|
||||||
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 21.1.0-4
|
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
|
||||||
|
|
||||||
* Sat Jul 03 2021 Scott Talbert <swt@techie.net> - 21.1.0-3
|
|
||||||
- Update to build with sip5+
|
|
||||||
|
|
||||||
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 21.1.0-2
|
|
||||||
- Rebuilt for Python 3.10
|
|
||||||
|
|
||||||
* Tue Feb 23 2021 Gwyn Ciesla <gwync@protonmail.com> - 21.1.0-1
|
|
||||||
- 21.1.0
|
|
||||||
|
|
||||||
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.75.0-7
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.75.0-7
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||||
|
|
||||||
|
2
sources
2
sources
@ -1 +1 @@
|
|||||||
SHA512 (python-poppler-qt5-21.3.0.tar.gz) = cc942a860c2c999ff04fb0468b1556b0e23e7aa19a0185a39c5e903e717dca64bcbd51b8fe34b6885bd789cbf5cc1080c2ca1dcee30b3e69fa1721618e8db278
|
SHA512 (python-poppler-qt5-0.75.0.tar.gz) = 2f03036a2eaeb8e28875f19a813ff85a91c1e9a94301bdb736ecc50e7ececb4de2622728e6fecbf64e114435529f82b6afd23d772e2d3910ae03d5d2b5da3205
|
||||||
|
Loading…
Reference in New Issue
Block a user