Repository navigation
template: dist/ is the whole output; #/ is the one import root; pkg/<name>-<version>-<arch>.tar.gz - #41
Merged
Conversation
julian-goldstein
force-pushed
the
bpf-object-in-dist
branch
from
October 29, 2026 02:43
5bc566c to
7031ae9
Compare
…name>-<version>-<arch>.tar.gz The linked BPF object now lands at dist/bin/probe.bpf.o beside the bundle, and bin/ at the project root is gone. A copied dist/ (index.js + bin/) runs on its own, and a final `tarball` step packs it into pkg/<name>-<version>-<arch>.tar.gz (name and version from package.json, arch from the toolchain), listed with the artifacts; pkg/ is gitignored and removed by `make clean`, and holds one package per version and arch. `#/` replaces `@/` as the one import root and means src/: tsconfig maps it there for esbuild, package.json `imports` maps it there for the runtime, so every module also runs standalone with `yeet run` (the old `@/` was bundle-time only). The one exception is the `#/bin/` prefix, the built-object dir, mapped to dist/bin/ in the tree. Nothing needs the bundle to run: `make bpf` then `yeet run .` runs the sources directly. The object is imported, not located: `import probe from "#/bin/probe.bpf.o"` evaluates to a ready BpfObject (the loader's BpfObjectRule). In the bundle it stays external and one esbuild alias rewrites the `#/bin` prefix to ./bin, so it points beside the bundle and any further object is just another import. This replaces the old `exe: "../bin/probe.bpf.o", base: import.meta.dirname` path, which only resolved from the bundle's location. Also: the kernel matrix stages veristat in .kmatrix/ instead of bin/, locally and in CI; `clean` prints one row per path; the step macro treats an empty exit status as failure; README and AGENTS.md follow.
julian-goldstein
force-pushed
the
bpf-object-in-dist
branch
from
October 29, 2026 02:49
7031ae9 to
583e920
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
dist/is the whole output. The linked BPF object now lands atdist/bin/probe.bpf.obeside the bundle;bin/at the project root is gone. A copieddist/(index.js+bin/) runs on its own, and a finaltarballstep packs it intopkg/<name>-<version>-<arch>.tar.gz(name and version from package.json, arch from the toolchain).pkg/is gitignored, removed bymake clean, and holds one package per version and arch built.#/is the one import root, replacing@/. It meanssrc/: tsconfig maps it there for esbuild, package.jsonimportsmaps it there for the runtime, so every module also runs standalone withyeet run src/probes/x.js(the old@/was bundle-time only, and the docs carried a caveat for it). The one exception is the#/bin/prefix, the built-object dir, which package.json maps todist/bin/. Nothing needs the bundle to run:make bpfthenyeet run .runs the sources directly.The object is imported, not located.
import probe from "#/bin/probe.bpf.o"evaluates to a readyBpfObject(the daemon'sBpfObjectRulewraps the file innew BpfObject({ exe })). In the bundle the import stays external and one esbuild alias rewrites the#/binprefix to./bin, so it points beside the bundle; any further object is just another#/bin/<name>.bpf.oimport. This replaces the oldexe: "../bin/probe.bpf.o", base: import.meta.dirnamepath, which only resolved from the bundle's location.Kernel matrix stages veristat in
.kmatrix/(its own workspace) instead ofbin/, locally and in CI, and the object path follows. README and AGENTS.md examples and alias notes updated throughout;cleanprints one row per path; the step macro treats an empty exit status as failure (it previously let a broken command through).Test plan
./bin/probe.bpf.oand no#/reference, sources inlined.yeet run .in the tree; a copy ofdist/alone; the package unpacked into an empty dir — all start the TUI.make bpfalone, thenyeet run .andyeet run src/main.jsxunbundled.yeet run src/probes/probe.jsandsrc/probes/runqlat.jsstandalone (#/bin/*beats#/*at runtime,#/probes/…resolves).make cleanleaves nodist/,.build/orpkg/; cleangit statusafter build + clean;make -j4from clean.#/libsource import.make veristat-matrix/ CI kernel-matrix (boot VMs; not run).