Skip to content

add cygwin support #1871

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

Merged
merged 4 commits into from
Jun 9, 2025
Merged

add cygwin support #1871

merged 4 commits into from
Jun 9, 2025

Conversation

Berrysoft
Copy link
Contributor

This PR adds cygwin support. It uses the POSIX poll as backend. I tried my best to fix the tests. Some of them are ignored reasonably, while some of them are not - related to the UnixListener and UnixStream. I don't understand them yet.

Copy link
Collaborator

@Thomasdezeeuw Thomasdezeeuw left a comment

Choose a reason for hiding this comment

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

Mostly LGTM. For the ignored tests can you add a reason why they are ignored.

@Berrysoft
Copy link
Contributor Author

@Thomasdezeeuw I enabled the 4 ignored tests, adding some workarounds to complete the handshake:

  • For UnixListener, it should call accept to unblock the client thread. Fortunately there is always an accept call in the real usages, I think.
  • For UnixStream, it should poll after connect to unblock the server thread. I think it should be true in the real usage, where the async runtime always poll after connect.

@Berrysoft
Copy link
Contributor Author

CI is failing but it's not my problem. The master branch also fails.

@Berrysoft Berrysoft requested a review from Thomasdezeeuw June 5, 2025 15:40
@Berrysoft
Copy link
Contributor Author

I proposed a fix for CI in #1883 .

@Thomasdezeeuw Thomasdezeeuw merged commit f352b81 into tokio-rs:master Jun 9, 2025
23 of 58 checks passed
@Thomasdezeeuw
Copy link
Collaborator

Thanks @Berrysoft

@Berrysoft Berrysoft deleted the dev/cygwin branch June 9, 2025 10:42
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