summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile15
1 files changed, 14 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index f1930f9..0176f32 100644
--- a/Makefile
+++ b/Makefile
@@ -53,6 +53,18 @@ check-schema: build ## validate emitted XML against schema/colitur-v1.xsd (needs
# deps), so absence is printed LOUDLY as SKIPPED rather than silently
# treated as a pass -- a silent skip reads as a pass, which is the whole
# failure mode this guards against.
+#
+# ordo.ms's own -P-pa5 (added alongside grid.ms's existing -P-pa4l, the
+# same mechanism, not a new one) and -Kutf8 (both flavours) fix two
+# defects this target's own "did it TYPESET" check could never see on its
+# own: groff's default PDF device paper is not A5 (so the booklet was
+# roughly twice the intended page area -- half a real density problem
+# was hiding in the page, not the type) and groff's default input
+# encoding is not UTF-8 (so an accented Latin name like Pe\(~nafort
+# rendered as visibly wrong characters) -- neither one is a groff
+# WARNING, so this target's own "any stderr is a failure" check was
+# silently green through both. Rendering to an actual PDF and reading it
+# is what caught them; a byte-identical-to-golden pass would not have.
check-templates: build ## typeset every shipped template (needs pdflatex/groff/typst; skipped per-tool if absent)
@ok=1; \
if command -v pdflatex >/dev/null 2>&1; then \
@@ -68,9 +80,10 @@ check-templates: build ## typeset every shipped template (needs pdflatex/groff/t
for t in ordo grid; do \
gflags=""; \
[ "$$t" = grid ] && gflags="-P-pa4l"; \
+ [ "$$t" = ordo ] && gflags="-P-pa5"; \
if opam exec -- dune exec colitur -- table --year 2027 --template templates/ef/$$t.ms \
> /tmp/$$t.ms 2>/tmp/$$t-render.err; then \
- groff -ms -t -Tpdf $$gflags /tmp/$$t.ms > /tmp/$$t-ms.pdf 2>/tmp/$$t-ms.warnings; \
+ groff -ms -t -Tpdf -Kutf8 $$gflags /tmp/$$t.ms > /tmp/$$t-ms.pdf 2>/tmp/$$t-ms.warnings; \
if [ -s /tmp/$$t-ms.warnings ]; then \
echo "groff: $$t.ms FAILED (groff exits 0 on a tbl/troff warning -- this target"; \
echo " treats ANY stderr output as a failure, since a warning here has meant"; \