]> git.pld-linux.org Git - SPECS.git/blob - python-timeoutsocket.spec
SPECS updated Mon 29 Apr 22:05:02 CEST 2024
[SPECS.git] / python-timeoutsocket.spec
1
2 %define         module  timeoutsocket
3
4 Summary:        Timeout Socket Python module
5 Summary(pl.UTF-8):      Moduł Pythona Timeout Socket
6 Name:           python-%{module}
7 Version:        1.23
8 Release:        6
9 License:        distributable
10 Group:          Development/Languages/Python
11 Source0:        http://www.timo-tasi.org/python/timeoutsocket.py
12 # Source0-md5:  137f1e1fe6e250896f01a589c25b44eb
13 URL:            http://www.timo-tasi.org/python/
14 %pyrequires_eq  python
15 BuildRequires:  python
16 BuildRequires:  python-modules
17 BuildRequires:  rpm-pythonprov
18 BuildArch:      noarch
19 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
20
21 %description
22 This module enables a timeout mechanism on all TCP connections. It
23 does this by inserting a shim into the socket module. After this
24 module has been imported, all socket creation goes through this shim.
25 As a result, every TCP connection will support a timeout.
26
27 %description -l pl.UTF-8
28 Ten moduł dodaje mechanizm limitu czasowego dla wszystkich połączeń
29 TCP. Moduł robi to poprzez dołożenie wkładki do modułu socket. Po
30 zaimportowaniu tego modułu, każde tworzenie gniazd przechodzi przez tę
31 wkładkę. W efekcie każde połączenie TCP obsługuje limit czasowy.
32
33 %prep
34 python <<EOF
35 import sys
36 d={}
37 execfile("%{SOURCE0}",d,d)
38 if d["__version__"].split()[1]!="%{version}":
39         print >>sys.stderr,"Source version mismatch!"
40         sys.exit(1)
41 EOF
42
43 %install
44 rm -rf $RPM_BUILD_ROOT
45 install -d $RPM_BUILD_ROOT%{py_sitescriptdir}
46
47 install %{SOURCE0} $RPM_BUILD_ROOT%{py_sitescriptdir}
48
49 %py_comp $RPM_BUILD_ROOT%{py_sitescriptdir}
50 %py_ocomp $RPM_BUILD_ROOT%{py_sitescriptdir}
51
52 rm $RPM_BUILD_ROOT%{py_sitescriptdir}/*.py
53
54 %clean
55 rm -rf $RPM_BUILD_ROOT
56
57 %files
58 %defattr(644,root,root,755)
59 %{py_sitescriptdir}/*.py?
This page took 0.769803 seconds and 3 git commands to generate.