Allow bootstrapping libnv on macOS and Linux
MacOS/Linux do not define struct cmsgcred but we need to bootstrap libnv when building on non-FreeBSD systems. Since they are not used during bootstrap we can just omit these two functions there. Reviewed By: emaste Differential Revision: https://reviews.freebsd.org/D18472
This commit is contained in:
parent
3ec68206f5
commit
032f0fbbb6
@ -157,6 +157,14 @@ msg_send(int sock, const struct msghdr *msg)
|
||||
return (0);
|
||||
}
|
||||
|
||||
/*
|
||||
* MacOS/Linux do not define struct cmsgcred but we need to bootstrap libnv
|
||||
* when building on non-FreeBSD systems. Since they are not used during
|
||||
* bootstrap we can just omit these two functions there.
|
||||
*/
|
||||
#ifndef __FreeBSD__
|
||||
#warning "cred_send() not supported on non-FreeBSD systems"
|
||||
#else
|
||||
int
|
||||
cred_send(int sock)
|
||||
{
|
||||
@ -232,6 +240,7 @@ cred_recv(int sock, struct cmsgcred *cred)
|
||||
|
||||
return (0);
|
||||
}
|
||||
#endif
|
||||
|
||||
static int
|
||||
fd_package_send(int sock, const int *fds, size_t nfds)
|
||||
|
Loading…
x
Reference in New Issue
Block a user