Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 3 additions & 55 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -944,23 +944,6 @@ jobs:
-DACECODE_BUILD_DESKTOP=ON
-DACECODE_DEEPIN=ON
-DWEBVIEW_WEBKITGTK_API=4.0
- id: linux-deepin-armv7
os: ubuntu-22.04
triplet: arm-linux
executable: acecode
archive_extension: tar.gz
build_desktop: false
cmake_extra_args: >-
-DACECODE_BUILD_DESKTOP=OFF
-DACECODE_DEEPIN=ON
-DVCPKG_CHAINLOAD_TOOLCHAIN_FILE="$VCPKG_ROOT/scripts/toolchains/linux.cmake"
-DVCPKG_TARGET_ARCHITECTURE=arm
-DCMAKE_C_COMPILER=clang-11
-DCMAKE_CXX_COMPILER=clang++-11
-DCMAKE_C_COMPILER_TARGET=arm-linux-gnueabihf
-DCMAKE_CXX_COMPILER_TARGET=arm-linux-gnueabihf
-DCMAKE_C_STANDARD_INCLUDE_DIRECTORIES=/usr/arm-linux-gnueabihf/include
-DCMAKE_CXX_STANDARD_INCLUDE_DIRECTORIES="/usr/arm-linux-gnueabihf/include/c++/8;/usr/arm-linux-gnueabihf/include/c++/8/arm-linux-gnueabihf;/usr/arm-linux-gnueabihf/include"

