Blame SPECS/python-augeas.spec

293f9f
# sitelib for noarch packages, sitearch for others (remove the unneeded one)
293f9f
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
293f9f
293f9f
%if ! 0%{?fedora}%{?rhel} || 0%{?fedora} >= 9 || 0%{?rhel} >= 6
293f9f
%bcond_without egg
293f9f
%endif
293f9f
293f9f
%global with_python3 0
293f9f
293f9f
Name:		python-augeas
293f9f
Version:	0.5.0
293f9f
Release:	2%{?dist}
293f9f
Summary:	Python bindings to augeas
293f9f
Group:		Development/Languages
293f9f
License:	LGPLv2+
293f9f
URL:		http://augeas.net/
293f9f
Source0:	http://fedorahosted.org/released/%{name}/%{name}-%{version}.tar.gz
293f9f
BuildRoot:	%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
293f9f
Requires:	augeas-libs
293f9f
BuildArch:	noarch
293f9f
293f9f
BuildRequires:	python-setuptools python-devel
293f9f
%if 0%{?with_python3}
293f9f
BuildRequires:	python3-setuptools python3-devel
293f9f
%endif # with_python3
293f9f
293f9f
%description
293f9f
python-augeas is a set of Python bindings around augeas.
293f9f
293f9f
293f9f
%if 0%{?with_python3}
293f9f
%package -n python3-augeas
293f9f
Summary:	Python 3 bindings to augeas
293f9f
Requires:	augeas-libs
293f9f
293f9f
%description -n python3-augeas
293f9f
python3-augeas is a set of Python bindings around augeas.
293f9f
%endif # with_python3
293f9f
293f9f
293f9f
%prep
293f9f
%setup -q
293f9f
293f9f
%if 0%{?with_python3}
293f9f
rm -rf %{py3dir}
293f9f
cp -a . %{py3dir}
293f9f
%endif # with_python3
293f9f
293f9f
%build
293f9f
# Remove CFLAGS=... for noarch packages (unneeded)
293f9f
CFLAGS="$RPM_OPT_FLAGS"
293f9f
%{__python} setup.py build_ext -i
293f9f
%{__python} setup.py build
293f9f
293f9f
%if 0%{?with_python3}
293f9f
pushd %{py3dir}
293f9f
%{__python3} setup.py build_ext -i
293f9f
%{__python3} setup.py build
293f9f
popd
293f9f
%endif # with_python3
293f9f
293f9f
%install
293f9f
rm -rf $RPM_BUILD_ROOT
293f9f
%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
293f9f
293f9f
%if 0%{?with_python3}
293f9f
pushd %{py3dir}
293f9f
%{__python3} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT
293f9f
popd
293f9f
%endif # with_python3
293f9f
293f9f
%files
293f9f
%doc COPYING AUTHORS README.txt
293f9f
%{python_sitelib}/augeas.py*
293f9f
%if %{with egg}
293f9f
%{python_sitelib}/*augeas*.egg-info
293f9f
%endif
293f9f
293f9f
%if 0%{?with_python3}
293f9f
%files -n python3-augeas
293f9f
%doc COPYING AUTHORS README.txt
293f9f
%{python3_sitelib}/*
293f9f
%endif # with_python3
293f9f
293f9f
293f9f
%changelog
293f9f
* Mon Sep 22 2014 Tomas Radej <tradej@redhat.com> - 0.5.0-2
293f9f
- Added Python 3 subpackage
293f9f
293f9f
* Thu Sep 04 2014 Greg Swift <gregswift@gmail.com> - 0.5.0-1
293f9f
- Version 0.5.0 release
293f9f
293f9f
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-6
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
293f9f
293f9f
* Tue Oct 22 2013 Greg Swift <gregswift@gmail.com> - 0.4.1-5
293f9f
- add python-ctypes dependency (rhbz#1020239)
293f9f
293f9f
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-4
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
293f9f
293f9f
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-3
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
293f9f
293f9f
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.4.1-2
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
293f9f
293f9f
* Mon Jan 16 2012 Greg Swift <gregswift@gmail.com> 0.4.1-1
293f9f
- version 0.4.1
293f9f
- include egg only on F-9, RHEL-6 and later
293f9f
293f9f
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.0-8
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
293f9f
293f9f
* Fri Feb 18 2011 Harald Hoyer <harald@redhat.com> 0.3.0-7
293f9f
- only include egg-info, if fedora >=9 or rhel >= 6
293f9f
Resolves: rhbz#661452
293f9f
293f9f
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.0-6
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
293f9f
293f9f
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 0.3.0-5
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild
293f9f
293f9f
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.0-4
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
293f9f
293f9f
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.3.0-3
293f9f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
293f9f
293f9f
* Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 0.3.0-2
293f9f
- Rebuild for Python 2.6
293f9f
293f9f
* Tue Sep 09 2008 Harald Hoyer <harald@redhat.com> 0.3.0-1
293f9f
- version 0.3.0
293f9f
293f9f
* Thu Jul 03 2008 Harald Hoyer <harald@redhat.com> 0.2.1-1
293f9f
- version 0.2.1
293f9f
293f9f
* Wed Jun 11 2008 Harald Hoyer <harald@redhat.com> 0.2.0-1
293f9f
- switched to noarch, dlopen/ python bindings
293f9f
293f9f
* Mon May 05 2008 Harald Hoyer <harald@redhat.com> 0.1.0-4
293f9f
- version to import in CVS (rhbz#444945)
293f9f
293f9f
* Mon May 05 2008 Harald Hoyer <harald@redhat.com> 0.1.0-3
293f9f
- set mode of _augeas.so to 0755
293f9f
293f9f
* Mon May 05 2008 Harald Hoyer <harald@redhat.com> 0.1.0-2
293f9f
- wildcard to catch egg-info in case it is build
293f9f
293f9f
* Fri May 02 2008 Harald Hoyer <harald@redhat.com> 0.1.0-1
293f9f
- new version
293f9f
293f9f
* Wed Apr 16 2008 Harald Hoyer <harald@redhat.com> - 0.0.8-1
293f9f
- initial version