]> git.pld-linux.org Git - packages/python-speaklater.git/blame - python-speaklater.spec
rebuild with tests and docs
[packages/python-speaklater.git] / python-speaklater.spec
CommitLineData
541670cc
MK
1#
2# Conditional build:
3# %bcond_without doc # don't build doc
4%bcond_without tests # do not perform "make test"
5%bcond_without python2 # CPython 2.x module
6%bcond_without python3 # CPython 3.x module
7
8%define module speaklater
9Summary: Implements a lazy string for python
10Summary(pl.UTF-8): Implementacja wartościowania leniwego dla Pythona
11# Name must match the python module/package name (as in 'import' statement)
12Name: python-%{module}
13Version: 1.3
e3bc9b07 14Release: 11
541670cc
MK
15License: BSD-like
16Group: Libraries/Python
17Source0: https://pypi.python.org/packages/source/s/%{module}/%{module}-%{version}.tar.gz
18# Source0-md5: e8d5dbe36e53d5a35cff227e795e8bbf
19URL: http://github.com/mitsuhiko/speaklater
387aff4d 20BuildRequires: rpmbuild(macros) >= 1.710
541670cc
MK
21BuildRequires: rpm-pythonprov
22%if %{with python2}
23BuildRequires: python-distribute
24%endif
25%if %{with python3}
541670cc
MK
26BuildRequires: python3-modules
27%endif
28Requires: python-modules
29BuildArch: noarch
30BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
31
32%description
33A module that provides lazy strings for translations. Basically you
34get an object that appears to be a string but changes the value every
35time the value is evaluated based on a callable you provide.
36
37# %description -l pl.UTF-8
38
39%package -n python3-%{module}
40Summary: -
41Summary(pl.UTF-8): -
42Group: Libraries/Python
43Requires: python3-modules
44
45%description -n python3-%{module}
46
47%description -n python3-%{module} -l pl.UTF-8
48
49%package apidocs
50Summary: %{module} API documentation
51Summary(pl.UTF-8): Dokumentacja API %{module}
52Group: Documentation
53
54%description apidocs
55API documentation for %{module}.
56
57%description apidocs -l pl.UTF-8
58Dokumentacja API %{module}.
59
60%prep
61%setup -q -n %{module}-%{version}
62
63%build
64%if %{with python2}
e5360f83 65%py_build %{?with_tests:test}
541670cc
MK
66%endif
67
68%if %{with python3}
e5360f83 69%py3_build %{?with_tests:test}
541670cc
MK
70%endif
71
72%install
73rm -rf $RPM_BUILD_ROOT
74
75%if %{with python2}
e5360f83 76%py_install
541670cc
MK
77
78%py_postclean
79%endif
80
81%if %{with python3}
e5360f83 82%py3_install
541670cc
MK
83%endif
84
85%clean
86rm -rf $RPM_BUILD_ROOT
87
88%if %{with python2}
89%files
90%defattr(644,root,root,755)
91%doc LICENSE README
92%{py_sitescriptdir}/*.py[co]
93%if "%{py_ver}" > "2.4"
94%{py_sitescriptdir}/%{module}-%{version}-py*.egg-info
95%endif
96%endif
97
98%if %{with python3}
99%files -n python3-%{module}
100%defattr(644,root,root,755)
101%doc LICENSE README
102%{py3_sitescriptdir}/%{module}.py
103%{py3_sitescriptdir}/__pycache__/*.py[co]
104%{py3_sitescriptdir}/%{module}-%{version}-py*.egg-info
105%endif
106
107
This page took 0.095777 seconds and 4 git commands to generate.