steps:
- name: Checkout
Expand Down Expand Up @@ -1003,15 +986,6 @@ jobs:
libegl1-mesa-dev libudev-dev libxi-dev libcups2-dev librsvg2-dev
)
fi
if [ "${{ matrix.id }}" = "linux-deepin-armv7" ]; then
packages+=(
binutils-arm-linux-gnueabihf
clang-11
gcc-arm-linux-gnueabihf
g++-arm-linux-gnueabihf
qemu-user
)
fi
apt-get install -y --no-install-recommends "${packages[@]}"
rm -rf /var/lib/apt/lists/*

Expand Down Expand Up @@ -1106,40 +1080,14 @@ jobs:
fi
fi

- name: Verify Deepin ARMv7 executable
if: matrix.id == 'linux-deepin-armv7'
shell: bash
run: |
export LC_ALL=C
elf_header="$(arm-linux-gnueabihf-readelf -h build/acecode)"
arm_attributes="$(arm-linux-gnueabihf-readelf -A build/acecode)"
program_headers="$(arm-linux-gnueabihf-readelf -l build/acecode)"

printf '%s\n' "$elf_header"
printf '%s\n' "$arm_attributes"

grep -Eq 'Class:[[:space:]]+ELF32' <<<"$elf_header"
grep -Eq 'Machine:[[:space:]]+ARM' <<<"$elf_header"
grep -Eq 'Tag_CPU_arch:[[:space:]]+v7' <<<"$arm_attributes"
grep -Eq 'Tag_ABI_VFP_args:[[:space:]]+VFP registers' <<<"$arm_attributes"
grep -Fq '/lib/ld-linux-armhf.so.3' <<<"$program_headers"

version_output="$(qemu-arm -L /usr/arm-linux-gnueabihf build/acecode --version)"
printf '%s\n' "$version_output"
grep -Eq '^acecode v[^[:space:]]+$' <<<"$version_output"

- name: Extract debug symbols
shell: bash
run: |
binutils_prefix=""
if [ "${{ matrix.id }}" = "linux-deepin-armv7" ]; then
binutils_prefix="arm-linux-gnueabihf-"
fi
"${binutils_prefix}objcopy" --only-keep-debug \
objcopy --only-keep-debug \
"build/${{ matrix.executable }}" \
"build/${{ matrix.executable }}.debug"
"${binutils_prefix}strip" --strip-unneeded "build/${{ matrix.executable }}"
"${binutils_prefix}objcopy" \
strip --strip-unneeded "build/${{ matrix.executable }}"
objcopy \
--add-gnu-debuglink="build/${{ matrix.executable }}.debug" \
"build/${{ matrix.executable }}"

Expand Down
4 changes: 2 additions & 2 deletions docs/deepin-desktop.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Deepin 包使用系统 WebKit2GTK **4.0**、Qt **5.11 或更新的 Qt 5**、DTK
## 运行条件

- x64、ARM64:归档包含 `acecode` 和 `acecode-desktop`。
- ARMv7:延续原流水线的终端/daemon 包,不包含 Desktop。
- ARMv7:1.0.7 是最后一个 Deepin ARMv7 包(终端/daemon,不含 Desktop)。已下载的版本仍可使用,但不会再有新版本。普通 `acecode-linux-armv7.tar.gz` 按较新的 glibc 构建,不保证能在 GLIBC 2.28 的旧 UOS / Deepin 上运行。
- 桌面依赖系统 `libwebkit2gtk-4.0.so.37`、`libdtkwidget.so.5`、`libdtkgui.so.5`、Qt 5 及 Deepin `dxcb` 平台插件。使用系统随附的对应运行库,归档不捆绑 Qt、DTK 或 WebKit。
- 原生窗框效果还要求 `XDG_CURRENT_DESKTOP` 或 `XDG_SESSION_DESKTOP` 含有 `Deepin` 桌面名称,并且窗口实际使用 GDK X11 后端。XWayland 满足这一后端条件,CPU 架构不参与判断。原生 Wayland 跳过 X11 窗框适配。
- Deepin 的 DPI 修正也受编译开关和上述运行条件限制;有效字体 DPI 大于 96 且缩放参数有效时启用,显示设置改变后实时刷新。
Expand All @@ -26,7 +26,7 @@ Deepin 包使用系统 WebKit2GTK **4.0**、Qt **5.11 或更新的 Qt 5**、DTK

## 打包与升级

下载文件为 `acecode-linux-deepin-x64.tar.gz`、`acecode-linux-deepin-arm64.tar.gz` 和 `acecode-linux-deepin-armv7.tar.gz`,替代原 `linux-old-*` 系列。普通 `acecode-linux-*` 包继续单独发布。
下载文件为 `acecode-linux-deepin-x64.tar.gz` 和 `acecode-linux-deepin-arm64.tar.gz`,替代原 `linux-old-*` 系列。普通 `acecode-linux-*` 包继续单独发布。

专用流水线保持 Debian Buster / GLIBC 2.28 基线。`scripts/build_deepin_dtk_sdk.sh` 从固定提交及 SHA-256 校验的源码构建 DTK 5.2 SDK,避免系统仓库更新 Qt 后抬高 ABI 要求。SDK 只用于 CI 链接,不放进发行包。流水线校验 GLIBC 上限、WebKitGTK 4.0、DTK 5 和动态依赖是否齐全。打包前及解包后运行 `scripts/verify_deepin_package.py`,拒绝归档中的 Qt/DTK 运行库和 Qt 插件。

Expand Down
2 changes: 1 addition & 1 deletion docs/help-source/getting-started.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
{
"id": "linux",
"title": "Linux",
"html": "<p>Linux 可以使用 npm 安装,也可以下载 <code>acecode-linux-x64.tar.gz</code> 或 <code>acecode-linux-arm64.tar.gz</code>。下面以 x64 压缩包为例,在下载目录执行:</p>\n <div class=\"code-block\"><div class=\"code-heading\"><span>Shell · 从压缩包启动</span><button class=\"copy-button js-only\" type=\"button\" aria-label=\"复制代码\"><svg class=\"icon \" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" aria-hidden=\"true\"><path d=\"M8 8h12v13H8zM16 8V3H3v13h5\"/></svg><span>复制</span></button></div><pre><code>tar -xzf acecode-linux-x64.tar.gz\ncd acecode-linux-x64\n./acecode configure\n./acecode</code></pre></div>\n <p>ARM64 用户替换文件名和目录名中的 <code>x64</code> 为 <code>arm64</code>。直接解压运行时使用 <code>./acecode</code>;将程序目录加入 PATH 后,才可在其他目录使用 <code>acecode</code>。</p>\n <h3 id=\"linux-desktop\">使用 Linux 桌面端</h3><p>桌面端需要 WebKitGTK 4.1。采用 apt 的发行版可安装对应运行库,然后在程序目录中启动:</p>\n <div class=\"code-block\"><div class=\"code-heading\"><span>Shell · 桌面运行库与启动</span><button class=\"copy-button js-only\" type=\"button\" aria-label=\"复制代码\"><svg class=\"icon \" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" aria-hidden=\"true\"><path d=\"M8 8h12v13H8zM16 8V3H3v13h5\"/></svg><span>复制</span></button></div><pre><code>sudo apt install libwebkit2gtk-4.1-0\n./acecode-desktop</code></pre></div>\n <p>其他发行版请使用对应的软件包管理器安装 WebKitGTK 4.1。UOS / Deepin 用户请下载 <code>acecode-linux-deepin-*</code> 专用包;桌面端使用系统 WebKitGTK 4.0 和 DTK 5,终端 ARMv7 包不包含桌面端。</p>\n <h3 id=\"web\">通过浏览器使用</h3><p>安装终端版后,也可以启动后台服务。npm 安装时执行:</p>\n <div class=\"code-block\"><div class=\"code-heading\"><span>终端 · 启动 Web 服务</span><button class=\"copy-button js-only\" type=\"button\" aria-label=\"复制代码\"><svg class=\"icon \" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" aria-hidden=\"true\"><path d=\"M8 8h12v13H8zM16 8V3H3v13h5\"/></svg><span>复制</span></button></div><pre><code>acecode daemon</code></pre></div>\n <p>未覆盖端口配置时,在本机浏览器打开 <a href=\"http://127.0.0.1:12399\" target=\"_blank\" rel=\"noopener noreferrer\">http://127.0.0.1:12399</a>。便携版请在程序目录执行 <code>./acecode daemon</code>。配置了端口或认证时,按服务启动信息访问。</p>\n <aside class=\"note\"><strong>本机 Web 与远程访问</strong><p>这里的地址用于本机访问。远程访问需要额外配置访问方式与认证;首次使用建议先在本机完成模型配置和任务验证。</p></aside>\n <p>请优先打开启动输出中的 <code>Web UI:</code> 地址;已保存的端口配置可能与默认值不同。完整操作见<a href=\"web.html\">Web</a>。</p>"
"html": "<p>Linux 可以使用 npm 安装,也可以下载 <code>acecode-linux-x64.tar.gz</code> 或 <code>acecode-linux-arm64.tar.gz</code>。下面以 x64 压缩包为例,在下载目录执行:</p>\n <div class=\"code-block\"><div class=\"code-heading\"><span>Shell · 从压缩包启动</span><button class=\"copy-button js-only\" type=\"button\" aria-label=\"复制代码\"><svg class=\"icon \" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" aria-hidden=\"true\"><path d=\"M8 8h12v13H8zM16 8V3H3v13h5\"/></svg><span>复制</span></button></div><pre><code>tar -xzf acecode-linux-x64.tar.gz\ncd acecode-linux-x64\n./acecode configure\n./acecode</code></pre></div>\n <p>ARM64 用户替换文件名和目录名中的 <code>x64</code> 为 <code>arm64</code>。直接解压运行时使用 <code>./acecode</code>;将程序目录加入 PATH 后,才可在其他目录使用 <code>acecode</code>。</p>\n <h3 id=\"linux-desktop\">使用 Linux 桌面端</h3><p>桌面端需要 WebKitGTK 4.1。采用 apt 的发行版可安装对应运行库,然后在程序目录中启动:</p>\n <div class=\"code-block\"><div class=\"code-heading\"><span>Shell · 桌面运行库与启动</span><button class=\"copy-button js-only\" type=\"button\" aria-label=\"复制代码\"><svg class=\"icon \" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" aria-hidden=\"true\"><path d=\"M8 8h12v13H8zM16 8V3H3v13h5\"/></svg><span>复制</span></button></div><pre><code>sudo apt install libwebkit2gtk-4.1-0\n./acecode-desktop</code></pre></div>\n <p>其他发行版请使用对应的软件包管理器安装 WebKitGTK 4.1。UOS / Deepin 用户请下载 <code>acecode-linux-deepin-*</code> 专用包(x64、arm64);桌面端使用系统 WebKitGTK 4.0 和 DTK 5。1.0.7 是最后一个 Deepin ARMv7 版本。</p>\n <h3 id=\"web\">通过浏览器使用</h3><p>安装终端版后,也可以启动后台服务。npm 安装时执行:</p>\n <div class=\"code-block\"><div class=\"code-heading\"><span>终端 · 启动 Web 服务</span><button class=\"copy-button js-only\" type=\"button\" aria-label=\"复制代码\"><svg class=\"icon \" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"1.6\" aria-hidden=\"true\"><path d=\"M8 8h12v13H8zM16 8V3H3v13h5\"/></svg><span>复制</span></button></div><pre><code>acecode daemon</code></pre></div>\n <p>未覆盖端口配置时,在本机浏览器打开 <a href=\"http://127.0.0.1:12399\" target=\"_blank\" rel=\"noopener noreferrer\">http://127.0.0.1:12399</a>。便携版请在程序目录执行 <code>./acecode daemon</code>。配置了端口或认证时,按服务启动信息访问。</p>\n <aside class=\"note\"><strong>本机 Web 与远程访问</strong><p>这里的地址用于本机访问。远程访问需要额外配置访问方式与认证;首次使用建议先在本机完成模型配置和任务验证。</p></aside>\n <p>请优先打开启动输出中的 <code>Web UI:</code> 地址;已保存的端口配置可能与默认值不同。完整操作见<a href=\"web.html\">Web</a>。</p>"
}
],
"sources": [
Expand Down
Loading
Loading