%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
Name: python-bugzilla
Version: 0.3
Release: 1%{?dist}
Summary: A python library for interacting with Bugzilla
Group: Development/Languages
License: GPLv2+
URL: http://wwoods.fedorapeople.org/python-bugzilla/
Source0: python-bugzilla-0.3.tar.gz
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch
BuildRequires: python-devel
%if 0%{?fedora} >= 8
BuildRequires: python-setuptools-devel
%else
BuildRequires: python-setuptools
%endif
%description
python-bugzilla is a python library for interacting with bugzilla instances
over XML-RPC. Currently it only supports the Red Hat Bugzilla web services.
This package also includes the 'bugzilla' commandline tool for interacting with
bugzilla.
%prep
%setup -q
%build
# fix rpmlint complaint (this is fixed in git)
sed -i -e 's|^#!/usr/bin/python|# -*- python -*-|' bugzilla.py
%{__python} setup.py build
%install
rm -rf $RPM_BUILD_ROOT
%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
# fix rpmlint complaint
chmod -x selftest.py
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc COPYING README TODO PKG-INFO selftest.py
%{python_sitelib}/*
%{_bindir}/bugzilla
%changelog
* Sat Jan 12 2008 Will Woods <wwoods@redhat.com> 0.3-1
- Update to python-bugzilla 0.3
- 'modify' works in the commandline-util
- add Bug.close() and Bug.setstatus()
* Thu Dec 13 2007 Will Woods <wwoods@redhat.com> 0.2-4
- use _bindir instead of /usr/bin and proper BR for setuptools
* Tue Dec 11 2007 Will Woods <wwoods@redhat.com> 0.2-3
- Fix a couple of things rpmlint complained about
* Tue Dec 11 2007 Will Woods <wwoods@redhat.com> 0.2-2
- Add docs
* Wed Oct 10 2007 Will Woods <wwoods@redhat.com> 0.2-1
- Initial packaging.