mirror of
https://gitcode.com/JianFeeeee/HomeAgent.git
synced 2026-09-21 17:38:10 +00:00
agentcli: Windows ConPTY 适配分支(原生实现替代剔除桩)+ cabi loader.c build tag 修复
- agentcli 平台无关化:plugin.go 拆为公共层 + ptyTerm 接口,新增 pty_linux.go(/dev/ptmx 原实现搬移,行为不变)与 pty_windows.go (ConPTY 原生实现,CreatePseudoConsole + PROC_THREAD_ATTRIBUTE_PSEUDOCONSOLE 注入子进程,双管道读写/ResizePseudoConsole/GetExitCodeProcess,零第三方依赖) - plugin_stub.go 收紧为 !linux && !windows(darwin 等仍走桩) - plugin_test.go build tag 放宽到 linux || windows - cabi/loader.c 补 linux || darwin build tag,修复 Windows 下 cgo 禁用时残留 C 源文件的编译错误 - 验证:Linux 全量构建+测试通过;Windows CGO 交叉编译 + go vet 全包零错误
This commit is contained in:
@ -1,3 +1,5 @@
|
||||
//go:build linux || darwin
|
||||
|
||||
// HomeAgent C ABI loader — C implementation (compiled alongside Go code via cgo)
|
||||
|
||||
#include <dlfcn.h>
|
||||
|
||||
Reference in New Issue
Block a user