Python egginfo. Fixes rhbz#1968618

epel9
Jiri Popelka 4 years ago
parent 5768ee4553
commit 9ccfaff35c
No known key found for this signature in database
GPG Key ID: A3E9A812AAB73DA7

@ -9,7 +9,7 @@
Name: koji
Version: 1.25.0
Release: 2%{?dist}
Release: 3%{?dist}
# the included arch lib from yum's rpmUtils is GPLv2+
License: LGPLv2 and GPLv2+
Summary: Build system tools
@ -25,6 +25,7 @@ Requires: python%{python3_pkgversion}-libcomps
Requires: python3-libcomps
BuildRequires: systemd
BuildRequires: pkgconfig
BuildRequires: sed
%description
Koji is a system for building and tracking RPMS. The base package
@ -36,6 +37,8 @@ Summary: Build system tools python library
BuildRequires: python%{python3_pkgversion}-devel
BuildRequires: python%{python3_pkgversion}-setuptools
BuildRequires: make
BuildRequires: python3-pip
BuildRequires: python3-wheel
Requires: python%{python3_pkgversion}-rpm
Requires: python%{python3_pkgversion}-requests
Requires: python%{python3_pkgversion}-requests-gssapi
@ -195,17 +198,27 @@ koji-web is a web UI to the Koji system.
%prep
%autosetup -p1
# we'll be packaging these separately and don't want them registered
# to the wheel we will produce.
sed -e '/util\/koji/g' -e '/koji_cli_plugins/g' -i setup.py
%build
# Nothing to build
%py3_build_wheel
%install
%py3_install_wheel %{name}-%{version}-py3-none-any.whl
mkdir -p %{buildroot}/etc/koji.conf.d
cp cli/koji.conf %{buildroot}/etc/koji.conf
for D in hub builder plugins util www vm ; do
pushd $D
make DESTDIR=$RPM_BUILD_ROOT PYTHON=%{__python3} %{?install_opt} install
popd
done
# alter python interpreter in koji CLI
scripts='%{_bindir}/koji %{_sbindir}/kojid %{_sbindir}/kojira %{_sbindir}/koji-shadow
%{_sbindir}/koji-gc %{_sbindir}/kojivmd %{_sbindir}/koji-sweep-db %{_sbindir}/koji-sidetag-cleanup'
%{_sbindir}/koji-gc %{_sbindir}/kojivmd %{_sbindir}/koji-sweep-db
%{_sbindir}/koji-sidetag-cleanup'
for fn in $scripts ; do
sed -i 's|#!/usr/bin/python2|#!/usr/bin/python3|' $RPM_BUILD_ROOT$fn
done
@ -229,6 +242,7 @@ done
%files -n python%{python3_pkgversion}-koji
%{python3_sitelib}/%{name}
%{python3_sitelib}/%{name}-%{version}.*-info
%{python3_sitelib}/koji_cli
%files -n python%{python3_pkgversion}-%{name}-cli-plugins
@ -336,6 +350,9 @@ done
%systemd_postun kojira.service
%changelog
* Tue Jun 15 2021 Jiri Popelka <jpopelka@redhat.com> - 1.25.0-3
- Python egginfo. Fixes rhbz#1968618
* Fri Jun 04 2021 Python Maint <python-maint@redhat.com> - 1.25.0-2
- Rebuilt for Python 3.10

Loading…
Cancel
Save