%define oname urlgrabber %define name python-%oname %define version 2.9.6 %define release 1mdk Summary: A high-level cross-protocol url-grabber Name: %{name} Version: %{version} Release: %{release} Source0: http://linux.duke.edu/projects/urlgrabber/download/%{oname}-%{version}.tar.bz2 License: LGPL Group: Development/Python BuildRoot: %{_tmppath}/%{name}-buildroot BuildArchitectures: noarch Url: http://linux.duke.edu/projects/mini/urlgrabber/ BuildRequires: python-devel %description A high-level cross-protocol url-grabber. Using urlgrabber, data can be fetched in three basic ways: urlgrab(url) copy the file to the local filesystem urlopen(url) open the remote file and return a file object (like urllib2.urlopen) urlread(url) return the contents of the file as a string When using these functions (or methods), urlgrabber supports the following features: * identical behavior for http://, ftp://, and file:// urls * http keepalive - faster downloads of many files by using only a single connection * byte ranges - fetch only a portion of the file * reget - for a urlgrab, resume a partial download * progress meters - the ability to report download progress automatically, even when using urlopen! * throttling - restrict bandwidth usage * retries - automatically retry a download if it fails. The number of retries and failure types are configurable. * authenticated server access for http and ftp * proxy support - support for authenticated http and ftp proxies * mirror groups - treat a list of mirrors as a single source, automatically switching mirrors if there is a failure. %prep %setup -q -n %oname-%version %build python setup.py build %install rm -rf %buildroot installed-docs python setup.py install --root=$RPM_BUILD_ROOT mv %buildroot%_datadir/doc/%oname-%version/ installed-docs %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) %doc installed-docs/* %_bindir/%oname %_libdir/python%pyver/site-packages/%oname/ %changelog * Mon Apr 25 2005 Götz Waschk <waschk@mandriva.org> 2.9.6-1mdk - New release 2.9.6 * Sun Dec 05 2004 Michael Scherer <misc@mandrake.org> 2.9.0-2mdk - Rebuild for new python * Thu Nov 25 2004 Götz Waschk <waschk@linux-mandrake.com> 2.9.0-1mdk - initial package