|
|
@@ -1,7 +1,7 @@
|
|
|
|
#
|
|
|
|
#
|
|
|
|
# spec file for package python-portpicker
|
|
|
|
# spec file for package python-portpicker
|
|
|
|
#
|
|
|
|
#
|
|
|
|
# Copyright (c) 2024 SUSE LLC
|
|
|
|
# Copyright (c) 2025 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
|
|
|
@@ -16,7 +16,7 @@
|
|
|
|
#
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
|
|
%bcond_without libalternatives
|
|
|
|
Name: python-portpicker
|
|
|
|
Name: python-portpicker
|
|
|
|
Version: 1.6.0
|
|
|
|
Version: 1.6.0
|
|
|
|
Release: 0
|
|
|
|
Release: 0
|
|
|
@@ -25,12 +25,14 @@ License: Apache-2.0
|
|
|
|
Group: Development/Libraries/Python
|
|
|
|
Group: Development/Libraries/Python
|
|
|
|
URL: https://github.com/google/python_portpicker
|
|
|
|
URL: https://github.com/google/python_portpicker
|
|
|
|
Source0: https://files.pythonhosted.org/packages/source/p/portpicker/portpicker-%{version}.tar.gz
|
|
|
|
Source0: https://files.pythonhosted.org/packages/source/p/portpicker/portpicker-%{version}.tar.gz
|
|
|
|
|
|
|
|
BuildRequires: %{python_module pip}
|
|
|
|
BuildRequires: %{python_module setuptools}
|
|
|
|
BuildRequires: %{python_module setuptools}
|
|
|
|
|
|
|
|
BuildRequires: %{python_module wheel}
|
|
|
|
|
|
|
|
BuildRequires: alts
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: net-tools-deprecated
|
|
|
|
BuildRequires: net-tools-deprecated
|
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
Requires(post): update-alternatives
|
|
|
|
Requires: alts
|
|
|
|
Requires(postun):update-alternatives
|
|
|
|
|
|
|
|
BuildArch: noarch
|
|
|
|
BuildArch: noarch
|
|
|
|
%python_subpackages
|
|
|
|
%python_subpackages
|
|
|
|
|
|
|
|
|
|
|
@@ -44,26 +46,25 @@ harnesses that launch local servers.
|
|
|
|
test -f setup.py || echo "import setuptools; setuptools.setup()" > setup.py
|
|
|
|
test -f setup.py || echo "import setuptools; setuptools.setup()" > setup.py
|
|
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
%build
|
|
|
|
%python_build
|
|
|
|
%pyproject_wheel
|
|
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
%install
|
|
|
|
%python_install
|
|
|
|
%pyproject_install
|
|
|
|
%python_clone -a %{buildroot}%{_bindir}/portserver.py
|
|
|
|
%python_clone -a %{buildroot}%{_bindir}/portserver.py
|
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
|
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
%check
|
|
|
|
%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} $python src/tests/portpicker_test.py
|
|
|
|
%python_expand PYTHONPATH=%{buildroot}%{$python_sitelib} $python src/tests/portpicker_test.py
|
|
|
|
|
|
|
|
|
|
|
|
%post
|
|
|
|
%pre
|
|
|
|
%python_install_alternative portserver.py
|
|
|
|
%python_libalternatives_reset_alternative portserver.py
|
|
|
|
|
|
|
|
|
|
|
|
%postun
|
|
|
|
|
|
|
|
%python_uninstall_alternative portserver.py
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
%files %{python_files}
|
|
|
|
%files %{python_files}
|
|
|
|
%license LICENSE
|
|
|
|
%license LICENSE
|
|
|
|
%doc CONTRIBUTING.md README.md
|
|
|
|
%doc CONTRIBUTING.md README.md
|
|
|
|
%{python_sitelib}/*
|
|
|
|
%{python_sitelib}/portpicker.py
|
|
|
|
|
|
|
|
%pycache_only %{python_sitelib}/__pycache__/portpicker*
|
|
|
|
|
|
|
|
%{python_sitelib}/portpicker-%{version}*-info
|
|
|
|
# import asyncio
|
|
|
|
# import asyncio
|
|
|
|
%python_alternative %{_bindir}/portserver.py
|
|
|
|
%python_alternative %{_bindir}/portserver.py
|
|
|
|
|
|
|
|
|
|
|
|