Support gpt and msdos disk labels on aarch64 (#1095904)

This commit is contained in:
David Cantrell 2014-06-24 11:27:18 -04:00
parent d82d69a2e6
commit 04fb2099c4
4 changed files with 7 additions and 41 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
pyparted-3.9.2.tar.gz
/pyparted-3.9.3.tar.gz
/pyparted-3.9.4.tar.gz

View File

@ -1,36 +0,0 @@
diff -Nru a/src/parted/__init__.py pyparted-3.9.3/src/parted/__init__.py
--- a/src/parted/__init__.py 2014-05-07 15:07:58.000000000 -0400
+++ pyparted-3.9.3/src/parted/__init__.py 2014-05-29 11:57:09.813438402 -0400
@@ -278,7 +278,8 @@
'sparc': ['sun'],
'ia64': ['msdos', 'gpt'],
'ppc': ['msdos', 'mac', 'amiga', 'gpt'],
- 'x86_64': ['msdos', 'gpt']}
+ 'x86_64': ['msdos', 'gpt'],
+ 'aarch64': ['msdos', 'gpt']}
# Adapted from:
# http://stackoverflow.com/questions/922550/how-to-mark-a-global-as-deprecated-in-python
@@ -312,9 +313,9 @@
__archLabels = (('amiga', 'ppc(64)?$'),
('bsd', 'alpha$'),
('dasd', 's390x?$'),
- ('gpt', 'i[3-6]86$|x86_64$|ia64$|ppc(64)?$|armv7l$'),
+ ('gpt', 'i[3-6]86$|x86_64$|ia64$|ppc(64)?$|armv7l$|aarch64$'),
('mac', 'ppc(64)?$'),
- ('msdos', 'i[3-6]86$|x86_64$|s390x?$|alpha$|ia64$|ppc(64)?$|armv7l$'),
+ ('msdos', 'i[3-6]86$|x86_64$|s390x?$|alpha$|ia64$|ppc(64)?$|armv7l$|aarch64$'),
('sun', 'sparc(64)?$'))
def getLabels(arch=None):
diff -Nru a/tests/test_parted_parted.py pyparted-3.9.3/tests/test_parted_parted.py
--- a/tests/test_parted_parted.py 2014-05-07 15:07:58.000000000 -0400
+++ pyparted-3.9.3/tests/test_parted_parted.py 2014-05-29 11:56:10.049244277 -0400
@@ -60,6 +60,7 @@
self.assertSetEqual(parted.getLabels('alpha'), {'bsd', 'msdos'})
self.assertSetEqual(parted.getLabels('ia64'), {'gpt', 'msdos'})
self.assertSetEqual(parted.getLabels('armv7l'), {'gpt', 'msdos'})
+ self.assertSetEqual(parted.getLabels('aarch64'), {'gpt', 'msdos'})
class GetDeviceTestCase(RequiresDeviceNode):
def runTest(self):

View File

@ -1,14 +1,13 @@
Summary: Python module for GNU parted
Name: pyparted
Epoch: 1
Version: 3.9.3
Release: 3%{?dist}
Version: 3.9.4
Release: 1%{?dist}
License: GPLv2+
Group: System Environment/Libraries
URL: http://fedorahosted.org/pyparted
Source0: http://fedorahosted.org/releases/p/y/%{name}/%{name}-%{version}.tar.gz
Patch0: 0001-pyparted-3.9-aarch64.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(id -u -n)
BuildRequires: python-devel
@ -22,7 +21,6 @@ partition tables.
%prep
%setup -q
%patch0 -p1
%build
make %{?_smp_mflags}
@ -45,6 +43,9 @@ rm -rf %{buildroot}
%{python_sitearch}/%{name}-%{version}-*.egg-info
%changelog
* Tue Jun 24 2014 David Cantrell <dcantrell@redhat.com> - 3.9.4-1
- Support gpt and msdos disk labels on aarch64 (#1095904)
* Thu Jun 12 2014 David Cantrell <dcantrell@redhat.com> - 3.9.3-3
- Fix GetLabelsTestCase for aarch64 (#1102854)

View File

@ -1 +1 @@
c0b7f54c95f942e5a345b921fea12685 pyparted-3.9.3.tar.gz
f03e51fd1d3fa8cfbf76583ab0eaa4fe pyparted-3.9.4.tar.gz