File python-buildbot_worker.spec of Package python-buildbot_worker

#
# spec file for package python-buildbot_worker
#
# 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
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.

# Please submit bugfixes or comments via https://bugs.opensuse.org/
#


%define package_name buildbot_worker
Name:           python-%{package_name}
Version:        3.10.1
Release:        0
Summary:        Buildbot buildworker
License:        GPL-2.0-only
Group:          Development/Tools/Other
URL:            https://github.com/buildbot/buildbot
Source:         buildbot-worker-%{version}.tar.gz
BuildRequires:  fdupes
BuildRequires:  python-rpm-macros
Requires:       python-Twisted
Requires:       python-autobahn
Requires:       python-future
Requires:       python-msgpack
Requires:       python-setuptools
Requires:       python-importlib-metadata
Requires:       python-six
Requires(post): update-alternatives
Requires(postun): update-alternatives
BuildArch:      noarch
BuildRequires:  %{python_module base >= 3.6}
BuildRequires:  %{python_module setuptools}
%python_subpackages

%description
This package contains only the buildworker implementation. The buildbot
package contains the buildmaster.

%prep
%setup -q -n buildbot-worker-%{version}

%build
%python_build

%install
%python_install

%python_expand %fdupes %{buildroot}%{$python_sitelib}

rm %{buildroot}%{_bindir}/buildbot_worker_windows_service
%python_clone -a %{buildroot}%{_bindir}/buildbot-worker

%post
%{python_install_alternative buildbot-worker}

%postun
%python_uninstall_alternative buildbot-worker

%files %{python_files}
%{python_sitelib}/*
%python_alternative %{_bindir}/buildbot-worker

%changelog
openSUSE Build Service is sponsored by