From 75a7b5ec3fc201e02cd145df630d21bf340d6c72 Mon Sep 17 00:00:00 2001 From: tison Date: Thu, 13 Apr 2023 09:47:52 +0000 Subject: [PATCH] build: support build on garudalinux --- deps/init/dep_create.sh | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/deps/init/dep_create.sh b/deps/init/dep_create.sh index 4436e6baf..5483c0a21 100644 --- a/deps/init/dep_create.sh +++ b/deps/init/dep_create.sh @@ -80,7 +80,7 @@ function get_os_release() { uos) version_ge "20" && compat_centos7 && return ;; - arch) + arch | garuda) compat_centos8 && return ;; rocky) @@ -108,7 +108,7 @@ function get_os_release() { ;; esac fi - not_supported && return 1 + not_supported && return 1 } get_os_release || exit 1 @@ -136,7 +136,7 @@ if [ -f ${WORKSAPCE_DEPS_3RD_MD5} ]; then fi else echo_log "${DEP_FILE} has been not initialized, due to ${WORKSAPCE_DEPS_3RD_MD5} not exists" -fi +fi # 依赖目录不存在,停止缓存 if [ "x${DEP_CACHE_DIR}" == "x" ]; then @@ -200,7 +200,7 @@ section="default" content="" function save_content { - if [[ "$content" != "" ]] + if [[ "$content" != "" ]] then if [[ $(echo "$section" | grep -E "^target\-") != "" ]] then @@ -225,7 +225,7 @@ do else [[ "$line" != "" ]] && [[ "$line" != '#'* ]] && content+=$'\n'"$line" fi -done < $DEP_FILE +done < $DEP_FILE save_content # 真正开始下载 @@ -259,7 +259,7 @@ do fi fi echo_log "unpack package <${pkg}>... \c" - if [ "$ID" = "arch" ]; then + if [[ "$ID" = "arch" || "$ID" = "garuda" ]]; then (cd ${TARGET_DIR_3RD} && rpmextract.sh "${TARGET_DIR_3RD}/pkg/${pkg}") else (cd ${TARGET_DIR_3RD} && rpm2cpio "${TARGET_DIR_3RD}/pkg/${pkg}" | cpio -di -u --quiet) @@ -313,7 +313,7 @@ if [ -f ${CACHE_DEPS_LOCKFILE} ];then fi else echo_log "lock file ${CACHE_DEPS_LOCKFILE} in 1 mins" - fi + fi fi if [ ${LINK_CHACE_DIRECT} == "ON" ]; then