2021-09-27 12:08:32 +02:00
|
|
|
From 2883215dfb434d4056812ed96d968f7043501d70 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
|
2021-09-27 12:08:32 +02:00
|
|
|
index ba600e106b..3e990cc05d 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):
|
|
|
|
--
|
2021-09-27 12:08:32 +02:00
|
|
|
2.33.0
|
2019-01-17 10:18:02 +01:00
|
|
|
|
|
|
|
|