Skip to content
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

accept4 is not defined in libc for android #1469

Closed
wants to merge 1 commit into from

Conversation

elwerene
Copy link

@elwerene elwerene commented Mar 5, 2021

In libc 0.2.87 there's no accept4 in unix/linux_like/android/mod.rs.
It is defined in unix/linux_like/linux/mod.rs, but this module is not loaded on android

@Thomasdezeeuw
Copy link
Collaborator

This is a regression in libc, not Mio. See rust-lang/libc#2101.

@Thomasdezeeuw
Copy link
Collaborator

For a quick fix add the following to your Cargo.toml:

[dependencies]
libc = "=0.2.86" # Note the `=` here.

@elwerene
Copy link
Author

elwerene commented Mar 5, 2021

@Thomasdezeeuw I had to add libc as dependency to my project to fix the build as the dependency to libc without = is defined in https://github.com/tokio-rs/mio/blob/master/Cargo.toml#L49

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