316d127
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
316d127
08b9184
%define _ver 0.1.10
ede16e5
316d127
Name:           python-mechanize
08b9184
Version:        0.1.10
08b9184
Release:        1%{?dist}
316d127
Summary:        Stateful programmatic web browsing
316d127
316d127
Group:          System Environment/Libraries
316d127
License:        BSD
316d127
URL:            http://wwwsearch.sourceforge.net/mechanize
ede16e5
Source0:        http://wwwsearch.sourceforge.net/mechanize/src/mechanize-%{_ver}.tar.gz
316d127
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
6771b55
BuildArch:      noarch
316d127
1cc7dd1
BuildRequires:  python-devel
1cc7dd1
%if 0%{?fedora} >= 8
1cc7dd1
BuildRequires: python-setuptools-devel
1cc7dd1
%else
1cc7dd1
BuildRequires: python-setuptools
1cc7dd1
%endif
316d127
Requires:       python-clientform
316d127
316d127
316d127
%description
316d127
Stateful programmatic web browsing, after Andy Lester's Perl module
316d127
WWW::Mechanize.
316d127
316d127
The library is layered: mechanize.Browser (stateful web browser),
316d127
mechanize.UserAgent (configurable URL opener), plus urllib2 handlers.
316d127
316d127
Features include: ftp:, http: and file: URL schemes, browser history,
316d127
high-level hyperlink and HTML form support, HTTP cookies, HTTP-EQUIV and
316d127
Refresh, Referer [sic] header, robots.txt, redirections, proxies, and
316d127
Basic and Digest HTTP authentication.  mechanize's response objects are
316d127
(lazily-) .seek()able and still work after .close().
316d127
316d127
Much of the code originally derived from Perl code by Gisle Aas
316d127
(libwww-perl), Johnny Lee (MSIE Cookie support) and last but not least
316d127
Andy Lester (WWW::Mechanize).  urllib2 was written by Jeremy Hylton.
316d127
316d127
316d127
%prep
ede16e5
%setup -q -n mechanize-%{_ver}
316d127
316d127
316d127
%build
316d127
%{__python} setup.py build
316d127
316d127
316d127
%install
316d127
rm -rf $RPM_BUILD_ROOT
316d127
%{__python} setup.py install --single-version-externally-managed \
316d127
                             -O1 --root=$RPM_BUILD_ROOT
316d127
316d127
316d127
%clean
316d127
rm -rf $RPM_BUILD_ROOT
316d127
316d127
316d127
%files
316d127
%defattr(-,root,root,-)
316d127
%doc COPYING.txt README.txt README.html GeneralFAQ.html doc.html examples
316d127
%{python_sitelib}/*
316d127
316d127
316d127
%changelog
08b9184
* Wed Dec 10 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.1.10-1
08b9184
- Update to 0.1.10
08b9184
a74f96f
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.1.6-0.3.b
a74f96f
- Rebuild for Python 2.6
a74f96f
1cc7dd1
* Sun Sep  2 2007 Luke Macken <lmacken@redhat.com> - 0.1.6-0.2.b
1cc7dd1
- Update for python-setuptools changes in rawhide
1cc7dd1
37176bd
* Sat Mar  3 2007 Luke Macken <lmacken@redhat.com> - 0.1.6-0.1.b
37176bd
- 0.1.6b
37176bd
ede16e5
* Fri Nov 24 2006 Luke Macken <lmacken@redhat.com> - 0.1.5-0.1.b
ede16e5
- Rebuild for python 2.5
ede16e5
- 0.1.5b
ede16e5
48c7d28
* Sun Sep  3 2006 Luke Macken <lmacken@redhat.com> - 0.1.1a-5
48c7d28
- Rebuild for FC6
48c7d28
932a54a
* Sun Jul  9 2006 Luke Macken <lmacken@redhat.com> - 0.1.1a-4
932a54a
- Remove unnecessary python-abi requirement
932a54a
6771b55
* Wed May 17 2006 Luke Macken <lmacken@redhat.com> - 0.1.1a-3
6771b55
- Add BuildArch: noarch (bug #192155)
6771b55
316d127
* Sun May 14 2006 Luke Macken <lmacken@redhat.com> - 0.1.1a-2
316d127
- Add python-abi Requires
316d127
- Remove noarch
316d127
316d127
* Thu May 11 2006 Luke Macken <lmacken@redhat.com> - 0.1.1a-1
316d127
- Packaged for Fedora Extras