]> git.pld-linux.org Git - packages/python-pycurl.git/blob - python-pycurl.spec
27f2d3257f5b4990a33123531b6949f88c168ee7
[packages/python-pycurl.git] / python-pycurl.spec
1 # TODO
2 # - as-needed fix: drop libssh2 dep from curl
3
4 # During its initialization, PycURL checks that the actual libcurl version
5 # is not lower than the one used when PycURL was built.
6 # Yes, that should be handled by library versioning (which would then get
7 # automatically reflected by rpm).
8 # For now, we have to reflect that dependency.
9 %define         libcurl_ver %(rpm -q --qf '%|E?{%{E}:}|%{V}' curl-devel | sed 's/package .* is not installed/ERROR/' || echo ERROR)
10
11 %define         module  pycurl
12 Summary:        Free and easy-to-use client-side URL transfer library
13 Summary(pl.UTF-8):      Łatwa w użyciu biblioteka obsługi URL od strony klienta
14 Name:           python-%{module}
15 Version:        7.19.0
16 Release:        8
17 License:        LGPL v2 or MIT-like
18 Group:          Libraries/Python
19 Source0:        http://pycurl.sourceforge.net/download/%{module}-%{version}.tar.gz
20 # Source0-md5:  919d58fe37e69fe87ce4534d8b6a1c7b
21 Patch0:         %{name}-no-static-libs.patch
22 URL:            http://pycurl.sourceforge.net/
23 BuildRequires:  curl-devel >= 7.19
24 BuildRequires:  python >= 1:2.5
25 BuildRequires:  python-devel >= 1:2.5
26 BuildRequires:  python-modules >= 1:2.5
27 BuildRequires:  rpm-pythonprov
28 BuildRequires:  rpmbuild(macros) >= 1.219
29 %pyrequires_eq  python-libs
30 Requires:       curl-libs >= %{libcurl_ver}
31 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
32
33 %description
34 pycurl is Python interface to curl library - free and easy-to-use
35 client-side URL transfer library, supporting FTP, FTPS, HTTP, HTTPS,
36 GOPHER, TELNET, DICT, FILE and LDAP. libcurl supports HTTPS
37 certificates, HTTP POST, HTTP PUT, FTP uploading, kerberos, HTTP form
38 based upload, proxies, cookies, user+password authentication, file
39 transfer resume, HTTP proxy tunneling and more!
40
41 %description -l pl.UTF-8
42 pycurl jest interfejsem języka Python do biblioteki libcurl -
43 wolnodostępnej i łatwej w użyciu biblioteki operacji na URL-ach od
44 strony klienta, obsługującej FTP, FTPS, HTTP, HTTPS, GOPHER, TELNET,
45 DICT, FILE i LDAP. libcurl obsługuje także certyfikaty HTTPS, HTTP
46 POST, HTTP PUT, uploady FTP, kerberos, upload plików przez HTTP oparty
47 na formularzach, proxy, ciasteczka, uwierzytelnienie, wznawianie
48 przesyłania plików, tunelowanie proxy i wiele innych.
49
50 %package doc
51 Summary:        Documentation for pycurl Python module
52 Summary(pl.UTF-8):      Dokumentacja do modułu Pythona pycurl
53 Group:          Libraries/Python
54 Requires:       %{name} = %{version}-%{release}
55
56 %description doc
57 This module contains documentation files for pycurl Python module.
58
59 %description doc -l pl.UTF-8
60 Moduł zawierający dokumentację dla modułu Pythona pucurl.
61
62 %package examples
63 Summary:        Examples for pycurl Python module
64 Summary(pl.UTF-8):      Przykładowe programy do modułu Pythona pycurl
65 Group:          Libraries/Python
66 Requires:       %{name} = %{version}-%{release}
67
68 %description examples
69 This module contains examples for pycurl Python module.
70
71 %description examples -l pl.UTF-8
72 Moduł zawierający przykładowe programy do modułu Pythona pycurl.
73
74 %prep
75 %setup -q -n %{module}-%{version}
76 %patch0 -p0
77
78 %build
79 %{__python} setup.py build \
80         --debug
81
82 %install
83 rm -rf $RPM_BUILD_ROOT
84 install -d $RPM_BUILD_ROOT{%{py_sitedir},%{_examplesdir}/%{name}-%{version}}
85
86 %{__python} setup.py install \
87         --root=$RPM_BUILD_ROOT \
88         --optimize=2
89
90 %py_postclean
91
92 cp -a examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
93 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/pycurl
94
95 %clean
96 rm -rf $RPM_BUILD_ROOT
97
98 %files
99 %defattr(644,root,root,755)
100 %doc COPYING2 ChangeLog README TODO
101 %attr(755,root,root) %{py_sitedir}/pycurl.so
102 %dir %{py_sitedir}/curl
103 %{py_sitedir}/curl/*.py[co]
104 %{py_sitedir}/pycurl-*.egg-info
105
106 %files doc
107 %defattr(644,root,root,755)
108 %doc doc/*.html
109
110 %files examples
111 %defattr(644,root,root,755)
112 %{_examplesdir}/%{name}-%{version}
This page took 0.066457 seconds and 2 git commands to generate.