blob: 0cbe4a3be6d2d9947da7fdc8453935de7c824360 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
Name: python-blist
Version: 1.0.1
Release: 1%{?dist}
Summary: A faster list implementation for Python
Group: Development/Languages
License: BSD
URL: http://pypi.python.org/pypi/blist/
Source0: http://pypi.python.org/packages/source/b/blist/blist-%{version}.tar.gz
Patch0: blist-1.0.1-fastcall-ix86-only.patch
Patch1: blist-1.0.1-remove-unsafe-tests.patch
Patch2: blist-1.0.1-use-upstream-macros.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: python-devel python-setuptools
%description
The BList is a type that looks, acts, and quacks like a Python list,
but has better performance for for modifying large lists.
For small lists (fewer than 128 elements), BLists and the built-in
list have very similar performance, although BLists are memory
inefficient if you need to create a larger number of small lists.
%prep
%setup -q -n blist-%{version}
%patch0 -p1 -b .fastcall-ix86-only
%patch1 -p1 -b .remove-unsafe-tests
%patch2 -p1 -b .use-upstream-macros
chmod -x LICENSE *.[ch] *.rst *.txt
%build
CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing" %{__python} setup.py build
%install
rm -rf $RPM_BUILD_ROOT
%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
%check
%{__python} setup.py test
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc LICENSE README.txt blist.rst
%{python_sitearch}/*
%changelog
* Sat Oct 10 2009 Michel Salim <salimma@fedoraproject.org> - 1.0.1-1
- Initial package
|