diff --git a/packaging/freebsd/port/README.md b/packaging/freebsd/port/README.md new file mode 100644 index 0000000..999b218 --- /dev/null +++ b/packaging/freebsd/port/README.md @@ -0,0 +1,61 @@ +# FreeBSD port: `sysutils/colibri` + +Source-of-truth for the Clawdie Colibri FreeBSD port, built by the first-party +poudriere server (`pkg.clawdie.si`). Kept here, with the code it builds, so the +port tracks the source. See clawdie-iso `docs/POUDRIERE-BUILD-SERVER.md`. + +## What's here (hand-authored) + +``` +sysutils/colibri/ +├── Makefile port recipe (cargo; ships 6 runtime/operator binaries) +├── pkg-descr package description +└── pkg-plist installed file list +``` + +## What's generated on the build host (NOT committed) + +Two files are derived and must be generated in the ports tree before building — +they are not hand-edited and not stored here: + +- **`distinfo`** — checksums of the source tarball + every crate distfile. + Generate with `make makesum`. +- **`CARGO_CRATES`** — the full crate list from `Cargo.lock` (hundreds of lines). + Generate with `make cargo-crates` and paste the block into the `Makefile` + (replacing the empty placeholder). Without it, the clean-jail build cannot + fetch crates offline. + +## Build it + +1. **Tag a release.** The Makefile fetches + `archive/v${DISTVERSION}.tar.gz` from Forgejo, so a matching tag + (e.g. `v0.0.1`) must exist on `clawdie/colibri`. + +2. **Drop the port into the poudriere ports tree** (default tree name `clawdie`, + per `poudriere-setup.sh`): + + ```sh + cp -R sysutils/colibri \ + /usr/local/poudriere/ports/clawdie/sysutils/colibri + cd /usr/local/poudriere/ports/clawdie/sysutils/colibri + make makesum # -> distinfo + make cargo-crates # -> paste the CARGO_CRATES block into the Makefile + make makesum # re-run now that crates are listed + ``` + +3. **Build + sign** via the wrapper: + + ```sh + poudriere-build.sh --jail clawdie-amd64 --ports clawdie sysutils/colibri + ``` + +## Notes + +- **License:** AGPL-3.0-only (matches `Cargo.toml`). +- Builds only the crates whose binaries ship (`colibri-client` yields both + `colibri` and `colibri-test-agent`); `colibri-probe` / + `colibri-runtime-inventory` are dev tools and are not installed. +- `rust-toolchain.toml` pins a rustup channel; the port removes it in + `post-extract` so the clean jail uses the ports `lang/rust` toolchain. +- Not yet test-built against a live ports tree — first real run is on + `mother-build`. diff --git a/packaging/freebsd/port/sysutils/colibri/Makefile b/packaging/freebsd/port/sysutils/colibri/Makefile new file mode 100644 index 0000000..3871b61 --- /dev/null +++ b/packaging/freebsd/port/sysutils/colibri/Makefile @@ -0,0 +1,49 @@ +PORTNAME= colibri +DISTVERSIONPREFIX= v +DISTVERSION= 0.0.1 +CATEGORIES= sysutils + +MAINTAINER= hello@clawdie.si +COMMENT= Clawdie Colibri control plane (agent supervision, tasks, skills) +WWW= https://code.smilepowered.org/clawdie/colibri + +LICENSE= AGPLv3 + +USES= cargo + +# Source tarball from the Clawdie Forgejo. A tagged release is required: the +# archive at archive/v${DISTVERSION}.tar.gz extracts to colibri/. +MASTER_SITES= https://code.smilepowered.org/clawdie/colibri/archive/ +DISTFILES= ${DISTVERSIONFULL}${EXTRACT_SUFX} +WRKSRC= ${WRKDIR}/colibri + +# CARGO_CRATES is generated from Cargo.lock. Regenerate on the build host before +# the first real build (the workspace pulls in hundreds of crates): +# make cargo-crates >> Makefile # then move the generated block here +# Empty in this draft, so `make makesum` only sums the main tarball. +CARGO_CRATES= # regenerate with: make cargo-crates + +# Build only the crates whose binaries we ship. colibri-client provides both +# `colibri` and `colibri-test-agent`. No GUI dependencies are pulled in. +CARGO_BUILD_ARGS= -p clawdie \ + -p colibri-client \ + -p colibri-daemon \ + -p colibri-mcp \ + -p colibri-glasspane-tui + +# The repo pins a rustup channel (rust-toolchain.toml); in a clean poudriere +# jail we use the ports lang/rust toolchain, so drop the pin before building. +post-extract: + @${RM} -f ${WRKSRC}/rust-toolchain.toml + +BINS= clawdie colibri colibri-daemon colibri-mcp colibri-test-agent colibri-tui + +do-install: + @${MKDIR} ${STAGEDIR}${PREFIX}/bin +.for b in ${BINS} + ${INSTALL_PROGRAM} \ + ${CARGO_TARGET_DIR}/${CARGO_BUILD_TARGET}/release/${b} \ + ${STAGEDIR}${PREFIX}/bin/${b} +.endfor + +.include diff --git a/packaging/freebsd/port/sysutils/colibri/pkg-descr b/packaging/freebsd/port/sysutils/colibri/pkg-descr new file mode 100644 index 0000000..0c2df34 --- /dev/null +++ b/packaging/freebsd/port/sysutils/colibri/pkg-descr @@ -0,0 +1,15 @@ +Colibri is the Clawdie control plane: a cross-platform (FreeBSD/Linux) Rust core +that supervises agents, schedules and routes tasks by capability, and exposes a +local board over a Unix socket and an MCP interface. + +This package installs the runtime and operator binaries: + + clawdie deployed-host service binary + colibri board / CLI client + colibri-daemon local board + scheduler daemon + colibri-mcp MCP server interface + colibri-test-agent test / development agent + colibri-tui glasspane terminal UI + +The colibri-probe and colibri-runtime-inventory development tools are part of +the source workspace but are not installed by this package. diff --git a/packaging/freebsd/port/sysutils/colibri/pkg-plist b/packaging/freebsd/port/sysutils/colibri/pkg-plist new file mode 100644 index 0000000..da2fd1b --- /dev/null +++ b/packaging/freebsd/port/sysutils/colibri/pkg-plist @@ -0,0 +1,6 @@ +bin/clawdie +bin/colibri +bin/colibri-daemon +bin/colibri-mcp +bin/colibri-test-agent +bin/colibri-tui