forked from pool/python-ws4py
- Switch to pyproject macros.
- No more greedy globs in %files. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-ws4py?expand=0&rev=15
This commit is contained in:
@@ -16,7 +16,6 @@
|
||||
#
|
||||
|
||||
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
%global flavor @BUILD_FLAVOR@%{nil}
|
||||
%if "%{flavor}" == "test"
|
||||
%define psuffix -test
|
||||
@@ -33,7 +32,9 @@ License: BSD-3-Clause
|
||||
Group: Development/Languages/Python
|
||||
URL: https://github.com/Lawouach/WebSocket-for-Python
|
||||
Source: https://files.pythonhosted.org/packages/source/w/ws4py/ws4py-%{version}.tar.gz
|
||||
BuildRequires: %{python_module pip}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
BuildRequires: %{python_module wheel}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
BuildArch: noarch
|
||||
@@ -56,11 +57,11 @@ defined in RFC 6455.
|
||||
rm test/test_cherrypy.py
|
||||
|
||||
%build
|
||||
%python_build
|
||||
%pyproject_wheel
|
||||
|
||||
%install
|
||||
%if !%{with test}
|
||||
%python_install
|
||||
%pyproject_install
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
%endif
|
||||
|
||||
@@ -75,7 +76,8 @@ sed -i 's:from mock:from unittest.mock:' test/test_*.py
|
||||
%files %{python_files}
|
||||
%license LICENSE
|
||||
%doc README.md
|
||||
%{python_sitelib}/*
|
||||
%{python_sitelib}/ws4py
|
||||
%{python_sitelib}/ws4py-%{version}.dist-info
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
|
Reference in New Issue
Block a user