Skip to content

fix(native): align Linux AMD64 production runtime with FFTC - #57

Merged
xiaopingshao merged 2 commits into
mainfrom
fix/linux-fftc-runtime
Nov 16, 2026
Merged

xiaopingshao merged 2 commits into
mainfrom
fix/linux-fftc-runtime

Conversation

@xiaopingshao

Copy link
Copy Markdown
Contributor

Linux AMD64 后端原生目录随仓库交付生产算法、原始 License.dat、FFTC、匹配的 JNI/Host 与必要依赖。加载和打包统一使用平铺的生产运行库,并校验变体及校验和;设备插件清单接受 Linux 平台。

验证:打包测试 72 通过、1 跳过;生产 ELF、依赖闭包及文件校验通过;前端 addon 45/45;JNI 声明 323 项;插件管理测试 99/99。

不包含独立压缩包、.otplugin、运行日志、临时数据或额外说明文档。

@xiaopingshao
xiaopingshao requested a review from a team November 16, 2026 10:36

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AI 代码审查(claude-opus-5-5)

本次改动把 Linux AMD64 切换为平铺的生产运行库加 FFTC,去掉 prd/ 覆盖层和 FFTW 依赖,整体方向合理。桌面端算法输入新增了变体、平台和校验和验证,与 macOS 保持一致。需要关注以下几点:

  1. 后端暂存缺少变体校验。 后端暂存(源码启动及打包)不校验 algorithm-build-info.json,旧布局材料(根目录测试库加 prd/)可能被静默当作正式材料使用。这会导致测试与正式授权材料交叉组合,违反 CONTEXT 中“授权环境”的约束。
  2. 设备插件平台未与宿主比对。 清单校验放开到三个平台,但没有与当前宿主平台比对,用户可以提交在本机无法加载的设备插件。
  3. 生产材料的来源需要确认。
    • 生产算法库来自脏工作树及个人开发分支。
    • 补丁位于其他仓库,可追溯性不足。
    • 提交的 License.dat 含授权码,需确认它就是与 Windows/macOS 相同的默认原生许可证。
  4. 二进制文件无法在 diff 中审查。 OptDevHost 和各 .so 是否随本次一起提交、内容是否与 SHA256SUMS.txt 一致,只能依赖 CI 或复核者在本地运行 tools/verify-linux-native.py 确认。
  5. Linux 已不再支持测试算法变体。 这与 macOS 一致,但 Linux 下的测试授权环境(测试云许可证服务)将无法再用匹配的测试材料运行。请确认这是预期的产品决策,必要时在 PR 描述或相关文档中说明。

跳过 11 个文件(锁文件、生成文件、二进制或无文本 diff)

由 AI 自动生成,仅供参考,不作为合并依据。审查提交:c1125ac。维护者可评论 /review 重新审查。

Comment thread tools/package-posix-native.mjs Resolved
Comment thread tools/verify-linux-native.py Resolved
Comment thread tools/verify-linux-native.py Resolved
Comment thread tools/verify-linux-native.py Resolved

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AI 代码审查(claude-opus-5-5)

总体评价:把 Linux AMD64 改成与 macOS 一致的平铺生产运行库,去掉 prd 覆盖目录,代码路径因此简化,Node 侧测试也同步更新了。主要风险有四点:

  1. 设备插件的平台白名单与宿主平台脱钩,而且额外放开了 macos-arm64。
  2. Linux 删除 test 变体后,测试授权环境的行为没有明确定义。
  3. 交付的生产算法库基于脏工作树构建。
  4. 新增校验脚本的依赖闭包检查可能被构建机上的系统库掩盖。

无法定位到具体行的意见:

  • 本次提交的 .so 和 OptDevHost 二进制在 diff 中不可见,无法审查,只能依赖 SHA256SUMS.txt 和 tools/verify-linux-native.py。建议在 PR 中附上该脚本在干净环境(未安装 fftc/hidapi 系统包)下的完整输出。
  • 本 PR 删除了 Linux 的 test 变体和 prd 目录约定。请检查 apps/native/docs/public-build.md 等构建、打包文档是否仍描述 Linux prd 目录或 OPENTEST_ALGORITHM_VARIANT=test,如有,需中英文同步更新。
  • tools/verify-linux-native.py 没有接入任何自动化测试或 CI,“生产 ELF、依赖闭包通过”目前只能靠提交者本地运行的结果。建议至少为 verify_payload 的校验和、路径安全逻辑补充单元测试,或在 CI 的 Linux 作业中运行。

跳过 11 个文件(锁文件、生成文件、二进制或无文本 diff)

由 AI 自动生成,仅供参考,不作为合并依据。审查提交:bcb4d0c。维护者可评论 /review 重新审查。

Comment thread tools/verify-linux-native.py Resolved
Comment thread tools/package.mjs Resolved
Comment thread tools/verify-linux-native.py Resolved
@xiaopingshao
xiaopingshao merged commit 17f7574 into main Nov 16, 2026
11 of 13 checks passed
@xiaopingshao
xiaopingshao deleted the fix/linux-fftc-runtime branch November 16, 2026 10:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants