Compare commits
21 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
b71463d9af | ||
|
52a1c8bfaf | ||
|
d32b10b877 | ||
|
e8f5fc9089 | ||
|
791a789e24 | ||
|
775cb0e480 | ||
|
0ae7d75235 | ||
|
10bc59882e | ||
|
b244549e30 | ||
|
197cf98baa | ||
|
c514058933 | ||
|
fd1528e088 | ||
|
6e7f603dca | ||
|
c37e0a86d4 | ||
|
7d25590c0f | ||
|
e54c3fce0a | ||
|
85315a929d | ||
|
2f159223e6 | ||
|
914d8b9212 | ||
|
32e3694413 | ||
|
e15d28a3aa |
9
.gitignore
vendored
9
.gitignore
vendored
@ -3,3 +3,12 @@
|
|||||||
/pyparted-3.11.0.tar.gz
|
/pyparted-3.11.0.tar.gz
|
||||||
/pyparted-3.11.2.tar.gz
|
/pyparted-3.11.2.tar.gz
|
||||||
/pyparted-3.11.2.tar.gz.asc
|
/pyparted-3.11.2.tar.gz.asc
|
||||||
|
/pyparted-3.11.3.tar.gz
|
||||||
|
/pyparted-3.11.4.tar.gz
|
||||||
|
/pyparted-3.11.4.tar.gz.asc
|
||||||
|
/pyparted-3.11.5.tar.gz
|
||||||
|
/pyparted-3.11.5.tar.gz.asc
|
||||||
|
/pyparted-3.11.7.tar.gz
|
||||||
|
/pyparted-3.11.7.tar.gz.asc
|
||||||
|
/pyparted-3.12.0.tar.gz
|
||||||
|
/pyparted-3.12.0.tar.gz.asc
|
||||||
|
BIN
keyring.gpg
Normal file
BIN
keyring.gpg
Normal file
Binary file not shown.
85
pyparted-3.12.0-partition-types.patch
Normal file
85
pyparted-3.12.0-partition-types.patch
Normal file
@ -0,0 +1,85 @@
|
|||||||
|
diff -up pyparted-3.12.0/src/parted/__init__.py.orig pyparted-3.12.0/src/parted/__init__.py
|
||||||
|
--- pyparted-3.12.0/src/parted/__init__.py.orig 2022-03-07 12:38:56.000000000 -0500
|
||||||
|
+++ pyparted-3.12.0/src/parted/__init__.py 2022-06-21 15:05:10.318939409 -0400
|
||||||
|
@@ -217,6 +217,14 @@ from _ped import DISK_GPT_PMBR_BOOT
|
||||||
|
from _ped import DISK_TYPE_EXTENDED
|
||||||
|
from _ped import DISK_TYPE_PARTITION_NAME
|
||||||
|
|
||||||
|
+if hasattr(_ped, 'DISK_TYPE_PARTITION_TYPE_ID'):
|
||||||
|
+ # pylint: disable=E0611
|
||||||
|
+ from _ped import DISK_TYPE_PARTITION_TYPE_ID
|
||||||
|
+
|
||||||
|
+if hasattr(_ped, 'DISK_TYPE_PARTITION_TYPE_UUID'):
|
||||||
|
+ # pylint: disable=E0611
|
||||||
|
+ from _ped import DISK_TYPE_PARTITION_TYPE_UUID
|
||||||
|
+
|
||||||
|
from _ped import EXCEPTION_TYPE_INFORMATION
|
||||||
|
from _ped import EXCEPTION_TYPE_WARNING
|
||||||
|
from _ped import EXCEPTION_TYPE_ERROR
|
||||||
|
diff -up pyparted-3.12.0/src/_pedmodule.c.orig pyparted-3.12.0/src/_pedmodule.c
|
||||||
|
--- pyparted-3.12.0/src/_pedmodule.c.orig 2022-03-07 12:49:11.000000000 -0500
|
||||||
|
+++ pyparted-3.12.0/src/_pedmodule.c 2022-06-21 15:04:57.863977820 -0400
|
||||||
|
@@ -685,6 +685,14 @@ MOD_INIT(_ped) {
|
||||||
|
PyModule_AddIntConstant(m, "DISK_TYPE_EXTENDED", PED_DISK_TYPE_EXTENDED);
|
||||||
|
PyModule_AddIntConstant(m, "DISK_TYPE_PARTITION_NAME", PED_DISK_TYPE_PARTITION_NAME);
|
||||||
|
|
||||||
|
+#if PED_DISK_TYPE_LAST_FEATURE > 2
|
||||||
|
+ PyModule_AddIntConstant(m, "DISK_TYPE_PARTITION_TYPE_ID", PED_DISK_TYPE_PARTITION_TYPE_ID);
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
+#if PED_DISK_TYPE_LAST_FEATURE > 4
|
||||||
|
+ PyModule_AddIntConstant(m, "DISK_TYPE_PARTITION_TYPE_UUID", PED_DISK_TYPE_PARTITION_TYPE_UUID);
|
||||||
|
+#endif
|
||||||
|
+
|
||||||
|
/* add PedFileSystemType as _ped.FileSystemType */
|
||||||
|
if (PyType_Ready(&_ped_FileSystemType_Type_obj) < 0)
|
||||||
|
return MOD_ERROR_VAL;
|
||||||
|
diff -up pyparted-3.12.0/tests/test__ped_disktype.py.orig pyparted-3.12.0/tests/test__ped_disktype.py
|
||||||
|
--- pyparted-3.12.0/tests/test__ped_disktype.py.orig 2018-01-12 13:31:40.000000000 -0500
|
||||||
|
+++ pyparted-3.12.0/tests/test__ped_disktype.py 2022-06-21 15:04:57.863977820 -0400
|
||||||
|
@@ -63,11 +63,22 @@ class DiskTypeCheckFeatureTestCase(Requi
|
||||||
|
self.assertTrue(self.disktype[name].check_feature(_ped.DISK_TYPE_EXTENDED))
|
||||||
|
self.assertFalse(self.disktype[name].check_feature(_ped.DISK_TYPE_PARTITION_NAME))
|
||||||
|
|
||||||
|
+ if hasattr(_ped, "DISK_TYPE_PARTITION_TYPE_ID"):
|
||||||
|
+ self.assertTrue(self.disktype[name].check_feature(_ped.DISK_TYPE_PARTITION_TYPE_ID))
|
||||||
|
+
|
||||||
|
+ if hasattr(_ped, "DISK_TYPE_PARTITION_TYPE_UUID"):
|
||||||
|
+ self.assertFalse(self.disktype[name].check_feature(_ped.DISK_TYPE_PARTITION_TYPE_UUID))
|
||||||
|
+
|
||||||
|
# The following types support DISK_TYPE_PARTITION_NAME
|
||||||
|
for name in ['amiga', 'gpt', 'mac', 'pc98']:
|
||||||
|
self.assertFalse(self.disktype[name].check_feature(_ped.DISK_TYPE_EXTENDED))
|
||||||
|
self.assertTrue(self.disktype[name].check_feature(_ped.DISK_TYPE_PARTITION_NAME))
|
||||||
|
|
||||||
|
+ # The following types support DISK_TYPE_PARTITION_TYPE_UUID
|
||||||
|
+ for name in ['gpt']:
|
||||||
|
+ if hasattr(_ped, "DISK_TYPE_PARTITION_TYPE_UUID"):
|
||||||
|
+ self.assertTrue(self.disktype[name].check_feature(_ped.DISK_TYPE_PARTITION_TYPE_UUID))
|
||||||
|
+
|
||||||
|
# The following types support all features
|
||||||
|
for name in ['dvh']:
|
||||||
|
self.assertTrue(self.disktype[name].check_feature(_ped.DISK_TYPE_EXTENDED))
|
||||||
|
@@ -75,11 +86,20 @@ class DiskTypeCheckFeatureTestCase(Requi
|
||||||
|
|
||||||
|
class DiskTypeStrTestCase(RequiresDiskTypes):
|
||||||
|
def runTest(self):
|
||||||
|
- self.assertEqual(str(self.disktype['msdos']), '_ped.DiskType instance --\n name: msdos features: 1')
|
||||||
|
+ if hasattr(_ped, "DISK_TYPE_PARTITION_TYPE_ID"):
|
||||||
|
+ self.assertEqual(str(self.disktype['msdos']), '_ped.DiskType instance --\n name: msdos features: 5')
|
||||||
|
+ else:
|
||||||
|
+ self.assertEqual(str(self.disktype['msdos']), '_ped.DiskType instance --\n name: msdos features: 1')
|
||||||
|
+
|
||||||
|
self.assertEqual(str(self.disktype['aix']), '_ped.DiskType instance --\n name: aix features: 0')
|
||||||
|
self.assertEqual(str(self.disktype['sun']), '_ped.DiskType instance --\n name: sun features: 0')
|
||||||
|
self.assertEqual(str(self.disktype['amiga']), '_ped.DiskType instance --\n name: amiga features: 2')
|
||||||
|
- self.assertEqual(str(self.disktype['gpt']), '_ped.DiskType instance --\n name: gpt features: 2')
|
||||||
|
+
|
||||||
|
+ if hasattr(_ped, "DISK_TYPE_PARTITION_TYPE_UUID"):
|
||||||
|
+ self.assertEqual(str(self.disktype['gpt']), '_ped.DiskType instance --\n name: gpt features: 10')
|
||||||
|
+ else:
|
||||||
|
+ self.assertEqual(str(self.disktype['gpt']), '_ped.DiskType instance --\n name: gpt features: 2')
|
||||||
|
+
|
||||||
|
self.assertEqual(str(self.disktype['mac']), '_ped.DiskType instance --\n name: mac features: 2')
|
||||||
|
self.assertEqual(str(self.disktype['bsd']), '_ped.DiskType instance --\n name: bsd features: 0')
|
||||||
|
self.assertEqual(str(self.disktype['pc98']), '_ped.DiskType instance --\n name: pc98 features: 2')
|
134
pyparted.spec
134
pyparted.spec
@ -22,41 +22,43 @@
|
|||||||
%bcond_without python3
|
%bcond_without python3
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
# XXX: uncomment this when things that use python2-pyparted can use
|
%if %{fedora} > 31
|
||||||
# the python3 version. Be sure to change '28' to the appropriate
|
# disable python2 by default
|
||||||
# version number. Also, replace all the '@' signs with '%' because
|
%bcond_with python2
|
||||||
# I cannot remember this macro construct, I'm just commenting it out.
|
%else
|
||||||
# --dcantrell
|
|
||||||
#@if @{fedora} > 28
|
|
||||||
## disable python2 by default
|
|
||||||
#@bcond_with python2
|
|
||||||
#@else
|
|
||||||
#@bcond_without python2
|
|
||||||
#@endif
|
|
||||||
|
|
||||||
# XXX: And delete this when you can disable python2 by default. --dcantrell
|
|
||||||
%bcond_without python2
|
%bcond_without python2
|
||||||
|
%endif
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
Summary: Python module for GNU parted
|
Summary: Python module for GNU parted
|
||||||
Name: pyparted
|
Name: pyparted
|
||||||
Epoch: 1
|
Epoch: 1
|
||||||
Version: 3.11.2
|
Version: 3.12.0
|
||||||
Release: 3%{?dist}
|
Release: 6%{?dist}
|
||||||
License: GPLv2+
|
License: GPLv2+
|
||||||
URL: https://github.com/rhinstaller/pyparted
|
URL: https://github.com/dcantrell/pyparted
|
||||||
|
|
||||||
Source0: https://github.com/rhinstaller/pyparted/archive/%{name}-%{version}.tar.gz
|
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
|
||||||
|
|
||||||
|
# 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-partition-types.patch
|
||||||
|
|
||||||
|
BuildRequires: make
|
||||||
BuildRequires: gcc
|
BuildRequires: gcc
|
||||||
BuildRequires: parted-devel >= 3.2-18
|
BuildRequires: parted-devel >= 3.3
|
||||||
BuildRequires: pkgconfig
|
BuildRequires: pkgconfig
|
||||||
BuildRequires: e2fsprogs
|
BuildRequires: e2fsprogs
|
||||||
|
BuildRequires: gnupg2
|
||||||
|
|
||||||
%if %{with python3}
|
%if %{with python3}
|
||||||
BuildRequires: python3-devel
|
BuildRequires: python3-devel
|
||||||
BuildRequires: python3-six
|
BuildRequires: python3-six
|
||||||
|
BuildRequires: python3-setuptools
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if %{with python2}
|
%if %{with python2}
|
||||||
@ -92,22 +94,26 @@ partition tables. This package provides Python 3 bindings for parted.
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
|
# Verify source archive signature
|
||||||
|
gpg --no-default-keyring --keyring %{SOURCE2} --trustdb-name %{SOURCE3} --verify %{SOURCE1} %{SOURCE0} || exit 1
|
||||||
|
|
||||||
%setup -q
|
%setup -q
|
||||||
|
%patch0 -p1
|
||||||
|
|
||||||
%if %{with python3}
|
%if %{with python3}
|
||||||
rm -rf %{py3dir}
|
everything=$(ls)
|
||||||
mkdir -p %{py3dir}
|
mkdir -p py3dir
|
||||||
cp -a . %{py3dir}
|
cp -a $everything py3dir
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%if %{with python2}
|
%if %{with python2}
|
||||||
PYTHON=python2 make %{?_smp_mflags}
|
PYTHON=python2 %make_build CFLAGS="%{optflags} -fcommon"
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if %{with python3}
|
%if %{with python3}
|
||||||
pushd %{py3dir}
|
pushd py3dir
|
||||||
PYTHON=python3 make %{?_smp_mflags}
|
PYTHON=python3 %make_build CFLAGS="%{optflags} -fcommon"
|
||||||
popd
|
popd
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
@ -117,19 +123,19 @@ PYTHON=python2 make test
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if %{with python3}
|
%if %{with python3}
|
||||||
pushd %{py3dir}
|
pushd py3dir
|
||||||
PYTHON=python3 make test
|
PYTHON=python3 make test
|
||||||
popd
|
popd
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%if %{with python2}
|
%if %{with python2}
|
||||||
PYTHON=python2 make install DESTDIR=%{buildroot}
|
PYTHON=python2 %make_install
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if %{with python3}
|
%if %{with python3}
|
||||||
pushd %{py3dir}
|
pushd py3dir
|
||||||
PYTHON=python3 make install DESTDIR=%{buildroot}
|
PYTHON=python3 %make_install
|
||||||
popd
|
popd
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
@ -150,6 +156,76 @@ popd
|
|||||||
%endif
|
%endif
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Jul 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1:3.12.0-6
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Jun 21 2022 David Cantrell <dcantrell@redhat.com> - 1:3.12.0-5
|
||||||
|
- 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 (#2098792)
|
||||||
|
|
||||||
|
* Mon Jun 20 2022 Adam Williamson <awilliam@redhat.com> - 1:3.12.0-4
|
||||||
|
- Backport PR #92 to fix tests with parted 3.5 (#2098792)
|
||||||
|
|
||||||
|
* Mon Jun 13 2022 Python Maint <python-maint@redhat.com> - 1:3.12.0-3
|
||||||
|
- Rebuilt for Python 3.11
|
||||||
|
|
||||||
|
* Mon Mar 07 2022 David Cantrell <dcantrell@redhat.com> - 3.12.0-2
|
||||||
|
- BR python3-setuptools
|
||||||
|
|
||||||
|
* Mon Mar 07 2022 David Cantrell <dcantrell@redhat.com> - 3.12.0-1
|
||||||
|
- Upgrade to pyparted-3.12.0
|
||||||
|
|
||||||
|
* Fri Jan 21 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1:3.11.7-5
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1:3.11.7-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jun 03 2021 Python Maint <python-maint@redhat.com> - 1:3.11.7-3
|
||||||
|
- Rebuilt for Python 3.10
|
||||||
|
|
||||||
|
* 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
|
* Fri Aug 16 2019 Miro Hrončok <mhroncok@redhat.com> - 1:3.11.2-3
|
||||||
- Rebuilt for Python 3.8
|
- Rebuilt for Python 3.8
|
||||||
|
|
||||||
|
4
sources
4
sources
@ -1,2 +1,2 @@
|
|||||||
SHA512 (pyparted-3.11.2.tar.gz) = c91b3113951f3bb032f5c1309b5c301754b1aa9a5347a3bf4bbd6d6d23c929da63fbbe8e922660af6249c1037e9594ceb73fd28b77c2fda5f0833b1816f002f3
|
SHA512 (pyparted-3.12.0.tar.gz) = 0179e5334be8c04287b10b47d407ad339933cd3e20514d2142fe968acf8a36c40e541ee5165e2b3699a40b133d8f1948d8d12ccf307d3a1736090fb33f28b7e7
|
||||||
SHA512 (pyparted-3.11.2.tar.gz.asc) = 4fba573c319518db3b3c9d80f65a8869f687c7abc028b3a153088adfe09b203987983b8e8f4e79e8ff3e0a6c6e584df140d13ac1d276e4f3a691d4e1dd33b60d
|
SHA512 (pyparted-3.12.0.tar.gz.asc) = 452d386fbc8b84fa0dc186bb75c6c12eb051c8a37575e5a3a0cf504d13c4b2a0134d7e486928f9af7d142d25802bda05c97fd95ff80721ae6f6c0abedb8b1614
|
||||||
|
BIN
trustdb.gpg
Normal file
BIN
trustdb.gpg
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user