!102 [sync] PR-99: add loongarch64 support for blivet
From: @openeuler-sync-bot Reviewed-by: @t_feng Signed-off-by: @t_feng
This commit is contained in:
commit
7595083d3d
34
0001-add-loongarch64-support-for-blivet.patch
Normal file
34
0001-add-loongarch64-support-for-blivet.patch
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
From c946520bc7917ee5b1c01c49ce7c866b7faf8eb0 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Wenlong Zhang <zhangwenlong@loongson.cn>
|
||||||
|
Date: Sat, 11 Feb 2023 06:48:05 +0000
|
||||||
|
Subject: [PATCH] add loongarch64 support for blivet
|
||||||
|
|
||||||
|
---
|
||||||
|
blivet/arch.py | 4 ++++
|
||||||
|
1 file changed, 4 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/blivet/arch.py b/blivet/arch.py
|
||||||
|
index 2cd978e..bc76031 100644
|
||||||
|
--- a/blivet/arch.py
|
||||||
|
+++ b/blivet/arch.py
|
||||||
|
@@ -333,6 +333,8 @@ def is_ipseries():
|
||||||
|
def is_powernv():
|
||||||
|
return is_ppc() and get_ppc_machine() == "PowerNV"
|
||||||
|
|
||||||
|
+def is_loongarch():
|
||||||
|
+ return os.uname()[4] == 'loongarch64'
|
||||||
|
|
||||||
|
def get_arch():
|
||||||
|
"""
|
||||||
|
@@ -349,6 +351,8 @@ def get_arch():
|
||||||
|
elif is_ppc(bits=64):
|
||||||
|
# ppc64 and ppc64le are distinct architectures
|
||||||
|
return os.uname()[4]
|
||||||
|
+ elif is_loongarch():
|
||||||
|
+ return os.uname()[4]
|
||||||
|
elif is_aarch64():
|
||||||
|
return 'aarch64'
|
||||||
|
elif is_alpha():
|
||||||
|
--
|
||||||
|
2.33.0
|
||||||
|
|
||||||
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
Name: python-blivet
|
Name: python-blivet
|
||||||
Version: 3.4.2
|
Version: 3.4.2
|
||||||
Release: 5
|
Release: 6
|
||||||
Epoch: 1
|
Epoch: 1
|
||||||
Summary: A python module for system storage configuration
|
Summary: A python module for system storage configuration
|
||||||
License: LGPLv2+
|
License: LGPLv2+
|
||||||
@ -27,6 +27,9 @@ patch9003: Incomplete-Chineseization-of-disk-mount.patch
|
|||||||
|
|
||||||
patch6001: backport-Exclude-unusable-disks-from-PartitionFactory-1.patch
|
patch6001: backport-Exclude-unusable-disks-from-PartitionFactory-1.patch
|
||||||
patch6002: backport-Exclude-unusable-disks-from-PartitionFactory-2.patch
|
patch6002: backport-Exclude-unusable-disks-from-PartitionFactory-2.patch
|
||||||
|
%if 0%(test `uname -m` == "loongarch64" && echo 1)
|
||||||
|
Patch6003: 0001-add-loongarch64-support-for-blivet.patch
|
||||||
|
%endif
|
||||||
|
|
||||||
%description
|
%description
|
||||||
The python-blivet package is a python module for examining and modifying
|
The python-blivet package is a python module for examining and modifying
|
||||||
@ -127,6 +130,12 @@ make PYTHON=%{__python2} DESTDIR=%{buildroot} install
|
|||||||
%doc README.md
|
%doc README.md
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Sat Feb 11 2023 Wenlong Zhang<zhangwenlong@loongson.cn> - 1:3.4.2-6
|
||||||
|
- Type:bugfix
|
||||||
|
- ID:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:add loongarch64 support for blivet
|
||||||
|
|
||||||
* Tue Dec 27 2022 hanhuihui<hanhuihui5@huawei.com> - 1:3.4.2-5
|
* Tue Dec 27 2022 hanhuihui<hanhuihui5@huawei.com> - 1:3.4.2-5
|
||||||
- Type:bugfix
|
- Type:bugfix
|
||||||
- ID:NA
|
- ID:NA
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user