agent-desktop/.github
Lahfir 2a8b8709b2 ci(ffi): ship prebuilt cdylib tarballs for 5 platforms on every release
Every GitHub Release now ships libagent_desktop_ffi.{dylib,so,dll} alongside
the CLI tarballs, so Python / Swift / Go / Ruby / Node / C hosts can download
and dlopen a prebuilt library instead of forking the CLI per call.

- crates/ffi/build.rs: bake install_name=@rpath/libagent_desktop_ffi.dylib
  via rustc-cdylib-link-arg so Swift/SPM consumers resolve through their own
  rpath chain. Verified locally with otool -D on the release-ffi profile.
- .github/workflows/release.yml: new build-ffi matrix job producing
  tarballs for aarch64/x86_64-apple-darwin, x86_64/aarch64-unknown-linux-gnu,
  and x86_64-pc-windows-msvc. Ubuntu 22.04 runner for the Linux glibc floor;
  native ubuntu-22.04-arm runner for aarch64. Each archive contains
  lib/<dylib>, include/agent_desktop.h, LICENSE, and a short README.
- publish-github downloads both binary-* and ffi-* artifacts in one pass,
  concatenates every .sha256 into checksums.txt, and uploads .tar.gz/.zip
  to the release. Asset-count guard bumped 3 → 8.
- actions/attest-build-provenance@v4.1.0 emits keyless Sigstore provenance
  over every release artifact; consumers verify with gh attestation verify.
- LICENSE (Apache-2.0) added at repo root so every FFI tarball can bundle it.
- README: new "Language bindings (FFI)" section with platform→artifact
  table, verify snippet, minimal Python dlopen example, and a link to
  skills/agent-desktop-ffi/.

Verification:
- otool -D target/release-ffi/libagent_desktop_ffi.dylib → @rpath/...
- Simulated workflow staging + tarball + extract + ctypes.CDLL loads from
  extracted lib/ path; 304 KB compressed on darwin-arm64.
- cargo test --lib --workspace: 139 passed (5 suites); clippy clean.
- YAML parses; 6 jobs: release-please, build, build-ffi, publish-github,
  publish-npm, publish-skills.
2026-04-17 03:44:36 -07:00
..
workflows ci(ffi): ship prebuilt cdylib tarballs for 5 platforms on every release 2026-04-17 03:44:36 -07:00