14
0
2022-04-20 06:22:08 +00:00
committed by Git OBS Bridge
parent 8872d4342b
commit a53385baa7
2 changed files with 23 additions and 6 deletions

View File

@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Wed Apr 20 06:19:11 UTC 2022 - Matej Cepl <mcepl@suse.com>
- Clean up of the SPEC file.
-------------------------------------------------------------------
Wed Feb 2 13:12:20 UTC 2022 - Bernhard Wiedemann <bwiedemann@suse.com>

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-PyQRCode
#
# Copyright (c) 2021 SUSE LLC
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -24,16 +24,18 @@ Version: 1.3.6
Release: 0
Summary: Python 3 module to generate QR Codes
License: MIT
URL: https://github.com/mnooner256/pyqrcode
URL: https://github.com/pyqrcode/pyqrcodeNG
# This is unofficial fork with some additional fixes, the canonical
# upstream repository is dead.
Source: https://github.com/pyqrcode/pyqrcodeNG/archive/refs/tags/%{version}.tar.gz#/pyqrcodeNG-%{version}.tar.gz
# PATCH-FIX-UPSTREAM https://github.com/pyqrcode/pyqrcodeNG/pull/18
Patch0: reproducible.patch
BuildRequires: %{python_module Sphinx}
BuildRequires: %{python_module pip}
BuildRequires: %{python_module pypng}
BuildRequires: %{python_module pytest}
BuildRequires: %{python_module setuptools}
BuildRequires: %{python_module wheel}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires(post): update-alternatives
@@ -44,18 +46,24 @@ BuildArch: noarch
%description
The PyQRCode module is a QR code generator that is simple to use and written in pure python. The module can automates most of the building process for creating QR codes. Most codes can be created using only two lines of code!
%package -n %{name}-doc
Summary: Documentation files for %{name}
%description -n %{name}-doc
HTML Documentation for %{name}.
%prep
%autosetup -p1 -n pyqrcodeNG-%{version}
sed -i -e '1{\@^#!%{_bindir}/env python@d}' pyqrcodeng/{cli,qrspecial}.py
%build
%python_build
%pyproject_wheel
python3 setup.py build_sphinx -v
rm -rvf build/sphinx/html/.buildinfo
%install
%python_install
%pyproject_install
%python_clone -a %{buildroot}%{_bindir}/pyqr
%python_expand %fdupes %{buildroot}/%{$python_sitelib}
@@ -70,9 +78,13 @@ rm -rvf build/sphinx/html/.buildinfo
%files %{python_files}
%license LICENSE
%doc README.rst CHANGES.rst build/sphinx/html
%doc README.rst CHANGES.rst
%{_bindir}/pyqr-%{python_bin_suffix}
%python_alternative %{_bindir}/pyqr
%{python_sitelib}/*
%{python_sitelib}/PyQRCodeNG-%{version}*-info
%{python_sitelib}/pyqrcodeng
%files -n %{name}-doc
%doc build/sphinx/html
%changelog