diff options
Diffstat (limited to 'docs/shared-libs.md')
| -rw-r--r-- | docs/shared-libs.md | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/docs/shared-libs.md b/docs/shared-libs.md index 4a07f80a..b9f64fdf 100644 --- a/docs/shared-libs.md +++ b/docs/shared-libs.md @@ -34,16 +34,17 @@ tests); `-Dmupdf` is gone. `zig build static -Dplatform=tui -Dtarget=x86_64-linux-musl` links the terminal binary statically (musl: glibc links only dynamically) with both addons compiled in: image.zig as a module, its stb_image static in stb.c -beside the binary's zstbi resize, and pdf.c with MuPDF, its FreeType and -zlib, its export renamed (`-Dpardes_addon=pardes_addon_pdf`), so the -binary holds one copy of each. Addon.zig registers both at start as if +beside the binary's zstbi resize, and pdf.zig with MuPDF, its FreeType and +zlib (the module exports `pardes_addon` only from its library, so the static +binary reads its declaration), so the binary holds one copy of each. Addon.zig registers both at start as if loaded. It loads no library (a static binary has no dlopen); it is also the way a build for macOS, whose loader has no memfd, could have image and PDF panes. ## PDF panes became an addon (2026-11-06) -`lib/pardes/addons/pdf.so` (addons/pdf/pdf.c and pdf_bridge.c) holds MuPDF, +`lib/pardes/addons/pdf.so` (addons/pdf/pdf.zig, in Zig, over MuPDF through +the C of pdf_bridge.c, since 2026-11-07) holds MuPDF, built against the build's FreeType and zlib and linked into the library with them, all three compiled position-independent; it exports `pardes_addon` alone (a version script), so its FreeType and zlib never |
