From 7a1c5bb0b40b4784f3f25d7b5723c80964e0e26f Mon Sep 17 00:00:00 2001 From: guibuilder_pel7x64builder0 Date: Wed, 28 Nov 2018 17:03:28 +0100 Subject: [PATCH] python3-setproctitle package creation Signed-off-by: guibuilder_pel7x64builder0 --- SPECS/python3-setproctitle.spec | 91 +++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 SPECS/python3-setproctitle.spec diff --git a/SPECS/python3-setproctitle.spec b/SPECS/python3-setproctitle.spec new file mode 100644 index 0000000..9f76a0a --- /dev/null +++ b/SPECS/python3-setproctitle.spec @@ -0,0 +1,91 @@ +# this is only turned on during transitional periods +%{?python3_next_pkgversion: %global with_python3_next 1} + +# Do not check .so files in the pythonX_sitearch directories. +%global __provides_exclude_from ^(%{python3_sitearch}|%{python3_next_sitearch})/.*\\.so$ + +%global tarname setproctitle + +%global _description\ +Python module allowing a process to change its title as displayed by\ +system tool such as ps and top.\ +\ +It's useful in multiprocess systems, allowing to identify tasks each forked\ +process is busy with. This technique has been used by PostgreSQL and OpenSSH.\ +\ +It's based on PostgreSQL implementation which has proven to be portable. + + +Name: python3-setproctitle +Version: 1.1.6 +Release: 2%{?dist} +Summary: Python module to customize a process title + +License: BSD +URL: https://pypi.python.org/pypi/%{tarname} +Source0: https://pypi.python.org/packages/source/s/%{tarname}/%{tarname}-%{version}.tar.gz + +BuildRequires: python%{python3_pkgversion}-devel +BuildRequires: python%{python3_pkgversion}-setuptools +#BuildRequires: python%{python3_pkgversion}-nose + +%description %_description + +%if "python%{python3_pkgversion}-%{tarname}" != "%{name}" +%package -n python%{python3_pkgversion}-%{tarname} +Summary: Python module to customize a process title + +%description -n python%{python3_pkgversion}-%{tarname} %_description +%endif + + +%if 0%{?with_python3_next} +%package -n python%{python3_next_pkgversion}-%{tarname} +Summary: Python module to customize a process title +BuildRequires: python%{python3_next_pkgversion}-devel +BuildRequires: python%{python3_next_pkgversion}-setuptools +BuildRequires: python%{python3_next_pkgversion}-nose + +%description -n python%{python3_next_pkgversion}-%{tarname} %_description +%endif + + +%prep +%autosetup -n %{tarname}-%{version} -p 1 + + +%build +%py3_build +%if 0%{?with_python3_next} +%py3_next_build +%endif + + +%install +%py3_install +%{__chmod} 0755 %{buildroot}%{python3_sitearch}/setproctitle*.so +%if 0%{?with_python3_next} +%py3_next_install +%{__chmod} 0755 %{buildroot}%{python3_next_sitearch}/setproctitle*.so +%endif + + +%files -n python%{python3_pkgversion}-%{tarname} +%license COPYRIGHT +%doc README.rst +%{python3_sitearch}/* + + +%if 0%{?with_python3_next} +%files -n python%{python3_next_pkgversion}-%{tarname} +%license COPYRIGHT +%doc README.rst +%{python3_next_sitearch}/* +%endif + +%changelog +* Thu Nov 16 2017 Björn Esser - 1.1.6-2 +- Some packaging fixes + +* Thu Aug 31 2017 Björn Esser - 1.1.6-1 +- Initial rpm release for EPEL7 (rhbz#1487224)