5 %define module psycopg2
7 Summary: psycopg is a PostgreSQL database adapter for Python
8 Summary(pl.UTF-8): psycopg jest przeznaczonym dla Pythona interfejsem do bazy PostgreSQL
13 Group: Libraries/Python
14 Source0: http://initd.org/pub/software/psycopg/%{module}-%{version}.tar.gz
15 # Source0-md5: 2c31827878d436b0c89e777989ff55af
16 #Patch0: %{name}-lib64.patch
17 URL: http://www.initd.org/software/psycopg/
18 BuildRequires: autoconf
19 BuildRequires: postgresql-backend-devel
20 BuildRequires: postgresql-devel
21 BuildRequires: python-devel
22 BuildRequires: rpm-pythonprov
23 Requires: postgresql-libs
24 %pyrequires_eq python-modules
25 %if "%{pld_release}" == "ac"
26 BuildRequires: python-mx-DateTime-devel
27 Requires: python-mx-DateTime
29 # allow mx.DateTime to be optional
30 # don't use Suggest - it is rare to use mx.DateTime; python provides its
31 # own datetime implementation, now
32 BuildConflicts: python-mx-DateTime
34 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
37 psycopg is a PostgreSQL database adapter for the Python programming
38 language (just like pygresql and popy.) It was written from scratch
39 with the aim of being very small and fast, and stable as a rock. The
40 main advantages of psycopg are that it supports the full Python
41 DBAPI-2.0 and being thread safe at level 2.
43 %description -l pl.UTF-8
44 psycopg jest przeznaczonym dla Pythona interfejsem do bazy danych
45 PostgreSQL (tak jak pygresql i popy). Został zakodowany od początku
46 z założeniem że ma być bardzo mały, szybki i stabilny. Główna zaletą
47 psycopg jest, że w jest pełni zgodny z standardem DBAPI-2.0 i jest
48 'thread safe' na poziomie 2.
51 %setup -q -n %{module}-%{version}
52 #%if "%{_lib}" == "lib64"
60 rm -rf $RPM_BUILD_ROOT
62 python setup.py install --optimize=2 --root=$RPM_BUILD_ROOT
64 find $RPM_BUILD_ROOT%{py_libdir} -type f -name "*.py" | xargs rm
67 rm -rf $RPM_BUILD_ROOT
70 %defattr(644,root,root,755)
71 %doc ChangeLog AUTHORS README doc/HACKING doc/SUCCESS doc/TODO
72 %dir %{py_sitedir}/%{module}
73 %attr(755,root,root) %{py_sitedir}/%{module}/*.so
74 %{py_sitedir}/%{module}/*.py[co]
75 %if "%{pld_release}" != "ac"
76 %{py_sitedir}/*.egg-info