[packages/python-ago] - initial
arekm
arekm at pld-linux.org
Fri Feb 14 12:50:33 CET 2014
commit 5c5bbe969d40d77a6fba36da1e151c22363ccb4d
Author: Arkadiusz Miśkiewicz <arekm at maven.pl>
Date: Fri Feb 14 12:50:22 2014 +0100
- initial
python-ago.spec | 93 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 93 insertions(+)
---
diff --git a/python-ago.spec b/python-ago.spec
new file mode 100644
index 0000000..4c9f97f
--- /dev/null
+++ b/python-ago.spec
@@ -0,0 +1,93 @@
+#
+# Conditional build:
+%bcond_without python2 # Python 2.x module
+%bcond_without python3 # Python 3.x module
+#
+%define module ago
+#
+Summary: Makes customizable human readable timedeltas
+Name: python-ago
+Version: 0.0.5
+Release: 1
+License: public domain
+Group: Development/Languages/Python
+Source0: https://pypi.python.org/packages/source/a/ago/ago-%{version}.tar.gz
+# Source0-md5: b10434275958edf61254a43adf4662f2
+URL: https://bitbucket.org/russellballestrini/ago/overview
+%if %{with python2}
+BuildRequires: python-devel
+BuildRequires: python-modules
+Requires: python
+%endif
+%if %{with python3}
+BuildRequires: python3-2to3
+BuildRequires: python3-devel
+BuildRequires: python3-modules
+%endif
+BuildRequires: rpm-pythonprov
+BuildArch: noarch
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+Makes customizable human readable timedeltas.
+
+%package -n python3-%{module}
+Summary: Makes customizable human readable timedeltas
+Group: Libraries/Python
+Requires: python3
+
+%description -n python3-%{module}
+Makes customizable human readable timedeltas.
+
+%prep
+%setup -q -n ago-%{version}
+
+%build
+%if %{with python2}
+%{__python} ./setup.py build --build-base py2
+%endif
+%if %{with python3}
+%{__python3} ./setup.py build --build-base py3
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+%if %{with python2}
+install -d $RPM_BUILD_ROOT%{_examplesdir}/python-%{module}-%{version}
+%{__python} ./setup.py build \
+ --build-base py2 \
+ install \
+ --optimize 2 \
+ --root=$RPM_BUILD_ROOT
+%endif
+
+%if %{with python3}
+install -d $RPM_BUILD_ROOT%{_examplesdir}/python3-%{module}-%{version}
+%{__python3} ./setup.py build \
+ --build-base py3 \
+ install \
+ --optimize 2 \
+ --root=$RPM_BUILD_ROOT
+%endif
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
+%files
+%defattr(644,root,root,755)
+%doc PKG-INFO README.rst
+%{_examplesdir}/python-%{module}-%{version}
+%{py_sitescriptdir}/%{module}.py*
+%{py_sitescriptdir}/*egg-info
+%endif
+
+%if %{with python3}
+%files -n python3-%{module}
+%defattr(644,root,root,755)
+%doc PKG-INFO README.rst
+%{_examplesdir}/python3-%{module}-%{version}
+%{py3_sitescriptdir}/%{module}.py*
+%{py3_sitescriptdir}/__pycache__/ago.cpython-*.py*
+%{py3_sitescriptdir}/*egg-info
+%endif
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/python-ago.git/commitdiff/5c5bbe969d40d77a6fba36da1e151c22363ccb4d
More information about the pld-cvs-commit
mailing list