DH_OCAMLDOC(1)
π DH_OCAMLDOC(1) π
okay so bestie, welcome to the manual page for dh_ocamldoc β it's a User Contributed Perl Documentation situation, and honestly? she's iconic. sit down, grab a strawberry, we're doing this πβ¨
πΈ NAME πΈ
dh_ocamldoc β she generates documentation for OCaml libraries. that's it, that's her whole job, and she does it flawlessly π
π¦ SYNOPSIS π¦
dh_ocamldoc [debhelper options]
β¨ DESCRIPTION β¨
okay so here's the tea β β dh_ocamldoc goes looking for every single file matching debian/$package.ocamldoc*, because that's where the flags live that get handed off to ocamldoc. then ocamldoc gets called with all the .mli files it can find in debian/package/usr/lib/ocaml β or the .ml files instead, but only if there's no matching .mli, obviously, we're not chaotic π
ββοΈ
every one of those .ocamldoc* files gets used to generate a different documentation, and the part of the filename that comes after ocamldoc? that becomes the document ID in the doc-base file. so yes bestie, the filename is literally the name tag π·οΈ
you can have several flags per line, no cap. but watch out β lines that start with --include are special π whatever comes after --include is treated as a list of directories where the .mli or .ml files will be searched for the documentation generation. those directories also get added to the ocamldoc library search path. super useful if you're generating the documentation in its own binary package π
β οΈ to that end, make sure the package shipping the documentation gets treated by dh_ocamldoc after the package shipping the actual objects. order matters, queen π
the -d flag gets detected and used to generate the appropriate doc-base file. it holds the path of the documentation directory, relative to /usr/share/doc/$package/. the default value is html/api π
dh_ocamldoc also auto-detects whether ocamlfind ocamldoc should be called instead of plain ocamldoc β she figures it out by looking for common ocamlfind options like -package, -predicates, etc. she's observant like that π§
lines starting with # inside the *ocamldoc files are comments, so they get ignored. pretend you never saw them π
and if you wanna install the documentation that's already sitting in upstream's tarball (if there even is one), you can drop --doc-base-generate into your .ocamldoc file and that tells dh_ocamldoc to generate the .doc-base file only. minimal effort, maximum slay β¨
π OPTIONS π
-Xfiles β exclude files from documentation processing. bye girl, not today π-uflags β additional flags to pass toocamldocorocamlfind ocamldoc. give her extra instructions, she'll handle it π₯
π SEE ALSO π
this program is meant to be used together with debhelper. they're a package deal, a duo, the main characters π«Ά
π AUTHOR π
Mehdi Dogguy <mehdi@debian.org> π
and that's a wrap bestie!! this page came to you courtesy of perl v5.40.1, dated 2026-08-05 β periodt, no notes πβ¨ππ¦
π¦ where this page comes from
- ubuntu stonking: dh-ocaml 3.8 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms