# To make byte compilation work properly everywhere %global __python %{__python3} %{!?python3_pkgversion:%global python3_pkgversion 3} Name: abf-console-client Version: 3.0.2.6 Release: 0%{?dist}.1 Summary: Console client for ABF (https://abf.openmandriva.org) License: GPLv2 URL: http://wiki.rosalab.ru/en/index.php/ABF_Console_Client Source0: https://github.com/OpenMandrivaSoftware/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz BuildArch: noarch BuildRequires: python%{python3_pkgversion}-devel BuildRequires: gettext BuildRequires: which Requires: python%{python3_pkgversion}-abf = %{version}-%{release} Requires: git-core Requires: tar >= 1.26 Requires: wget Recommends: rpm-build Recommends: mock %description Console client for ABF (https://abf.openmandriva.org). %package -n python%{python3_pkgversion}-abf Summary: Python API for ABF (https://abf.openmandriva.org) %{?python_provide:%python_provide python%{python3_pkgversion}-abf} Requires: python%{python3_pkgversion}-beaker Requires: python%{python3_pkgversion}-rpm Requires: python%{python3_pkgversion}-yaml Requires: python%{python3_pkgversion}-magic %description -n python%{python3_pkgversion}-abf This is the python API to ABF (https://abf.openmandriva.org). It contains a set of basic operations, done with either HTML parsing or through ABF JSON API. It also provides data model to operate with. %prep %autosetup %build pushd po %make_build popd %install %make_install PYTHON=%{__python3} install -d %{buildroot}%{_sysconfdir}/abf/mock/configs ln -sr %{buildroot}%{python3_sitelib}/abf/console/download.py %{buildroot}/%{_bindir}/dw %make_install -C po sed -e "s|#!/usr/bin/env python|#!%{__python3}|g" \ -i %{buildroot}%{python3_sitelib}/abf/console/download.py %find_lang %{name} %files -f %{name}.lang %{_bindir}/abf %{_bindir}/dw %{_datadir}/bash-completion/abf %{_sysconfdir}/profile.d/abfcd.sh %dir %{_sysconfdir}/abf/mock/configs/ %config(noreplace) %{_sysconfdir}/abf/mock/configs/*.* %dir /var/cache/abf/ %dir /var/cache/abf/mock/ %dir /var/lib/abf/mock/src %dir /var/lib/abf/ %dir /var/lib/abf/mock %files -n python%{python3_pkgversion}-abf %{python3_sitelib}/abf/ %changelog * Sat Jan 04 19:50:44 EST 2020 Neal Gompa - 3.0.2.6-0.1 - Initial packaging