]>
Commit | Line | Data |
---|---|---|
534e935f ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
4 | ||
5 | %define module peppercorn | |
6 | Summary: A library for converting a token stream into a data structure for use in web form posts | |
7 | Name: python-%{module} | |
8 | Version: 0.4 | |
4c2ad113 | 9 | Release: 2 |
534e935f ER |
10 | License: BSD-derived (http://www.repoze.org/LICENSE.txt) |
11 | Group: Libraries/Python | |
12 | Source0: http://pypi.python.org/packages/source/p/peppercorn/peppercorn-%{version}.tar.gz | |
13 | # Source0-md5: 464d6f2342eaf704dfb52046c1f5c320 | |
14 | URL: http://docs.pylonsproject.org/projects/peppercorn/ | |
15 | BuildRequires: python-distribute | |
16 | BuildRequires: rpm-pythonprov | |
17 | BuildRequires: rpmbuild(macros) >= 1.219 | |
18 | Requires: python-modules | |
19 | BuildArch: noarch | |
20 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
21 | ||
22 | %description | |
23 | A library for converting a token stream into a data structure | |
24 | comprised of sequences, mappings, and scalars, developed primarily for | |
25 | converting HTTP form post data into a richer data structure. | |
26 | ||
27 | %prep | |
28 | %setup -q -n %{module}-%{version} | |
29 | ||
30 | %build | |
17931a62 | 31 | %py_build |
534e935f ER |
32 | |
33 | %{?with_tests:%{__python} setup.py test} | |
34 | ||
35 | %install | |
36 | rm -rf $RPM_BUILD_ROOT | |
17931a62 | 37 | %py_install |
534e935f ER |
38 | |
39 | %{__rm} $RPM_BUILD_ROOT%{py_sitescriptdir}/%{module}/tests.py* | |
40 | ||
41 | %py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir} | |
42 | %py_comp $RPM_BUILD_ROOT%{py_sitescriptdir} | |
43 | %py_postclean | |
44 | ||
45 | %clean | |
46 | rm -rf $RPM_BUILD_ROOT | |
47 | ||
48 | %files | |
49 | %defattr(644,root,root,755) | |
50 | %doc CHANGES.txt LICENSE.txt README.txt | |
51 | %dir %{py_sitescriptdir}/%{module} | |
52 | %{py_sitescriptdir}/%{module}/*.py[co] | |
53 | %{py_sitescriptdir}/%{module}-%{version}*.egg-info |