%{!?python_sitearch: %global python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)" 2>/dev/null)} %{?!pybasever: %global pybasever %(python -c "import sys; print sys.version[:3]" 2>/dev/null || echo 0.0)} Name: python-twisted-conch Version: 10.0.0 Release: 2.0.cf%{?dist} Summary: An SSH and SFTP protocol implementation together with clients and servers Group: Development/Libraries License: MIT URL: http://twistedmatrix.com/trac/wiki/TwistedConch Source0: http://twistedmatrix.com/Releases/Conch/10.0/TwistedConch-%{version}.tar.bz2 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -nu) BuildRequires: python-twisted-core >= 10.0.0, python2-devel %if "%{pybasever}" == "2.3" Requires: python-abi = 2.3 %endif Requires: python-twisted-core >= 10.0.0 Requires: python-pyasn1 Requires: python-crypto # a noarch-turned-arch package should not have debuginfo %global debug_package %{nil} %description Twisted is an event-based framework for Internet applications. Conch is an SSHv2 implementation written in Python. SSH is a protocol designed to allow remote access to shells and commands, but it is generic enough to allow everything from TCP forwarding to generic filesystem access. Since conch is written in Python, it interfaces well with other Python projects, such as Imagination. Conch also includes a implementations of the telnet and vt102 protocols, as well as support for rudimentary line editing behaviors. A new implementation of Twisted's Manhole application is also included, featuring server-side input history and interactive syntax coloring. %prep %setup -n TwistedConch-%{version} -q # Fix doc file dependencies chmod -x doc/{benchmarks/buffering_mixin.py,examples/sshsimpleserver.py} %build python setup.py build %install rm -rf %{buildroot} # This is a pure python package, but extending the twisted namespace from # python-twisted-core, which is arch-specific, so it needs to go in sitearch python setup.py install -O1 --skip-build --install-purelib %{python_sitearch} --root %{buildroot} # Man pages mkdir -p %{buildroot}%{_mandir}/man1/ cp -a doc/man/*.1 %{buildroot}%{_mandir}/man1/ rm -rf doc/man # See if there's any egg-info if [ -f %{buildroot}%{python_sitearch}/Twisted_Conch-%{version}-py%{pybasever}.egg-info ]; then echo %{python_sitearch}/Twisted_Conch-%{version}-py%{pybasever}.egg-info fi > egg-info %clean rm -rf %{buildroot} %post if [ -x %{_libexecdir}/twisted-dropin-cache ]; then %{_libexecdir}/twisted-dropin-cache || : fi %postun if [ -x %{_libexecdir}/twisted-dropin-cache ]; then %{_libexecdir}/twisted-dropin-cache || : fi %files -f egg-info %defattr(-,root,root,-) %doc LICENSE NEWS README doc/* %{_bindir}/cftp %{_bindir}/ckeygen %{_bindir}/conch %{_bindir}/tkconch %{_mandir}/man1/cftp.1* %{_mandir}/man1/ckeygen.1* %{_mandir}/man1/conch.1* %{_mandir}/man1/tkconch.1* %{python_sitearch}/twisted/conch/ %{python_sitearch}/twisted/plugins/twisted_conch.py* %changelog * Wed Apr 20 2011 Paul Howarth 10.0.0-2.0.cf - require python-pyasn1 (#696100) - update source URL to point to official upstream location - nobody else likes macros for commands - BR: python2-devel rather than just python-devel * Thu Mar 4 2010 Paul Howarth 10.0.0-1.0.cf - update to 10.0.0 (see NEWS for details) - egg-info now named Twisted_Conch rather than just Conch * Wed Nov 25 2009 Paul Howarth 9.0.0-1.0.cf - update to 9.0.0 * Mon Aug 10 2009 Paul Howarth 8.2.0-3.0.cf - define RPM macros in global scope - tidy up egg-info handling * Sun Jul 26 2009 Paul Howarth 8.2.0-2.0.cf - rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild * Fri Jan 16 2009 Paul Howarth 8.2.0-1.0.CF - update to 8.2.0 - make sure the scriplets never return a non-zero exit status * Mon May 19 2008 Paul Howarth 8.1.0-1 - update to 8.1.0 * Tue Apr 1 2008 Paul Howarth 8.0.0-1 - update to 8.0.0 - deal with egg-info if present * Wed Jan 10 2007 Paul Howarth 0.8.0-1 - update to 0.8.0 - require python-twisted-core >= 2.5.0 - fix another executable document * Thu Jan 4 2007 Paul Howarth 0.7.0-5 - update URL - add %%post and %%postun scriptlets to maintain the dropin cache * Tue Dec 12 2006 Paul Howarth 0.7.0-4 - reinstate tabs - reinstate python-devel buildreq, now needed on Rawhide with python 2.5 * Mon Sep 4 2006 Paul Howarth 0.7.0-3 - drop unnecessary python-devel buildreq - don't ghost .pyo files - don't generate debuginfo package * Fri Jun 9 2006 Paul Howarth 0.7.0-2 - build as arch-specific package for proper integration with twisted-core (see http://www.redhat.com/archives/fedora-extras-list/2006-June/msg00264.html) - script the python files list generation to clean up the spec * Wed May 31 2006 Paul Howarth 0.7.0-1 - update to 0.7.0 - add doc files LICENSE and NEWS * Wed May 10 2006 Paul Howarth 0.6.0-1 - update to 0.6.0 * Tue May 9 2006 Paul Howarth 0.5.0-4 - import from PyVault Repository - rewrite in Fedora Extras style * Fri Sep 23 2005 Jeff Pitman 0.5.0-3 - normalize crypto name * Tue Aug 23 2005 Jeff Pitman 0.5.0-2 - need twisted to build * Fri Mar 25 2005 Jeff Pitman 0.5.0-1 - final release * Wed Mar 16 2005 Jeff Pitman 0.5.0-0.1.a3 - upstream release * Sat Mar 12 2005 Jeff Pitman 0.5.0-0.1.a2 - new prerelease; FE versioning * Mon Feb 07 2005 Jeff Pitman 0.1.0-1 - prep for split