-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add IP[V6]_[RECV]ORIGDSTADDR for Linux and Android #1252
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
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @gnzlbg (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
These constants are defined on FreeBSD 12, too. You should add them to all platforms that define them, not just Linux. |
Is only FreeBSD missing? How do I know exhaustive list of platforms I need to add? Is just googling sufficient or one supposed to actually run a fresh release in a VM and check if it's there or not? |
You aren't expected to run your own VM for every single platform. That's CI's job. But figuring out which platforms support a certain symbol is something that you can do. The easiest way is to check online man pages. That works well when binding functions. For constants you may need to look at the sources. Here are some of the resources I use: It's hard to find definitive answers for Linux because it's so fragmented. But a VM can give pretty good answers, even if they aren't perfect. The hardest platform to research is OSX. I pretty much use Google for OSX. |
For MacOS X you can search for the MacOSXSDK headers, e.g., this repo contains most of them: https://github.com/phracker/MacOSX-SDKs The only thing to keep in mind is that for i686-apple-darwin macosx headers types sometimes use Maybe we should compile some of this information to the contribution docs. |
@bors: r+ |
📌 Commit 4d0694c has been approved by |
Add IP[V6]_[RECV]ORIGDSTADDR for Linux and Android
☀️ Test successful - checks-cirrus, checks-travis, status-appveyor |
Why did you merge the PR even though it was incomplete, @gnzlbg ? |
I thought we could add the FreeBSD 12 constants in a subsequent PR (as in, no need to block this part from landing on that). |
I tried searching superficially for But looking at https://reviews.freebsd.org/D9235 and For Are those things supposed to be auto-generated from headers (or closely track platorm's respective header files) or each item should be judged on case-by-case basis? |
Yeah, libc has plenty of missing definitions. You don't need to worry about fixing all of them, but it's good not to make things worse. You can CC me as a reviewer if you want. |
A follow-up from rust-lang#1252. CC @asomers. r? @gnzlbg.
No description provided.