# Kylin Patcher Builder **Repository Path**: kylinos-dev/kylin-patcher-builder ## Basic Information - **Project Name**: Kylin Patcher Builder - **Description**: 银河麒麟桌面操作系统补丁集安装包制作工具 - **Primary Language**: Shell - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2023-01-09 - **Last Updated**: 2025-10-26 ## Categories & Tags **Categories**: Uncategorized **Tags**: Kylin, Qt ## README # 麒麟系统补丁安装器 & 补丁包打包工具 麒麟补丁安装器可用来批量安装 kylin-patch-installer[-auto]-<当前日期>.run 中的补丁,并对补丁进行 sha256sum 校验。 ### 功能: - [x] 支持系统版本区分运行 - [x] 支持系统架构区分运行 - [x] 支持 ARM 架构下,普通 ARM 与 华为海思 CPU 区分运行 - [x] 支持图形模式 - [x] 支持命令行模式 (自动化安装,过程中有 sudo 提权提示) - [x] 增加解压缩提示 (GUI:zenity/terminal-emulator) - [x] 修正目录结构有误时,对系统的匹配机制问题 (仍然会安装部分包) - **待测** - [x] 修正系统包状态检测 - [x] 增加动作脚本调用接口 (对应目录放入 actions.d 及 actions 脚本,请参考下边目录结构) - [x] 增加各系统版本适用包方案,比如 v10sp1/all/xx.deb 可用于全部 v10sp1 系统 (自动区分架构) 等 - [ ] ~~增加 Update 版本检测 (对比 ukui-control-center 版本号[临时]) ~~[暂无有效方案] - [x] 增加自定义安装脚本 - [x] 补丁包增加释放选项 (-e | --extract) - [ ] 修复依赖逻辑 ### 依赖环境(GUI): * zenity * pkexec ### 工具文件说明: | 脚本 | 说明 | | ----------------------------------- | --------------------------------------------------------------- | | LICENSE | 许可协议 | | README.md | 说明文件 | | environment.sh | 补丁安装器全局配置 | | builder.sh | 补丁安装器构建工具 | | release.sh | 补丁安装器构建工具发布工具 | | VERSION | 工具版本文件 | | scripts/FUNCTIONS.in | 公共函数文件 | | scripts/installer.sh.in | 主执行文件 | | scripts/self-installer.sh.in | 自解压引导程序 | | examples/actions.d/pre-actions.sh | 补丁安装前调用的脚本 (模板) | | examples/actions.d/post-actions.sh | 补丁安装后调用的脚本 (模板) | | examples/installer.custom.sh.in | 补丁自定义安装脚本(模板) | ### 补丁包文件说明: | 文件 | 说明 | | ----------------------------------- | --------------------------------------------------------------- | | kylin-patches-changelog.html | 更新日志文件,图形安装器启动时显示,可用 Markdown 文档转换而来 | | kylin-patches-version.txt | 补丁版本文件 | ### 补丁制作方法: **补丁安装器支持多层级目录。** * 将补丁文件放至此目录或子目录中 * 更新日志文件,需要 HTML 格式,HTML 换行为 \
。 * 命令参考: ```shell # 系统大版本:v10 | v10sp1 # SP1 系统分支版本:2107 | 2203 | 2303 | 2403 | ... # 华为 CPU 型号:990 | 9006c | m900 # 安装过程中脚本调用: # 脚本目录:actions.d # 安装前执行:pre-actions.sh # 安装后执行:post-actions.sh # 目录结构: # patches -- <补丁目录> # |--all (非华为全版本支持) # | |--actions.d # | | |--pre-actions.sh # | | |--post-actions.sh # | |--xxxx.deb # | # |--huawei- (all 为华为全架构支持) # | |--all (华为全版本支持) # | | |--actions.d # | | | |--pre-actions.sh # | | | |--post-actions.sh # | | |--xxxx.deb # | | # | |--2107 # | |--actions.d # | | |--pre-actions.sh # | | |--post-actions.sh # | |--xxxx.deb # | # |--v10sp1 # | |--all # | | |--actions.d # | | | |--pre-actions.sh # | | | |--post-actions.sh # | | |--xxxx.deb # | | # | |--2107 # | | |--actions.d # | | | |--pre-actions.sh # | | | |--post-actions.sh # | | |--xxxx.deb # | | # | |--2203 # | | |--actions.d # | | | |--pre-actions.sh # | | | |--post-actions.sh # | | |--xxxx.deb # | | # | |--huawei- (与上级 huawei 目录支持一致) # | |--all # | | |--actions.d # | | | |--pre-actions.sh # | | | |--post-actions.sh # | | |--xxxx.deb # | | # | |--2107 # | | |--actions.d # | | | |--pre-actions.sh # | | | |--post-actions.sh # | | |--xxxx.deb # | | # | |--2203 # | |--actions.d # | | |--pre-actions.sh # | | |--post-actions.sh # | |--xxxx.deb # | # |--v10 # | |--actions.d # | | |--pre-actions.sh # | | |--post-actions.sh # | |--xxxx.deb # kylin-patches-version.txt # kylin-patches-changelog.html # builder.sh # 执行命令制作带图形界面的补丁安装包 (仅支持单一系统版本补丁,待更新为支持多系统补丁制作工具): $ ./builder.sh <补丁目录> # 或用以下命令生成多系统补丁一键安装包 (无人干预,支持多系统版本补丁共存) $ ./builder.sh -a <补丁目录> ``` * 将构建工具生成的 kylin-patch-installer-<当前日期>.run 文件提交给用户。 ### 补丁使用方法: * 图形模式补丁可以双击/命令行运行,**非图形模式补丁,只能命令行模式运行 (因有提权请求)** * 双击 kylin-patch-installer-<当前日期>.run 运行。 * ```shell $ [sudo] ./kylin-patch-installer[-auto]-<当前日期>.run ```