On 2022-01-08 14:59:56 -0500, Tom Lane wrote:
> > We could grab it from ossp-uuid or e2fs - both seem to be compatibly licensed?
>
> Right, I was planning to have a look at how they'd done it. The BSD
> implementation seems to be inside the kernel, so that's not likely
> to be helpful, but the other two must be in userspace.
https://github.com/tytso/e2fsprogs/blob/master/lib/uuid/gen_uuid.c#L240
https://github.com/sean-/ossp-uuid/blob/master/uuid_mac.c#L92