Hi Alejandro, > To me man(1) is still a black box (I have looked at its source code > occasionally, but not very often), and there's no way to know what > it's doing, since it provides no equivalent to groff(1)'s -V.
Colin Watson's man(1) uses his libpipeline(3). $ PIPELINE_DEBUG=1 man ls 2>&1 >/dev/null | grep '^Starting pipeline:' Starting pipeline: zcat [input: {0, /usr/share/man/man1/ls.1p.gz}, output: {-1, NULL}] Starting pipeline: zcat [input: {0, /usr/share/man/man1/ls.1.gz}, output: {-1, NULL}] Starting pipeline: zcat [input: {0, /usr/share/man/man1/ls.1.gz}, output: {-1, NULL}] Starting pipeline: (echo .nh && echo .de hy && echo .. && echo .na && echo .de ad && echo .. && zcat) [input: {0, /usr/share/man/man1/ls.1.gz}, output: {-1, NULL}] Starting pipeline: (cd /usr/share/man && /usr/lib/man-db/zsoelim) | (cd /usr/share/man && /usr/lib/man-db/manconv -f UTF-8:ISO-8859-1 -t UTF-8//IGNORE) | (cd /usr/share/man && preconv -e UTF-8) | (cd /usr/share/man && tbl) | (cd /usr/share/man && nroff -mandoc -rLL=265n -rLT=265n -Tutf8) [input: {-1, NULL}, output: {-1, NULL}] Starting pipeline: col -b -p -x | sed -e '/^[[:space:]]*$/{ N; /^[[:space:]]*\n[[:space:]]*$/D; }' [input: {-1, NULL}, output: {0, NULL}] Starting pipeline: zcat [input: {3, NULL}, output: {-1, NULL}] Starting pipeline: Waiting for pipeline: zcat [input: {3, NULL}, output: {-1, NULL}] $ > > $ groff -Tascii -kpt -V > > preconv | pic | tbl | troff -Tascii | grotty > > $ > > Does man(1) run pic(1)? It can do. It sometimes reads the man page to find out the preprocessors to use. Read around ‘MANROFFSEQ’ in man(1). > BTW, you may notice I added some trick to make eqn(1) fail: > > <https://git.kernel.org/pub/scm/docs/man-pages/man-pages.git/commit/?id=e728d5d1e639e5c803a84480ad727e7b02bac222> I'd grep for ^ as otherwise the code doesn't match the commit message. :-) -- Cheers, Ralph.