FreeBSD 15+ has renameat2.
These values are supported:
AT_RENAME_NOREPLACE If the path specified by tofd and to exists, the
request fails with the error EEXIST.
AT_RENAME_EXCHANGE Atomically exchange the files pointed to by the from
and to names.
This one should also be added:
libc::SYS_renameat2
FreeBSD 15+ has renameat2.
These values are supported:
This one should also be added:
libc::SYS_renameat2