-
Notifications
You must be signed in to change notification settings - Fork 679
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add MSG_WAITFORONE
flag
#2014
Add MSG_WAITFORONE
flag
#2014
Conversation
8360327
to
0dba904
Compare
0dba904
to
f029aa2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If some definitions are missing from libc, then you should add them there rather than leave them out here. That's a very common thing to do when adding new functionality to Nix.
Add `MSG_WAITFORONE` to freebsd and openbsd Adds `MSG_WAITFORONE` to freebsd, openbsd, and ~illumos~, as requested in nix-rust/nix#2014. I got the values from: - freebsd: http://fxr.watson.org/fxr/source/sys/socket.h#L473 - openbsd: https://github.com/openbsd/src/blob/2852e11abfc574a216ce741308fb0c6968d9617a/sys/sys/socket.h#L512 - illumos: https://github.com/illumos/illumos-gate/blob/717646f7112314de3f464bc0b75f034f009c861e/usr/src/boot/sys/sys/socket.h#L434 This flag is also supposedly supported on [solaris](https://docs.oracle.com/cd/E88353_01/html/E37843/recvmmsg-3c.html), but I don't know how to find the value. If anyone knows what it is, I'll add it to the PR.
Add `MSG_WAITFORONE` to freebsd and openbsd Adds `MSG_WAITFORONE` to freebsd, openbsd, and ~illumos~, as requested in nix-rust/nix#2014. I got the values from: - freebsd: http://fxr.watson.org/fxr/source/sys/socket.h#L473 - openbsd: https://github.com/openbsd/src/blob/2852e11abfc574a216ce741308fb0c6968d9617a/sys/sys/socket.h#L512 - illumos: https://github.com/illumos/illumos-gate/blob/717646f7112314de3f464bc0b75f034f009c861e/usr/src/boot/sys/sys/socket.h#L434 This flag is also supposedly supported on [solaris](https://docs.oracle.com/cd/E88353_01/html/E37843/recvmmsg-3c.html), but I don't know how to find the value. If anyone knows what it is, I'll add it to the PR.
Add `MSG_WAITFORONE` to freebsd and openbsd Adds `MSG_WAITFORONE` to freebsd, openbsd, and ~illumos~, as requested in nix-rust/nix#2014. I got the values from: - freebsd: http://fxr.watson.org/fxr/source/sys/socket.h#L473 - openbsd: https://github.com/openbsd/src/blob/2852e11abfc574a216ce741308fb0c6968d9617a/sys/sys/socket.h#L512 - illumos: https://github.com/illumos/illumos-gate/blob/717646f7112314de3f464bc0b75f034f009c861e/usr/src/boot/sys/sys/socket.h#L434 This flag is also supposedly supported on [solaris](https://docs.oracle.com/cd/E88353_01/html/E37843/recvmmsg-3c.html), but I don't know how to find the value. If anyone knows what it is, I'll add it to the PR.
I've added it for more platforms in libc, and that change is in the latest libc release. |
This PR is still failing because MSG_WAITFORONE isn't defined everywhere. You need to update the libc spec in Cargo.toml. Also, I think you need to rebase to fix the failure in Linux armv7 uclibceabihf |
e9893a6
to
cf8f9d1
Compare
This is rebased and all tests now pass. |
I'm not sure what platforms this is defined on, so I listed the ones that I think it's defined on. Below I've listed why I think it's defined on each platform.
Edit: Removed the flag for freebsd, illumos, and openbsd since it isn't defined in the rust libc library for those platforms. The linux musl failure seems to be unrelated.
Edit 2: Added a changelog entry.