40 lines
1.5 KiB
Diff
40 lines
1.5 KiB
Diff
From 3cb595825d136cdce47dd264360780bb405acfba Mon Sep 17 00:00:00 2001
|
|
From: yangchenguang <yangchenguang@kylinsec.com.cn>
|
|
Date: Fri, 7 Apr 2023 15:12:31 +0800
|
|
Subject: [PATCH] fix(*):fix supermin cannot detect kylinsecos
|
|
MIME-Version: 1.0
|
|
Content-Type: text/plain; charset=UTF-8
|
|
Content-Transfer-Encoding: 8bit
|
|
|
|
- 添加supermin对kylinsec的支持
|
|
|
|
Signed-off-by: yangchenguang <yangchenguang@kylinsec.com.cn>
|
|
---
|
|
src/ph_rpm.ml | 5 +++--
|
|
1 file changed, 3 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/src/ph_rpm.ml b/src/ph_rpm.ml
|
|
index 8260396..a6e1eb4 100644
|
|
--- a/src/ph_rpm.ml
|
|
+++ b/src/ph_rpm.ml
|
|
@@ -31,13 +31,14 @@ let stringset_of_list pkgs =
|
|
let fedora_detect () =
|
|
Config.rpm <> "no" && Config.rpm2cpio <> "no" && rpm_is_available () &&
|
|
(Config.yumdownloader <> "no" || Config.dnf <> "no") &&
|
|
- (List.mem (Os_release.get_id ()) [ "fedora"; "rhel"; "centos"; "openEuler"; "hce"; "euleros" ] ||
|
|
+ (List.mem (Os_release.get_id ()) [ "fedora"; "rhel"; "centos"; "openEuler"; "hce"; "euleros"; "KylinSecOS" ] ||
|
|
try
|
|
(stat "/etc/redhat-release").st_kind = S_REG ||
|
|
(stat "/etc/fedora-release").st_kind = S_REG ||
|
|
(stat "/etc/openEuler-release").st_kind = S_REG ||
|
|
(stat "/etc/euleros-release").st_kind = S_REG ||
|
|
- (stat "/etc/hce-release").st_kind = S_REG
|
|
+ (stat "/etc/hce-release").st_kind = S_REG ||
|
|
+ (stat "/etc/kylinsec-release").st_kind = S_REG
|
|
with Unix_error _ -> false)
|
|
|
|
let opensuse_detect () =
|
|
--
|
|
2.33.0
|
|
|