Skip to content

deps: require at least libc 0.2.160 #52

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

Closed
wants to merge 1 commit into from
Closed

Conversation

mxinden
Copy link
Member

@mxinden mxinden commented Nov 29, 2024

#29 added the following libc import:

use libc::{
    freeifaddrs, getifaddrs, getpid, if_data, if_indextoname, ifaddrs, in6_addr, in_addr,
    sockaddr_in, sockaddr_in6, sockaddr_storage, AF_UNSPEC, PF_ROUTE, RTAX_MAX,
};

RTAX_MAX was added in libc 0.2.160:

https://github.com/rust-lang/libc/releases/tag/0.2.160

More specifically rust-lang/libc#3714.

This commit makes sure the above new requirement is encoded in the mtu Cargo.toml libc dependency declaration.

See CI failure without discussed in #51 (comment).

mozilla#29 added the following `libc` import:

``` rust
use libc::{
    freeifaddrs, getifaddrs, getpid, if_data, if_indextoname, ifaddrs, in6_addr, in_addr,
    sockaddr_in, sockaddr_in6, sockaddr_storage, AF_UNSPEC, PF_ROUTE, RTAX_MAX,
};
```

`RTAX_MAX` was added in `libc` `0.2.160`:

https://github.com/rust-lang/libc/releases/tag/0.2.160

More specifically rust-lang/libc#3714.

This commit makes sure the above new requirement is encoded in the `mtu`
`Cargo.toml` `libc` dependency declaration.

See CI failure without discussed in mozilla#51 (comment).
Comment on lines 24 to +25
# Don't increase beyond what Firefox is currently using: https://searchfox.org/mozilla-central/source/Cargo.lock
libc = { version = "0.2", default-features = false }
libc = { version = "0.2.160", default-features = false }
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These lines are at odds with each other, as mozilla-central currently depends on libc v0.2.158. We will need to bump mozilla-central's libc version before we can merge here.

https://searchfox.org/mozilla-central/rev/d4235354139ae0da3b15b89943b140b510a74f2f/Cargo.lock#3533-3537

Copy link

codecov bot commented Nov 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.42%. Comparing base (c7cd35a) to head (81afc43).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #52      +/-   ##
==========================================
- Coverage   93.61%   93.42%   -0.20%     
==========================================
  Files           5        5              
  Lines         517      517              
==========================================
- Hits          484      483       -1     
- Misses         33       34       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@larseggert
Copy link
Collaborator

This might change with the Solaris PR, which (as a side effect) pulls in more things from bindgen vs. libc. If we land that first, the libc version requirement might go away.

@larseggert
Copy link
Collaborator

Closing this in favor of #45, which addresses this as a side effect.

@larseggert larseggert closed this Dec 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants