]> git.pld-linux.org Git - packages/python-psycopg2.git/blob - python-psycopg2.spec
- (B)R += python-mx-DateTime(-devel)
[packages/python-psycopg2.git] / python-psycopg2.spec
1 #
2 # todo:
3 # - zope adapter
4 # - lib64 patch
5 #
6
7 %define         module  psycopg2
8
9 Summary:        psycopg is a PostgreSQL database adapter for Python
10 Summary(pl):    psycopg jest przeznaczonym dla Pythona interfejsem do bazy PostgreSQL
11 Name:           python-%{module}
12 Version:        2.0.5.1
13 Release:        4
14 License:        GPL
15 Group:          Libraries/Python
16 Source0:        http://initd.org/pub/software/psycopg/%{module}-%{version}.tar.gz
17 # Source0-md5:  052e4b97dab47708fdcdc36ffb25af66
18 #Patch0:                %{name}-lib64.patch
19 URL:            http://www.initd.org/software/psycopg/
20 BuildRequires:  autoconf
21 BuildRequires:  postgresql-backend-devel
22 BuildRequires:  postgresql-devel
23 BuildRequires:  python-devel
24 BuildRequires:  python-mx-DateTime-devel
25 BuildRequires:  rpm-pythonprov
26 Requires:       postgresql-libs
27 %pyrequires_eq  python-modules
28 Requires:       python-mx-DateTime
29 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31 %define zope_subname ZPsycopgDA
32
33 %description
34 psycopg is a PostgreSQL database adapter for the Python programming
35 language (just like pygresql and popy.) It was written from scratch
36 with the aim of being very small and fast, and stable as a rock. The
37 main advantages of psycopg are that it supports the full Python
38 DBAPI-2.0 and being thread safe at level 2.
39
40 %description -l pl
41 psycopg jest przeznaczonym dla Pythona interfejsem do bazy danych
42 PostgreSQL (tak jak pygresql i popy). Zosta³ zakodowany od pocz±tku
43 z za³o¿eniem ¿e ma byæ bardzo ma³y, szybki i stabilny. G³ówna zalet±
44 psycopg jest, ¿e w jest pe³ni zgodny z standardem DBAPI-2.0 i jest
45 'thread safe' na poziomie 2.
46
47 %package -n Zope-%{zope_subname}
48 Summary:        Zope PostgreSQL database adapter
49 Summary(pl):    Interfejs bazy danych PostgreSQL do Zope
50 Group:          Development/Languages/Python
51 Requires:       %{name} = %{version}-%{release}
52 Requires:       Zope
53
54 %description -n Zope-%{zope_subname}
55 Zope PostgreSQL database adapter.
56
57 %description -n Zope-%{zope_subname} -l pl
58 Interfejs bazy danych PostgreSQL do Zope.
59
60 %prep
61 %setup -q -n %{module}-%{version}
62 #%if "%{_lib}" == "lib64"
63 #%patch0 -p1
64 #%endif
65
66 %build
67 python setup.py build
68
69 %install
70 rm -rf $RPM_BUILD_ROOT
71
72 python setup.py install --optimize=2 --root=$RPM_BUILD_ROOT
73
74 find $RPM_BUILD_ROOT%{py_libdir} -type f -name "*.py" | xargs rm
75
76 #install -d $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}
77
78 #cp -ar %{zope_subname}/* $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}
79 #%py_comp $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}
80 #%py_ocomp $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}
81 #rm -f $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}/*.py
82
83 %clean
84 rm -rf $RPM_BUILD_ROOT
85
86 #%post -n Zope-%{zope_subname}
87 #/usr/sbin/installzopeproduct %{_datadir}/Zope-%{zope_subname} %{zope_subname}
88 #if [ -f /var/lock/subsys/zope ]; then
89 #       /etc/rc.d/init.d/zope restart >&2
90 #fi
91
92 #%postun -n Zope-%{zope_subname}
93 #if [ "$1" = "0" ]; then
94 #       /usr/sbin/installzopeproduct -d %{zope_subname} 
95 #       if [ -f /var/lock/subsys/zope ]; then
96 #               /etc/rc.d/init.d/zope restart >&2
97 #       fi
98 #fi
99
100 %files
101 %defattr(644,root,root,755)
102 %doc ChangeLog AUTHORS README doc/HACKING doc/SUCCESS doc/TODO
103 %dir %{py_sitedir}/%{module}
104 %attr(755,root,root) %{py_sitedir}/%{module}/*.so
105 %{py_sitedir}/%{module}/*.py[co]
106
107 #%files -n Zope-%{zope_subname}
108 #%defattr(644,root,root,755)
109 #%{_datadir}/Zope-%{zope_subname}
This page took 0.094309 seconds and 3 git commands to generate.