To build Samba documentation from the supplied XML files you need to specify where all the Docbook templates are situated. This is described in a catalog file, which on Linux is situated in /etc/xml/catalog normally. On FreeBSD this location is different.
In buildtools/wafsamba/wafsamba.py we have:
bld.env.SAMBA_CATALOGS = 'file:///etc/xml/catalog file:///usr/local/share/xml/catalog file://' + bld.srcnode.abspath() + '/bin/default/docs-xml/build/catalog.xml'
That looks like attempt to address location of FreeBSD catalog file, but it's wrong, as /usrlocal is a default prefix, but could be anything set during the build process.
Better and more universal case would be to use XML_CATALOG_FILES environment variable to override that location or at least command line switch to waf --configure.
XML catalog behavior can be changed by redirecting queries to the
user's own set of catalogs. This can be done by setting the
XML_CATALOG_FILES environment variable to a list of catalogs. An
empty one should deactivate loading the default /etc/xml/catalog