]> git.pld-linux.org Git - packages/python-psycopg2.git/blob - python-psycopg2.spec
2d59338e9c1dcfc5bac42d1a7e330ba056e55d0f
[packages/python-psycopg2.git] / python-psycopg2.spec
1 #
2 # todo:
3 # - lib64 patch
4
5 %define         module  psycopg2
6
7 Summary:        psycopg is a PostgreSQL database adapter for Python
8 Summary(pl.UTF-8):      psycopg jest przeznaczonym dla Pythona interfejsem do bazy PostgreSQL
9 Name:           python-%{module}
10 Version:        2.0.10
11 Release:        0.r407.1
12 License:        GPL
13 Group:          Libraries/Python
14 #Source0:       http://initd.org/pub/software/psycopg/%{module}-%{version}.tar.gz
15 Source0:        http://initd.org/pub/software/psycopg/%{module}-r407.tar.gz
16 # Source0-md5:  463a684a427a71f894f74d8502e68c8d
17 #Patch0:                %{name}-lib64.patch
18 URL:            http://www.initd.org/software/psycopg/
19 BuildRequires:  autoconf
20 BuildRequires:  postgresql-backend-devel
21 BuildRequires:  postgresql-devel
22 BuildRequires:  python-devel
23 BuildRequires:  rpm-pythonprov
24 Requires:       postgresql-libs
25 Requires:       python-modules
26 %if "%{pld_release}" == "ac"
27 BuildRequires:  python-mx-DateTime-devel
28 Requires:       python-mx-DateTime
29 %else
30 # if somebody really needs mx.DateTime, then one can request mx.Datetime
31 # usage on runtime;
32 # it is pointless to use 'Requires' or 'Suggest' field because
33 # - python provides its own datetime implementation
34 # - one can request it on runtime (as said above)
35 # - usage of mx.DateTime type is application specific
36 BuildConflicts:   python-mx-DateTime
37 %endif
38 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
39
40 %description
41 psycopg is a PostgreSQL database adapter for the Python programming
42 language (just like pygresql and popy.) It was written from scratch
43 with the aim of being very small and fast, and stable as a rock. The
44 main advantages of psycopg are that it supports the full Python
45 DBAPI-2.0 and being thread safe at level 2.
46
47 %description -l pl.UTF-8
48 psycopg jest przeznaczonym dla Pythona interfejsem do bazy danych
49 PostgreSQL (tak jak pygresql i popy). Został zakodowany od początku
50 z założeniem że ma być bardzo mały, szybki i stabilny. Główna zaletą
51 psycopg jest, że w jest pełni zgodny z standardem DBAPI-2.0 i jest
52 'thread safe' na poziomie 2.
53
54 %prep
55 %setup -q -n %{module}-%{version}
56 #%if "%{_lib}" == "lib64"
57 #%patch0 -p1
58 #%endif
59
60 %build
61 python setup.py build
62
63 %install
64 rm -rf $RPM_BUILD_ROOT
65
66 python setup.py install --optimize=2 --root=$RPM_BUILD_ROOT
67
68 find $RPM_BUILD_ROOT%{py_libdir} -type f -name "*.py" | xargs rm
69
70 %clean
71 rm -rf $RPM_BUILD_ROOT
72
73 %files
74 %defattr(644,root,root,755)
75 %doc ChangeLog AUTHORS README doc/HACKING doc/SUCCESS doc/TODO
76 %dir %{py_sitedir}/%{module}
77 %attr(755,root,root) %{py_sitedir}/%{module}/*.so
78 %{py_sitedir}/%{module}/*.py[co]
79 %if "%{pld_release}" != "ac"
80 %{py_sitedir}/*.egg-info
81 %endif
This page took 0.089657 seconds and 2 git commands to generate.