2023-01-09 13:52:13 +01:00
|
|
|
From 3ce70f43376dbf62edf2ca2aa8c9f28aa733b3d8 Mon Sep 17 00:00:00 2001
|
2019-01-17 10:18:02 +01:00
|
|
|
From: Mihai Dinca <mdinca@suse.de>
|
|
|
|
Date: Thu, 13 Dec 2018 12:17:35 +0100
|
|
|
|
Subject: [PATCH] Return the expected powerpc os arch (bsc#1117995)
|
|
|
|
|
|
|
|
---
|
2021-09-27 12:08:32 +02:00
|
|
|
salt/utils/pkg/rpm.py | 7 ++++---
|
|
|
|
1 file changed, 4 insertions(+), 3 deletions(-)
|
2019-01-17 10:18:02 +01:00
|
|
|
|
|
|
|
diff --git a/salt/utils/pkg/rpm.py b/salt/utils/pkg/rpm.py
|
2023-01-09 13:52:13 +01:00
|
|
|
index e80a01f92f..8203d2f989 100644
|
2019-01-17 10:18:02 +01:00
|
|
|
--- a/salt/utils/pkg/rpm.py
|
|
|
|
+++ b/salt/utils/pkg/rpm.py
|
2021-09-27 12:08:32 +02:00
|
|
|
@@ -59,9 +59,10 @@ def get_osarch():
|
2021-01-08 13:41:50 +01:00
|
|
|
stderr=subprocess.PIPE,
|
|
|
|
).communicate()[0]
|
2019-01-17 10:18:02 +01:00
|
|
|
else:
|
2021-01-08 13:41:50 +01:00
|
|
|
- ret = "".join([x for x in platform.uname()[-2:] if x][-1:])
|
2019-01-17 10:18:02 +01:00
|
|
|
-
|
2021-01-08 13:41:50 +01:00
|
|
|
- return salt.utils.stringutils.to_str(ret).strip() or "unknown"
|
|
|
|
+ ret = "".join(list(filter(None, platform.uname()[-2:]))[-1:])
|
|
|
|
+ ret = salt.utils.stringutils.to_str(ret).strip() or "unknown"
|
|
|
|
+ ARCH_FIXES_MAPPING = {"powerpc64le": "ppc64le"}
|
2019-01-17 10:18:02 +01:00
|
|
|
+ return ARCH_FIXES_MAPPING.get(ret, ret)
|
|
|
|
|
|
|
|
|
|
|
|
def check_32(arch, osarch=None):
|
|
|
|
--
|
2023-01-09 13:52:13 +01:00
|
|
|
2.37.3
|
2019-01-17 10:18:02 +01:00
|
|
|
|
|
|
|
|