forked from pool/python-pybeam
- Remove doc conditional as it is never built due to always being
as a bcond_with - Use unittest directly to avoid setup.py test deprecation - Allow usage with construct 2.10 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pybeam?expand=0&rev=30
This commit is contained in:
committed by
Git OBS Bridge
parent
3b3573e3f9
commit
4371383c21
@@ -1,3 +1,11 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed Feb 12 16:47:55 UTC 2020 - Tomáš Chvátal <tchvatal@suse.com>
|
||||||
|
|
||||||
|
- Remove doc conditional as it is never built due to always being
|
||||||
|
as a bcond_with
|
||||||
|
- Use unittest directly to avoid setup.py test deprecation
|
||||||
|
- Allow usage with construct 2.10
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sun Dec 15 02:38:15 UTC 2019 - Stefan Brüns <stefan.bruens@rwth-aachen.de>
|
Sun Dec 15 02:38:15 UTC 2019 - Stefan Brüns <stefan.bruens@rwth-aachen.de>
|
||||||
|
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package python-pybeam
|
# spec file for package python
|
||||||
#
|
#
|
||||||
# Copyright (c) 2019 SUSE LLC
|
# Copyright (c) 2020 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@@ -19,12 +19,10 @@
|
|||||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||||
%global flavor @BUILD_FLAVOR@%{nil}
|
%global flavor @BUILD_FLAVOR@%{nil}
|
||||||
%if "%{flavor}" == "test"
|
%if "%{flavor}" == "test"
|
||||||
%bcond_with doc
|
|
||||||
%bcond_without test
|
|
||||||
%define psuffix -test
|
%define psuffix -test
|
||||||
|
%bcond_without test
|
||||||
%endif
|
%endif
|
||||||
%if "%{flavor}" == ""
|
%if "%{flavor}" == ""
|
||||||
%bcond_with doc
|
|
||||||
%bcond_with test
|
%bcond_with test
|
||||||
%endif
|
%endif
|
||||||
Name: python-pybeam%{?psuffix}
|
Name: python-pybeam%{?psuffix}
|
||||||
@@ -33,25 +31,19 @@ Release: 0
|
|||||||
Summary: Python module to parse Erlang BEAM files
|
Summary: Python module to parse Erlang BEAM files
|
||||||
License: MIT
|
License: MIT
|
||||||
Group: Development/Languages/Python
|
Group: Development/Languages/Python
|
||||||
URL: http://github.com/matwey/pybeam
|
URL: https://github.com/matwey/pybeam
|
||||||
Source: https://files.pythonhosted.org/packages/source/p/pybeam/pybeam-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/p/pybeam/pybeam-%{version}.tar.gz
|
||||||
Patch0: make_sphinx_optional.patch
|
Patch0: make_sphinx_optional.patch
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
%if %{with doc}
|
|
||||||
BuildRequires: %{python_module Sphinx}
|
|
||||||
BuildRequires: %{python_module construct < 2.10}
|
|
||||||
BuildRequires: %{python_module construct >= 2.9}
|
|
||||||
%endif
|
|
||||||
%if %{with test}
|
|
||||||
BuildRequires: %{python_module pybeam == %{version}}
|
|
||||||
BuildRequires: %{python_module six}
|
|
||||||
%endif
|
|
||||||
Requires: python-construct < 2.10
|
|
||||||
Requires: python-construct >= 2.9
|
Requires: python-construct >= 2.9
|
||||||
Requires: python-six >= 1.4.0
|
Requires: python-six >= 1.4.0
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
%if %{with test}
|
||||||
|
BuildRequires: %{python_module construct >= 2.9}
|
||||||
|
BuildRequires: %{python_module six}
|
||||||
|
%endif
|
||||||
%python_subpackages
|
%python_subpackages
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@@ -60,7 +52,7 @@ imports, exports, atoms, as well as compile info and attribute
|
|||||||
chunks in pretty python format.
|
chunks in pretty python format.
|
||||||
|
|
||||||
%package -n %{name}-doc
|
%package -n %{name}-doc
|
||||||
Summary: API Documentation for %name
|
Summary: API Documentation for %{name}
|
||||||
Group: Documentation/HTML
|
Group: Documentation/HTML
|
||||||
|
|
||||||
%description -n %{name}-doc
|
%description -n %{name}-doc
|
||||||
@@ -71,14 +63,13 @@ chunks in pretty python format.
|
|||||||
%prep
|
%prep
|
||||||
%setup -q -n pybeam-%{version}
|
%setup -q -n pybeam-%{version}
|
||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
|
# do not block the new python-construct
|
||||||
|
sed -i -e ',<2.10' setup.py
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if %{without test}
|
%if %{without test}
|
||||||
%python_build
|
%python_build
|
||||||
%endif
|
%endif
|
||||||
%if %{with doc}
|
|
||||||
%python_build build_sphinx
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%if %{without test}
|
%if %{without test}
|
||||||
@@ -88,7 +79,7 @@ chunks in pretty python format.
|
|||||||
|
|
||||||
%check
|
%check
|
||||||
%if %{with test}
|
%if %{with test}
|
||||||
%python_exec setup.py test
|
%python_exec -m unittest discover
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if %{without test}
|
%if %{without test}
|
||||||
@@ -97,9 +88,4 @@ chunks in pretty python format.
|
|||||||
%{python_sitelib}/*
|
%{python_sitelib}/*
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if %{with doc}
|
|
||||||
%files -n %{name}-doc
|
|
||||||
%doc build/html
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Reference in New Issue
Block a user