diff --git a/.gitignore b/.gitignore index f0061cb..09746ad 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1 @@ -pyparted-3.9.2.tar.gz -/pyparted-3.9.3.tar.gz -/pyparted-3.9.4.tar.gz -/pyparted-3.9.5.tar.gz +/pyparted-pyparted-3.10.4.tar.gz diff --git a/pyparted.spec b/pyparted.spec index 0a31842..59be362 100644 --- a/pyparted.spec +++ b/pyparted.spec @@ -1,16 +1,21 @@ +%define with_python3 1 + Summary: Python module for GNU parted Name: pyparted Epoch: 1 -Version: 3.9.5 -Release: 2%{?dist} +Version: 3.10.4 +Release: 1%{?dist} License: GPLv2+ Group: System Environment/Libraries -URL: http://fedorahosted.org/pyparted +URL: https://github.com/dcantrell/%{name} -Source0: http://fedorahosted.org/releases/p/y/%{name}/%{name}-%{version}.tar.gz +Source0: https://github.com/dcantrell/%{name}/releases/%{name}-%{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -u -n) BuildRequires: python-devel +%if 0%{?with_python3} +BuildRequires: python3-devel +%endif BuildRequires: parted-devel >= 3.1-14 BuildRequires: pkgconfig BuildRequires: e2fsprogs @@ -19,30 +24,79 @@ BuildRequires: e2fsprogs Python module for the parted library. It is used for manipulating partition tables. +%if 0%{?with_python3} +%package -n python3-pyparted +Summary: Python 3 module for GNU parted +Group: System Environment/Libraries + +%description -n python3-pyparted +Python module for the parted library. It is used for manipulating +partition tables. This package provides Python 3 bindings for parted. +%endif + %prep -%setup -q +%setup -q -n %{name}-%{name}-%{version} + +%if 0%{?with_python3} +rm -rf %{py3dir} +cp -a . %{py3dir} +%endif %build make %{?_smp_mflags} +%if 0%{?with_python3} +pushd %{py3dir} +PYTHON=python3 make %{?_smp_mflags} +popd +%endif + %install rm -rf %{buildroot} make install DESTDIR=%{buildroot} +%if 0%{?with_python3} +pushd %{py3dir} +PYTHON=python3 make install DESTDIR=%{buildroot} +popd +%endif + %check make test +%if 0%{?with_python3} +pushd %{py3dir} +PYTHON=python3 make test +popd +%endif + %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) -%doc AUTHORS BUGS COPYING ChangeLog NEWS README TODO -%{python_sitearch}/_pedmodule.so +%doc AUTHORS BUGS COPYING NEWS README TODO +%{python_sitearch}/_ped.so %{python_sitearch}/parted %{python_sitearch}/%{name}-%{version}-*.egg-info +%if 0%{?with_python3} +%files -n python3-pyparted +%defattr(-,root,root,-) +%doc AUTHORS BUGS COPYING NEWS README TODO +%{python3_sitearch}/_ped.*.so +%{python3_sitearch}/parted +%{python3_sitearch}/%{name}-%{version}-*.egg-info +%endif + %changelog +* Tue May 05 2015 David Cantrell - 1:3.10.4-1 +- Upgrade to pyparted-3.10.4 for multiple fixes and to add a Python 3 + subpackage (#1196402) + +* Mon Dec 01 2014 Adam Williamson - 1:3.9.5-3 +- backport resetNumber() function from 3.10 (needed to fix RHBZ #1166598) + * Sun Aug 17 2014 Fedora Release Engineering - 1:3.9.5-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild diff --git a/sources b/sources index 001af75..4fe5625 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -9cf098ec38b9fe0af98782671027c5d6 pyparted-3.9.5.tar.gz +f7b324cfd13210cc802c87628ecf8f35 pyparted-pyparted-3.10.4.tar.gz