Seth Vidal aacc182
%if ! (0%{?fedora} > 12 || 0%{?rhel} > 5)
Seth Vidal aacc182
%{!?python_sitelib: %global python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")}
Seth Vidal aacc182
%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
Seth Vidal aacc182
%endif
Seth Vidal aacc182
Seth Vidal aacc182
Seth Vidal aacc182
Summary:    Python bindings for lzma
Seth Vidal aacc182
Name:       pyliblzma
Seth Vidal aacc182
Version:    0.5.3
031a580
Release:    8%{?dist}
Seth Vidal aacc182
License:    LGPLv3+
Seth Vidal aacc182
URL:        https://launchpad.net/pyliblzma
Seth Vidal aacc182
Source0:    http://pypi.python.org/packages/source/p/pyliblzma/%{name}-%{version}.tar.bz2
Seth Vidal aacc182
Patch0:     no-script-liblzma.patch
Seth Vidal aacc182
Seth Vidal aacc182
BuildRequires:    xz-devel python-setuptools python2-devel
Seth Vidal aacc182
BuildRoot:    %{_tmppath}/%{name}-%{version}-%{release}-buildroot
Seth Vidal aacc182
Seth Vidal aacc182
%description
Seth Vidal aacc182
PylibLZMA provides a python interface for the liblzma library
Seth Vidal aacc182
to read and write data that has been compressed or can be decompressed
Seth Vidal aacc182
by Lasse Collin's lzma utils.
Seth Vidal aacc182
Seth Vidal aacc182
%prep
Seth Vidal aacc182
%setup -qn %{name}-%{version}
Seth Vidal aacc182
Seth Vidal aacc182
%patch0 -p1 
Seth Vidal aacc182
Seth Vidal aacc182
%build
Seth Vidal aacc182
%{__python} setup.py build
Seth Vidal aacc182
Seth Vidal aacc182
%check
Seth Vidal aacc182
%{__python} setup.py test
Seth Vidal aacc182
Seth Vidal aacc182
%install
Seth Vidal aacc182
rm -rf %{buildroot}
Seth Vidal aacc182
%{__python} setup.py install --root=%{buildroot}
Seth Vidal aacc182
Seth Vidal aacc182
%clean
Seth Vidal aacc182
rm -rf %{buildroot}
Seth Vidal aacc182
Seth Vidal aacc182
%files
Seth Vidal aacc182
%defattr(-,root,root)
Seth Vidal aacc182
%doc README THANKS ChangeLog NEWS
Seth Vidal aacc182
%attr(0755,-,-) %{python_sitearch}/lzma.so
Seth Vidal aacc182
%{python_sitearch}/liblzma.py*
Seth Vidal aacc182
%{python_sitearch}/%{name}*.egg-info
Seth Vidal aacc182
Seth Vidal aacc182
%changelog
031a580
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.5.3-8
031a580
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
031a580
03b4101
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.5.3-7
03b4101
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
03b4101
03c401d
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.5.3-6
03c401d
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
03c401d
2bd156e
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.5.3-5
2bd156e
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
2bd156e
d6350c8
* Tue Jul 27 2010 David Malcolm <dmalcolm@redhat.com> - 0.5.3-4
d6350c8
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
d6350c8
Seth Vidal aacc182
* Fri Jun  4 2010 Seth Vidal <skvidal at fedoraproject.org> - 0.5.3-3
Seth Vidal aacc182
- set perms on lzma.so to 0755 so wonky umasks don't impact it
Seth Vidal aacc182
Seth Vidal aacc182
* Fri May 14 2010 Seth Vidal <skvidal at fedoraproject.org> - 0.5.3-1
Seth Vidal aacc182
- cleanup from upstream spec to fedora-ish style/reqs
Seth Vidal aacc182