Name: python-twisted Version: 1.3.0 Release: 0.fdr.3 Summary: Event-driven networking framework written in Python. Group: Applications/Internet License: LGPL URL: http://www.twistedmatrix.com/ Source: http://twisted.sourceforge.net/Twisted-%{version}.tar.bz2 Patch0: %{name}-python22.patch Patch1: %{name}-processtest.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: python-devel >= 2.2 %{?_with_tests:BuildRequires: pyOpenSSL >= 0.5.1} Requires: python >= 2.2 Requires: pyOpenSSL >= 0.5.1 Requires: python-abi = %(%{__python} -c "import sys ; print sys.version[:3]") Provides: Twisted = %{version}-%{release} Obsoletes: python-Twisted %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} %description An event-driven networking framework written in Python and licensed under the LGPL. Twisted supports TCP, UDP, SSL/TLS, multicast, Unix sockets, a large number of protocols (including HTTP, NNTP, SSH, IRC, FTP, and others), and much more. %package doc Summary: Documentation for the Twisted networking framework. Group: Documentation Provides: Twisted-doc = %{version}-%{release} Obsoletes: python-Twisted-docs %description doc An event-driven networking framework written in Python and licensed under the LGPL. Twisted supports TCP, UDP, SSL/TLS, multicast, Unix sockets, a large number of protocols (including HTTP, NNTP, SSH, IRC, FTP, and others), and much more. This package contains all the documentation for Twisted. %prep %setup -q -n Twisted-%{version} %patch0 -p1 %patch1 -p0 find doc -type f -name "*.tex" | xargs rm ln -sf index.xhtml doc/index.html find doc -type f | xargs chmod 644 %build CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build %install rm -rf $RPM_BUILD_ROOT %{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT install -dm 755 $RPM_BUILD_ROOT%{_mandir}/man1 install -pm 644 doc/man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1 rm doc/man/*.1 # avoid including these in -doc # Remove im, it requires PyGTK 1.2. rm -rf \ $RPM_BUILD_ROOT%{_bindir}/{im,t-im} \ $RPM_BUILD_ROOT%{_mandir}/man1/{im,t-im}.1* \ $RPM_BUILD_ROOT%{python_sitearch}/twisted/{im,scripts/im.py*} find $RPM_BUILD_ROOT%{python_sitearch}/twisted -type d \ | sed "s|^$RPM_BUILD_ROOT|%dir |" > %{name}-%{version}.files find $RPM_BUILD_ROOT%{python_sitearch}/twisted -type f ! -name "*.pyo" \ | sed "s|^$RPM_BUILD_ROOT||" >> %{name}-%{version}.files find $RPM_BUILD_ROOT%{python_sitearch}/twisted -type f -name "*.pyo" \ | sed "s|^$RPM_BUILD_ROOT|%ghost |" >> %{name}-%{version}.files %check || : # requires networking (I guess), takes ~4 minutes on my box # fails: testMulticast (twisted.test.test_udp.MulticastTestCase) %{?_with_tests:bin/trial --bwverbose twisted.test} %clean rm -rf $RPM_BUILD_ROOT %files -f %{name}-%{version}.files %defattr(-,root,root,-) %doc CREDITS ChangeLog LICENSE NEWS README %{_bindir}/ckeygen %{_bindir}/conch %{_bindir}/lore %{_bindir}/mailmail %{_bindir}/manhole %{_bindir}/mktap %{_bindir}/tap2deb %{_bindir}/tap2rpm %{_bindir}/tapconvert %{_bindir}/tkconch %{_bindir}/tkmktap %{_bindir}/trial %{_bindir}/twistd %{_bindir}/websetroot %{_mandir}/man1/ckeygen.1* %{_mandir}/man1/conch.1* %{_mandir}/man1/lore.1* %{_mandir}/man1/mailmail.1* %{_mandir}/man1/manhole.1* %{_mandir}/man1/mktap.1* %{_mandir}/man1/pyhtmlizer.1* %{_mandir}/man1/tap2deb.1* %{_mandir}/man1/tap2rpm.1* %{_mandir}/man1/tapconvert.1* %{_mandir}/man1/tkconch.1* %{_mandir}/man1/tkmktap.1* %{_mandir}/man1/trial.1* %{_mandir}/man1/twistd.1* %{_mandir}/man1/websetroot.1* %files doc %defattr(-,root,root,-) %doc doc/* %changelog * Tue Sep 14 2004 Thomas Vander Stichele - 1.3.0-0.fdr.1 - put back trial (patch from Johan Dahlin) * Fri Aug 27 2004 Thomas Vander Stichele - 1.3.0-0.fdr.2 - Remove epochs - Remove python-crypto, it's not in fedora.us - Add periods back in Summary - Provide correct python-Twisted-docs for upgrading previous package * Sat Aug 21 2004 Ville Skyttä - 0:1.3.0-0.fdr.1 - Update to 1.3.0, rename to python-twisted (lowercase) for consistency. - Provide Twisted and python-Twisted and *-docs for compatibility. - Bring up to date with current fedora.us Python spec template. - (Build)Require Python >= 2.2, python-crypto and pyOpenSSL. - Don't package im, it requires PyGTK 1.2, and don't package test suite. - Add rpmbuild flag to run tests during build (use "--with tests" to enable). - Rename -docs to -doc for consistency with most doc packages out there. - Don't install *.tex in -doc. * Sun May 09 2004 Thomas Vander Stichele - 1.2.0-0.fdr.1: Update to new upstream release - split off docs - packaged man pages correctly - patch to remove hardcoding of python2.2 * Fri Feb 13 2004 Thomas Vander Stichele - 1.1.1-0.fdr.1: Initial RPM release