Hi Ian,
I fear help2man is a deep rabbit hole. Its use typically breaks cross
building. There are very many different approaches to handle this:
* Include generated manual pages in the source package and rebuild them
in native builds only.
* Declare Build-Depends: $SELF:native <cross> and run help2man on the
installed tools.
* Build the package twice. Once for the .deb and once for help2man.
This is only really feasible when there are few dependencies and the
package is small. It is what I am suggesting here.
* Write real manual pages.
* Write a shell script that extracts the --help output from the source
code without compilation (rarely works).
* Skip installing manual pages in cross builds. (breaks
reproducibility)
* Fail cross building unless you pass the nodoc build profile.
As you can see, the solution space is big. In general, my impression is
that manual pages generated using help2man can mostly be deleted. Their
only reason to exist is to make lintian happy and you could just add an
override instead.
Helmut