It now occurs to me that this unittest fails to ensure the function compiles, only that _if_ it compiles, it works correctly.  Eg a change to signature of `realpath` could break this function on linux without being detected by the autotester.

I think it should be explicitly disabled for FreeBSD/OpenBSD/any others we have chosen not to implement at the moment.  This will force new ports to explicitly consider this function.  It is possible the documentation should also assume this policy, but I'm less sure on that.