Hello community,
here is the log from the commit of package python-pdfminer.six for
openSUSE:Factory checked in at 2020-05-26 17:16:59
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pdfminer.six (Old)
and /work/SRC/openSUSE:Factory/.python-pdfminer.six.new.2738 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pdfminer.six"
Tue May 26 17:16:59 2020 rev:2 rq:807651 version:20200124
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-pdfminer.six/python-pdfminer.six.changes
2020-02-18 15:18:55.188735870 +0100
+++
/work/SRC/openSUSE:Factory/.python-pdfminer.six.new.2738/python-pdfminer.six.changes
2020-05-26 17:17:59.195802765 +0200
@@ -1,0 +2,5 @@
+Wed May 20 07:26:10 UTC 2020 - Petr Gajdos <[email protected]>
+
+- %python3_only -> %python_alternative
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-pdfminer.six.spec ++++++
--- /var/tmp/diff_new_pack.7kczm9/_old 2020-05-26 17:18:00.383805319 +0200
+++ /var/tmp/diff_new_pack.7kczm9/_new 2020-05-26 17:18:00.383805319 +0200
@@ -1,7 +1,7 @@
#
# spec file for package python-pdfminer.six
#
-# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2020 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -12,7 +12,9 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
+#
+
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
@@ -24,17 +26,19 @@
URL: https://github.com/pdfminer/pdfminer.six
Source:
https://github.com/pdfminer/pdfminer.six/archive/%{version}.tar.gz#/pdfminer.six-%{version}.tar.gz
BuildRequires: %{python_module chardet}
+BuildRequires: %{python_module nose}
BuildRequires: %{python_module pycryptodome}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module six}
BuildRequires: %{python_module sortedcontainers}
-BuildRequires: %{python_module nose}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-chardet
Requires: python-pycryptodome
Requires: python-six
Requires: python-sortedcontainers
+Requires(post): update-alternatives
+Requires(postun): update-alternatives
Provides: python-pdfminer3k = %{version}
Obsoletes: python-pdfminer3k < %{version}
BuildArch: noarch
@@ -55,7 +59,7 @@
%prep
%setup -q -n pdfminer.six-%{version}
sed -i -e '/^#!\//, 1d' pdfminer/psparser.py
-sed -i '1i #!/usr/bin/python3' tools/dumppdf.py tools/pdf2txt.py
+sed -i '1i #!%{_bindir}/python3' tools/dumppdf.py tools/pdf2txt.py
%build
%python_build
@@ -66,15 +70,25 @@
mv %{buildroot}%{_bindir}/dumppdf.py %{buildroot}%{_bindir}/dumppdf
mv %{buildroot}%{_bindir}/pdf2txt.py %{buildroot}%{_bindir}/pdf2txt
+%python_clone -a %{buildroot}%{_bindir}/pdf2txt
+%python_clone -a %{buildroot}%{_bindir}/dumppdf
%check
%python_expand nosetests-%{$python_bin_suffix} -v
+%post
+%python_install_alternative pdf2txt
+%python_install_alternative dumppdf
+
+%postun
+%python_uninstall_alternative pdf2txt
+%python_uninstall_alternative dumppdf
+
%files %{python_files}
%license LICENSE
%doc README.md
-%python3_only %{_bindir}/dumppdf
-%python3_only %{_bindir}/pdf2txt
+%python_alternative %{_bindir}/dumppdf
+%python_alternative %{_bindir}/pdf2txt
%{python_sitelib}/pdfminer*
%changelog