Merge reactormixins-4987
[twisted.git] / admin / twisted.spec
blobef0f21e9f89cc0d516ca78c913ca2e754ff30e09
1 %define name Twisted
2 %define version SVN-trunk
3 %define release 1tummy
4 %define prefix %{_prefix}
5 %define py_libver 2.3
7 Summary: Twisted is an event-based framework for internet applications.
8 Name: %{name}
9 Version: %{version}
10 Release: %{release}
11 Source: %{name}-%{version}.tar.bz2
12 License: MIT
13 Group: System/Libraries
14 URL: http://www.twistedmatrix.com/
15 Requires: python >= %{py_libver}
16 BuildRequires: python-devel
17 BuildRoot: %{_tmppath}/%{name}-buildroot
18 Prefix: %{_prefix}
20 %description
21 Twisted is an event-based framework for internet applications. It includes a
22 web server, a telnet server, a chat server, a news server, a generic client
23 and server for remote object access, and APIs for creating new protocols and
24 services. Twisted supports integration of the Tk, GTK+, Qt or wxPython event
25 loop with its main event loop. The Win32 event loop is also supported, as is
26 basic support for running servers on top of Jython.
28 %package doc
29 Summary: Twisted documentation and example programs
30 Group: Development/Python
31 %description doc
32 Twisted is an event-based framework for internet applications.
33 Install Twisted-doc if you need the API documentation and example programs.
35 %prep
36 %setup -n %{name}-%{version}
37 %build
39 %install
40 [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf "$RPM_BUILD_ROOT"
41 mkdir -p "$RPM_BUILD_ROOT"
43 python setup.py install --optimize=2 --record=installed-files \
44 --root="$RPM_BUILD_ROOT"
46 # install man pages
47 mkdir -p "$RPM_BUILD_ROOT"/%{_mandir}/man1/
48 cp -a doc/man/*.1 "$RPM_BUILD_ROOT"/%{_mandir}/man1/
50 %clean
51 [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf "$RPM_BUILD_ROOT"
53 %files
54 %defattr(755,root,root)
55 %doc CREDITS LICENSE README
56 %{_bindir}/*
57 %attr(644,-,-) %{_mandir}/man1/*
58 %{_libdir}/python%{py_libver}/site-packages/twisted/
60 %files doc
61 %defattr(-,root,root)
62 %doc doc/*