]> git.pld-linux.org Git - packages/python-psycopg.git/blame - python-psycopg.spec
- release 8 (by relup.sh)
[packages/python-psycopg.git] / python-psycopg.spec
CommitLineData
701dfc24 1
782c8536 2%define module psycopg
701dfc24 3
5da62670 4Summary: psycopg is a PostgreSQL database adapter for Python
ad9293af 5Summary(pl.UTF-8): psycopg jest przeznaczonym dla Pythona interfejsem do bazy PostgreSQL
5da62670 6Name: python-%{module}
886f87a9 7Version: 1.1.21
3a80495e 8Release: 8
940e837d 9License: GPL
53f73d5f 10Group: Libraries/Python
c3ade87c 11Source0: http://initd.org/pub/software/psycopg/%{module}-%{version}.tar.gz
886f87a9 12# Source0-md5: a31f79f68d6d32898d6f24e11369a106
ddceceb9 13Patch0: %{name}-lib64.patch
940e837d 14URL: http://www.initd.org/software/psycopg/
4f4348d5 15BuildRequires: autoconf
940e837d 16BuildRequires: postgresql-backend-devel
42d26dba 17BuildRequires: postgresql-devel
940e837d
JB
18BuildRequires: python-devel
19BuildRequires: python-mx-DateTime-devel
dfeb4f96 20BuildRequires: rpm-pythonprov
940e837d 21Requires: postgresql-libs
8ffcb2a8 22%pyrequires_eq python-modules
277ad867 23Requires: python-mx-DateTime
5da62670 24BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
5da62670 25
d8f99445 26%define zope_subname ZPsycopgDA
7d6cfb74 27
5da62670
MK
28%description
29psycopg is a PostgreSQL database adapter for the Python programming
30language (just like pygresql and popy.) It was written from scratch
31with the aim of being very small and fast, and stable as a rock. The
32main advantages of psycopg are that it supports the full Python
33DBAPI-2.0 and being thread safe at level 2.
34
08cdca40 35%description -l pl.UTF-8
5da62670 36psycopg jest przeznaczonym dla Pythona interfejsem do bazy danych
08cdca40
JR
37PostgreSQL (tak jak pygresql i popy). Został zakodowany od początku z
38założeniem że ma być bardzo mały, szybki i stabilny. Główna zaletą
39psycopg jest, że w jest pełni zgodny z standardem DBAPI-2.0 i jest
5da62670
MK
40'thread safe' na poziomie 2.
41
d8f99445 42%package -n Zope-%{zope_subname}
7d6cfb74 43Summary: Zope PostgreSQL database adapter
ad9293af 44Summary(pl.UTF-8): Interfejs bazy danych PostgreSQL do Zope
7d6cfb74 45Group: Development/Languages/Python
c3ade87c 46Requires: %{name} = %{version}-%{release}
7d6cfb74 47Requires: Zope
7d6cfb74 48
d8f99445 49%description -n Zope-%{zope_subname}
7d6cfb74
JK
50Zope PostgreSQL database adapter.
51
08cdca40 52%description -n Zope-%{zope_subname} -l pl.UTF-8
7d6cfb74
JK
53Interfejs bazy danych PostgreSQL do Zope.
54
5da62670
MK
55%prep
56%setup -q -n %{module}-%{version}
ddceceb9 57%if "%{_lib}" == "lib64"
5da62670 58%patch0 -p1
ddceceb9 59%endif
5da62670
MK
60
61%build
62%{__autoconf}
63
940e837d
JB
64%configure \
65 --with-python=%{_bindir}/python \
a96aab30 66 --with-mxdatetime-includes=%{py_incdir}/mx \
940e837d 67 --with-postgres-includes=%{_includedir}/postgresql/server
5da62670
MK
68%{__make}
69
70%install
71rm -rf $RPM_BUILD_ROOT
d8f99445 72install -d $RPM_BUILD_ROOT{%{py_sitedir},%{_datadir}/Zope-%{zope_subname}}
5da62670 73
940e837d 74install psycopgmodule.so $RPM_BUILD_ROOT%{py_sitedir}
5da62670 75
a29fe666 76cp -a %{zope_subname}/* $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}
d8f99445
JK
77%py_comp $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}
78%py_ocomp $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}
79rm -f $RPM_BUILD_ROOT%{_datadir}/Zope-%{zope_subname}/*.py
7d6cfb74 80
5da62670
MK
81%clean
82rm -rf $RPM_BUILD_ROOT
83
d8f99445
JK
84%post -n Zope-%{zope_subname}
85/usr/sbin/installzopeproduct %{_datadir}/Zope-%{zope_subname} %{zope_subname}
86if [ -f /var/lock/subsys/zope ]; then
87 /etc/rc.d/init.d/zope restart >&2
88fi
89
90%postun -n Zope-%{zope_subname}
91if [ "$1" = "0" ]; then
a29fe666 92 /usr/sbin/installzopeproduct -d %{zope_subname}
d8f99445
JK
93 if [ -f /var/lock/subsys/zope ]; then
94 /etc/rc.d/init.d/zope restart >&2
95 fi
96fi
97
5da62670
MK
98%files
99%defattr(644,root,root,755)
940e837d
JB
100%doc AUTHORS CREDITS FAQ NEWS README RELEASE-1.0 SUCCESS TODO doc
101%attr(755,root,root) %{py_sitedir}/*.so
7d6cfb74 102
d8f99445 103%files -n Zope-%{zope_subname}
7d6cfb74 104%defattr(644,root,root,755)
d8f99445 105%{_datadir}/Zope-%{zope_subname}
This page took 0.15114 seconds and 4 git commands to generate.