[packages/python-speaklater] Initial version 1.3.

matkor matkor at pld-linux.org
Thu Oct 2 17:05:02 CEST 2014


commit 541670cca78411ae57e890a5bcb16996aaacd49d
Author: Mateusz Korniak <matkor at pld-linux.org>
Date:   Thu Oct 2 17:04:46 2014 +0200

    Initial version 1.3.

 python-speaklater.spec | 115 +++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 115 insertions(+)
---
diff --git a/python-speaklater.spec b/python-speaklater.spec
new file mode 100644
index 0000000..d2469a4
--- /dev/null
+++ b/python-speaklater.spec
@@ -0,0 +1,115 @@
+#
+# Conditional build:
+# %bcond_without	doc		# don't build doc
+%bcond_without	tests	# do not perform "make test"
+%bcond_without	python2 # CPython 2.x module
+%bcond_without	python3 # CPython 3.x module
+
+%define 	module	speaklater
+Summary:	Implements a lazy string for python
+Summary(pl.UTF-8):	Implementacja wartościowania leniwego dla Pythona
+# Name must match the python module/package name (as in 'import' statement)
+Name:		python-%{module}
+Version:	1.3
+Release:	0.1
+License:	BSD-like
+Group:		Libraries/Python
+Source0:	https://pypi.python.org/packages/source/s/%{module}/%{module}-%{version}.tar.gz
+# Source0-md5:	e8d5dbe36e53d5a35cff227e795e8bbf
+URL:		http://github.com/mitsuhiko/speaklater
+BuildRequires:	rpm-pythonprov
+%if %{with python2}
+BuildRequires:	python-distribute
+%endif
+%if %{with python3}
+BuildRequires:	python3-distribute
+BuildRequires:	python3-modules
+%endif
+Requires:	python-modules
+BuildArch:	noarch
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+A module that provides lazy strings for translations. Basically you
+get an object that appears to be a string but changes the value every
+time the value is evaluated based on a callable you provide.
+
+# %description -l pl.UTF-8
+
+%package -n python3-%{module}
+Summary:	-
+Summary(pl.UTF-8):	-
+Group:		Libraries/Python
+Requires:	python3-modules
+
+%description -n python3-%{module}
+
+%description -n python3-%{module} -l pl.UTF-8
+
+%package apidocs
+Summary:	%{module} API documentation
+Summary(pl.UTF-8):	Dokumentacja API %{module}
+Group:		Documentation
+
+%description apidocs
+API documentation for %{module}.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API %{module}.
+
+%prep
+%setup -q -n %{module}-%{version}
+
+%build
+%if %{with python2}
+%{__python} setup.py build --build-base build-2 %{?with_tests:test}
+%endif
+
+%if %{with python3}
+%{__python3} setup.py build --build-base build-3 %{?with_tests:test}
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
+%{__python} setup.py \
+	build --build-base build-2 \
+	install --skip-build \
+	--optimize=2 \
+	--root=$RPM_BUILD_ROOT
+
+%py_postclean
+%endif
+
+%if %{with python3}
+%{__python3} setup.py \
+	build --build-base build-3 \
+	install --skip-build \
+	--optimize=2 \
+	--root=$RPM_BUILD_ROOT
+%endif
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%if %{with python2}
+%files
+%defattr(644,root,root,755)
+%doc LICENSE README
+%{py_sitescriptdir}/*.py[co]
+%if "%{py_ver}" > "2.4"
+%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
+%endif
+%endif
+
+%if %{with python3}
+%files -n python3-%{module}
+%defattr(644,root,root,755)
+%doc LICENSE README
+%{py3_sitescriptdir}/%{module}.py
+%{py3_sitescriptdir}/__pycache__/*.py[co]
+%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
+%endif
+
+
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/python-speaklater.git/commitdiff/541670cca78411ae57e890a5bcb16996aaacd49d



More information about the pld-cvs-commit mailing list