(13051) Make the uniqueid for FreeBSD return the value of sysctl -n kern.hostid

New patch, moves hostuuid to a separate source file and adds unit tests
for both uniqueid and hostuuid on FreeBSD.

This patch was submitted by Garrett Wollman in the description of #13051.