summaryrefslogtreecommitdiff
path: root/docs/typ/building.typ
diff options
context:
space:
mode:
Diffstat (limited to 'docs/typ/building.typ')
-rw-r--r--docs/typ/building.typ12
1 files changed, 10 insertions, 2 deletions
diff --git a/docs/typ/building.typ b/docs/typ/building.typ
index 8520fbbf..151d4b3f 100644
--- a/docs/typ/building.typ
+++ b/docs/typ/building.typ
@@ -14,8 +14,15 @@ fetched and pinned by the manifest; the terminal build needs no system
package. The SDL shell builds SDL3 and FreeType from source. Pictures and
PDFs are addons, each its own step: `zig build image`, `zig build pdf`
(`pdf.so`, over MuPDF, its own FreeType and zlib in it), or `zig build
-addons` for both; the binaries hold neither, and MuPDF is compiled only
-for the `pdf` step and the tests.
+addons` for both; the binaries hold neither. MuPDF, and the FreeType and
+zlib the terminal build takes only for it, are lazy: a build fetches them
+only with `-Dpdf`, which is on by itself once MuPDF is fetched, so a fresh
+checkout's `zig build -Dplatform=tui` downloads none of them, and its
+first `zig build pdf -Dpdf` (or `addons`, `static`, `mupdf-check`, a PDF
+bench) fetches MuPDF once; without it those steps say to add `-Dpdf`, and
+the tests leave their PDF cases out. (Zig 0.17's configure is handed the
+options and never the steps asked for, so a step cannot fetch for itself.)
+MuPDF is compiled only for the steps and tests that use `pdf.so`.
#pairs(
[`zig build`], [the terminal shell and the SDL window together, *installed into `~/.local/bin`* (`pardes` and `pardes-gui`)],
@@ -41,6 +48,7 @@ must share with its session; `pardes --help` lists every flag.
#pairs(
[`-Dplatform`], [`tui`, `gui`, `macos`; absent: the tui and SDL shells together, installed into `~/.local`],
+ [`-Dpdf`], [bool: build the pdf addon, fetching MuPDF the first time; default on once MuPDF is fetched, and off Linux],
[`-Djpx`], [bool, `true`: JPEG 2000, and with it scanned PDFs],
[`-Dtree-sitter`], [`disabled`, `zig`, `minimal`, `full`; `full`],
[`-Dembed-sources`], [bool, `false`: serve the sources under #file("/src")],