|
|
|
@ -22,7 +22,7 @@
|
|
|
|
|
%bcond_without python3
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{fedora} > 31
|
|
|
|
|
%if %{fedora} > 28
|
|
|
|
|
# disable python2 by default
|
|
|
|
|
%bcond_with python2
|
|
|
|
|
%else
|
|
|
|
@ -30,35 +30,29 @@
|
|
|
|
|
%endif
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%global py2dir python2-build
|
|
|
|
|
|
|
|
|
|
Summary: Python module for GNU parted
|
|
|
|
|
Name: pyparted
|
|
|
|
|
Epoch: 1
|
|
|
|
|
Version: 3.12.0
|
|
|
|
|
Release: 1%{?dist}
|
|
|
|
|
Version: 3.11.7
|
|
|
|
|
Release: 4%{?dist}
|
|
|
|
|
License: GPLv2+
|
|
|
|
|
URL: https://github.com/dcantrell/pyparted
|
|
|
|
|
Group: System Environment/Libraries
|
|
|
|
|
URL: https://github.com/rhinstaller/pyparted
|
|
|
|
|
|
|
|
|
|
Source0: https://github.com/dcantrell/pyparted/releases/download/v%{version}/%{name}-%{version}.tar.gz
|
|
|
|
|
Source1: https://github.com/dcantrell/pyparted/releases/download/v%{version}/%{name}-%{version}.tar.gz.asc
|
|
|
|
|
Source2: keyring.gpg
|
|
|
|
|
Source3: trustdb.gpg
|
|
|
|
|
Source0: https://github.com/rhinstaller/pyparted/archive/%{name}-%{version}.tar.gz
|
|
|
|
|
|
|
|
|
|
# Support new disk type features from parted 3.5:
|
|
|
|
|
# https://bugzilla.redhat.com/show_bug.cgi?id=2098792
|
|
|
|
|
# https://github.com/dcantrell/pyparted/issues/91
|
|
|
|
|
Patch0: pyparted-3.12.0-types.patch
|
|
|
|
|
Patch0: pyparted-3.11.7-covscan.patch
|
|
|
|
|
|
|
|
|
|
BuildRequires: make
|
|
|
|
|
BuildRequires: gcc
|
|
|
|
|
BuildRequires: parted-devel >= 3.5
|
|
|
|
|
BuildRequires: parted-devel >= 3.2-18
|
|
|
|
|
BuildRequires: pkgconfig
|
|
|
|
|
BuildRequires: e2fsprogs
|
|
|
|
|
BuildRequires: gnupg2
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
BuildRequires: python3-devel
|
|
|
|
|
BuildRequires: python3-six
|
|
|
|
|
BuildRequires: python3-setuptools
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with python2}
|
|
|
|
@ -86,7 +80,11 @@ Obsoletes: pyparted < %{epoch}:%{version}-%{release}
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
%package -n python3-pyparted
|
|
|
|
|
Summary: Python 3 module for GNU parted
|
|
|
|
|
Summary: Python 3 module for GNU parted
|
|
|
|
|
Group: System Environment/Libraries
|
|
|
|
|
%if !%{with python2}
|
|
|
|
|
Provides: pyparted = %{epoch}:%{version}-%{release}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%description -n python3-pyparted
|
|
|
|
|
Python module for the parted library. It is used for manipulating
|
|
|
|
@ -94,57 +92,47 @@ partition tables. This package provides Python 3 bindings for parted.
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
# Verify source archive signature
|
|
|
|
|
gpg --no-default-keyring --keyring %{SOURCE2} --trustdb-name %{SOURCE3} --verify %{SOURCE1} %{SOURCE0} || exit 1
|
|
|
|
|
|
|
|
|
|
%setup -q
|
|
|
|
|
%patch0 -p1
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
everything=$(ls)
|
|
|
|
|
mkdir -p py3dir
|
|
|
|
|
cp -a $everything py3dir
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
PYTHON=python2 %make_build CFLAGS="%{optflags} -fcommon"
|
|
|
|
|
rm -rf ../%{py2dir}
|
|
|
|
|
mkdir -p ../%{py2dir}
|
|
|
|
|
cp -a . ../%{py2dir}
|
|
|
|
|
mv ../%{py2dir} .
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
pushd py3dir
|
|
|
|
|
PYTHON=python3 %make_build CFLAGS="%{optflags} -fcommon"
|
|
|
|
|
popd
|
|
|
|
|
PYTHON=python3 CFLAGS="%{optflags}" make %{?_smp_mflags}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
PYTHON=python2 make test
|
|
|
|
|
pushd %{py2dir}
|
|
|
|
|
PYTHON=python2 CFLAGS="%{optflags}" make %{?_smp_mflags}
|
|
|
|
|
popd
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%check
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
pushd py3dir
|
|
|
|
|
PYTHON=python3 make test
|
|
|
|
|
popd
|
|
|
|
|
PYTHON=python3 CFLAGS="%{optflags}" make test
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
PYTHON=python2 %make_install
|
|
|
|
|
pushd %{py2dir}
|
|
|
|
|
PYTHON=python2 CFLAGS="%{optflags}" make test
|
|
|
|
|
popd
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
%if %{with python3}
|
|
|
|
|
pushd py3dir
|
|
|
|
|
PYTHON=python3 %make_install
|
|
|
|
|
popd
|
|
|
|
|
PYTHON=python3 CFLAGS="%{optflags}" make install DESTDIR=%{buildroot}
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
%files -n python2-pyparted
|
|
|
|
|
%doc AUTHORS COPYING NEWS README TODO
|
|
|
|
|
%{python2_sitearch}/_ped.so
|
|
|
|
|
%{python2_sitearch}/parted
|
|
|
|
|
%{python2_sitearch}/%{name}-%{version}-*.egg-info
|
|
|
|
|
pushd %{py2dir}
|
|
|
|
|
PYTHON=python2 CFLAGS="%{optflags}" make install DESTDIR=%{buildroot}
|
|
|
|
|
popd
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with python3}
|
|
|
|
@ -155,106 +143,65 @@ popd
|
|
|
|
|
%{python3_sitearch}/%{name}-%{version}-*.egg-info
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%if %{with python2}
|
|
|
|
|
%files -n python2-pyparted
|
|
|
|
|
%doc AUTHORS COPYING NEWS README TODO
|
|
|
|
|
%{python2_sitearch}/_ped.so
|
|
|
|
|
%{python2_sitearch}/parted
|
|
|
|
|
%{python2_sitearch}/%{name}-%{version}-*.egg-info
|
|
|
|
|
%endif
|
|
|
|
|
|
|
|
|
|
%changelog
|
|
|
|
|
* Tue Jun 21 2022 David Cantrell <dcantrell@redhat.com> - 1:3.12.0-1
|
|
|
|
|
- Patch pyparted to handle PED_DISK_TYPE_PARTITION_TYPE_ID for the
|
|
|
|
|
msdos disk type and PED_DISK_TYPE_PARTITION_TYPE_UUID for the gpt
|
|
|
|
|
label
|
|
|
|
|
Resolves: rhbz#2103243
|
|
|
|
|
|
|
|
|
|
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 1:3.11.7-4
|
|
|
|
|
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
|
|
|
|
|
Related: rhbz#1991688
|
|
|
|
|
|
|
|
|
|
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 1:3.11.7-3
|
|
|
|
|
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
|
|
|
|
|
|
|
|
|
|
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1:3.11.7-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Oct 23 2020 David Cantrell <dcantrell@redhat.com> - 1:3.11.7-1
|
|
|
|
|
- Upgrade to pyparted-3.11.7 (BZ#1890443)
|
|
|
|
|
- Set PY_SSIZE_T_CLEAN for the build (bcl)
|
|
|
|
|
- add nvme support
|
|
|
|
|
- Update RELEASE file to make last step be "make pypi" (dcantrell)
|
|
|
|
|
|
|
|
|
|
* Tue Jul 14 2020 Tom Stellard <tstellar@redhat.com> - 1:3.11.5-3
|
|
|
|
|
- Use make macros
|
|
|
|
|
- https://fedoraproject.org/wiki/Changes/UseMakeBuildInstallMacro
|
|
|
|
|
|
|
|
|
|
* Sat May 23 2020 Miro Hrončok <mhroncok@redhat.com> - 1:3.11.5-2
|
|
|
|
|
- Rebuilt for Python 3.9
|
|
|
|
|
|
|
|
|
|
* Mon Mar 09 2020 David Cantrell <dcantrell@redhat.com> - 1:3.11.5-1
|
|
|
|
|
- Require at least libparted 3.3 and python 3.7 (dcantrell)
|
|
|
|
|
- pedmodule.c: Fix partition enum flag handling (bcl)
|
|
|
|
|
- Add support for chromeos_kernel and bls_boot partition flags (bcl)
|
|
|
|
|
- Move exception declarations to _pedmodule.c (dcantrell)
|
|
|
|
|
|
|
|
|
|
* Tue Feb 11 2020 David Cantrell <dcantrell@redhat.com> - 1:3.11.4-1
|
|
|
|
|
- Use Decimal for Device.getSize() operations, return a
|
|
|
|
|
float (#1801355)
|
|
|
|
|
- Update the 'twine upload' line in the Makefile
|
|
|
|
|
- Don't intentionally prohibit Python 2 usage (#67)
|
|
|
|
|
- mips64 support
|
|
|
|
|
|
|
|
|
|
* Thu Jan 30 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1:3.11.3-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Nov 15 2019 David Cantrell <dcantrell@redhat.com> - 1:3.11.3-1
|
|
|
|
|
- Fix deprecation warning in parted/cachedlist.py (#1772060)
|
|
|
|
|
|
|
|
|
|
* Sun Oct 20 2019 Miro Hrončok <mhroncok@redhat.com> - 1:3.11.2-5
|
|
|
|
|
- Remove python2-pyparted from Fedora 32+
|
|
|
|
|
|
|
|
|
|
* Thu Oct 03 2019 Miro Hrončok <mhroncok@redhat.com> - 1:3.11.2-4
|
|
|
|
|
- Rebuilt for Python 3.8.0rc1 (#1748018)
|
|
|
|
|
|
|
|
|
|
* Fri Aug 16 2019 Miro Hrončok <mhroncok@redhat.com> - 1:3.11.2-3
|
|
|
|
|
- Rebuilt for Python 3.8
|
|
|
|
|
|
|
|
|
|
* Fri Jul 26 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1:3.11.2-2
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
|
|
|
|
|
|
|
|
|
* Fri Feb 01 2019 David Cantrell <dcantrell@redhat.com> - 1:3.11.2-1
|
|
|
|
|
- pyparted-3.11.2 (dcantrell)
|
|
|
|
|
- Do not remove the generated tarballs. (dcantrell)
|
|
|
|
|
- Update the RELEASE file. (dcantrell)
|
|
|
|
|
- tests: Fix flag_get_name tests (bcl)
|
|
|
|
|
- Avoid potential NULL dereferences in pydisk.c and pytimer.c
|
|
|
|
|
(dcantrell)
|
|
|
|
|
- New - example to query device capacity (jflorian)
|
|
|
|
|
- correct spelling mistake (edward)
|
|
|
|
|
- _ped's *_flag_get_name methods now throw a PartedException instead of
|
|
|
|
|
ValueError on unsupported flags. (lukasz.zemczak)
|
|
|
|
|
- Make the partition name a property on parted.Partition objects (#34)
|
|
|
|
|
(dcantrell)
|
|
|
|
|
* Mon Jul 12 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.7-4
|
|
|
|
|
- Rebuild for gating
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Fri Jul 09 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.7-3
|
|
|
|
|
- More covscan patch followup
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Tue Jul 31 2018 Florian Weimer <fweimer@redhat.com> - 1:3.11.0-17
|
|
|
|
|
- Rebuild with fixed binutils
|
|
|
|
|
* Fri Jul 09 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.7-2
|
|
|
|
|
- Patched errors found by covscan
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Fri Jul 27 2018 Igor Gnatenko <ignatenkobrain@fedoraproject.org> - 1:3.11.0-16
|
|
|
|
|
- Rebuild for new binutils
|
|
|
|
|
* Thu Jul 08 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.7-1
|
|
|
|
|
- Upgrade to pyparted-3.11.7
|
|
|
|
|
Resolves: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Thu Jul 26 2018 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-15
|
|
|
|
|
- Do not disable python2 builds by default. There are still some packages
|
|
|
|
|
that have not been updated to python3 and require python2-pyparted.
|
|
|
|
|
* Tue May 18 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-21
|
|
|
|
|
- Rebuild for gating
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Tue May 18 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-20
|
|
|
|
|
- Fixes for gating
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Mon May 17 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-19
|
|
|
|
|
- Rebuild for gating
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Mon May 17 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-18
|
|
|
|
|
- Rebuild for gating
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Mon May 17 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-17
|
|
|
|
|
- Rebuild
|
|
|
|
|
Related: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Wed Jul 25 2018 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-14
|
|
|
|
|
- Conditionalize python2 and python3 builds to make the SRPM more portable
|
|
|
|
|
across releases. On RHEL > 7 and Fedora > 28, do not build for python2.
|
|
|
|
|
On RHEL <= 7, do not build for python3.
|
|
|
|
|
* Tue Feb 23 2021 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-16
|
|
|
|
|
- Handle PED_EXCEPTION_FIX (Fix/Ignore) exceptions
|
|
|
|
|
Resolves: rhbz#1927379
|
|
|
|
|
|
|
|
|
|
* Tue Jul 24 2018 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-13
|
|
|
|
|
- Use 'python2' when building the Python 2.x bindings (#1605566)
|
|
|
|
|
- BuildRequires gcc (#1605566)
|
|
|
|
|
- %%{python_sitearch} -> %%{python2_sitearch} (#1605566)
|
|
|
|
|
* Wed Jul 25 2018 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-13
|
|
|
|
|
- Do not build python2 subpackage
|
|
|
|
|
Resolves: rhbz#1565329
|
|
|
|
|
|
|
|
|
|
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1:3.11.0-12
|
|
|
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
|
|
|
|
* Thu Jul 19 2018 David Cantrell <dcantrell@redhat.com> - 1:3.11.0-12
|
|
|
|
|
- Have python3-pyparted package provide 'pyparted'
|
|
|
|
|
Resolves: rhbz#1602333
|
|
|
|
|
|
|
|
|
|
* Fri Jun 15 2018 Miro Hrončok <mhroncok@redhat.com> - 1:3.11.0-11
|
|
|
|
|
- Rebuilt for Python 3.7
|
|
|
|
|
* Mon May 28 2018 Charalampos Stratakis <cstratak@redhat.com> - 1:3.11.0-11
|
|
|
|
|
- Conditionalize the python2 subpackage
|
|
|
|
|
|
|
|
|
|
* Mon Apr 02 2018 Adam Williamson <awilliam@redhat.com> - 1:3.11.0-10
|
|
|
|
|
- Make pyparted provides/obsoletes include the epoch
|
|
|
|
|