From 310714740b01c7515e570e4e75a563ad1fa14ee2 Mon Sep 17 00:00:00 2001 From: David Shea Date: Wed, 5 Aug 2015 11:38:28 -0400 Subject: [PATCH] Initial import of package --- .gitignore | 1 + python-pid.spec | 88 +++++++++++++++++++++++++++++++++++++++++++++++++ sources | 1 + 3 files changed, 90 insertions(+) create mode 100644 python-pid.spec diff --git a/.gitignore b/.gitignore index e69de29..b0de2c2 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/pid-2.0.1.tar.gz diff --git a/python-pid.spec b/python-pid.spec new file mode 100644 index 0000000..7f1fcf0 --- /dev/null +++ b/python-pid.spec @@ -0,0 +1,88 @@ +%global srcname pid + +Name: python-%{srcname} +Version: 2.0.1 +Release: 2%{?dist} +Summary: PID file management library + +License: ASL 2.0 +URL: https://pypi.python.org/pypi/%{srcname} +Source0: https://pypi.python.org/packages/source/p/%{srcname}/%{srcname}-%{version}.tar.gz + +BuildRequires: python2-devel python3-devel +BuildRequires: python-setuptools python3-setuptools + +BuildArch: noarch + +%description +pid provides a PidFile class that manages PID files. PidFile features: + - stale detection + - locking using fcntl + - chmod (default is 0o644) + - chown + - custom exceptions + +PidFile can also be used as a context manager or a decorator. + +%package -n python2-%{srcname} +Summary: PID file management library +%{?python_provide:%python_provide python2-%{srcname}} + +%description -n python2-%{srcname} +pid provides a PidFile class that manages PID files. PidFile features: + - stale detection + - locking using fcntl + - chmod (default is 0o644) + - chown + - custom exceptions + +PidFile can also be used as a context manager or a decorator. + +%package -n python3-%{srcname} +Summary: PID file management library +%{?python_provide:%python_provide python3-%{srcname}} + +%description -n python3-%{srcname} +pid provides a PidFile class that manages PID files. PidFile features: + - stale detection + - locking using fcntl + - chmod (default is 0o644) + - chown + - custom exceptions + +PidFile can also be used as a context manager or a decorator. + +%prep +%autosetup -n %{srcname}-%{version} +rm -rf *.egg-info + +%build +%py2_build +%py3_build + +%install +%py2_install +%py3_install + +%check +%{__python2} setup.py test +%{__python3} setup.py test + +%files -n python2-%{srcname} +%license LICENSE +%doc AUTHORS CHANGELOG README.rst +%{python2_sitelib}/pid +%{python2_sitelib}/pid-*.egg-info + +%files -n python3-%{srcname} +%license LICENSE +%doc AUTHORS CHANGELOG README.rst +%{python3_sitelib}/pid +%{python3_sitelib}/pid-*.egg-info + +%changelog +* Wed Aug 05 2015 Igor Gnatenko - 2.0.1-2 +- Update to modern python packaging guidelines + +* Tue Aug 4 2015 David Shea - 2.0.1-1 +- Initial package diff --git a/sources b/sources index e69de29..e520533 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +1120fb3f538a005100135523e4e4c668 pid-2.0.1.tar.gz