Skip to content

Cygwin support in rustc #140154

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

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

Conversation

Berrysoft
Copy link
Contributor

@Berrysoft Berrysoft commented Apr 22, 2025

This PR builds host rustc targeting cygwin.

Currently supported:

  • rustc
  • rustdoc
  • rustfmt
  • clippy

Blocking:

$ rustc --version --verbose
rustc 1.88.0-dev
binary: rustc
commit-hash: unknown
commit-date: unknown
host: x86_64-pc-cygwin
release: 1.88.0-dev
LLVM version: 20.1.4

@rustbot
Copy link
Collaborator

rustbot commented Apr 22, 2025

r? @compiler-errors

rustbot has assigned @compiler-errors.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Apr 22, 2025
@Berrysoft

This comment was marked as outdated.

@jieyouxu jieyouxu added the O-cygwin Target: *-pc-cygwin label Apr 25, 2025
@jeremyd2019
Copy link
Contributor

I'm looking forward to being able to try this, and I bet @tyan0 and others from Cygwin are too!

@jeremyd2019
Copy link
Contributor

jeremyd2019 commented May 8, 2025

The build script of rustc_llvm is modified a little because llvm-config of MSYS2 is broken:

This should be fixed now (llvm/llvm-project#136599), and _GNU_SOURCE is defined in llvm-config --cppflags and friends (llvm/llvm-project#138329):

$ llvm-config --cxxflags
-I/usr/include -std=c++17   -fno-exceptions -funwind-tables -D_GNU_SOURCE -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS

@Berrysoft

This comment was marked as outdated.

@Berrysoft Berrysoft force-pushed the cygwin-host branch 2 times, most recently from 7ee303f to d23fa03 Compare May 13, 2025 16:35
@Berrysoft Berrysoft changed the title Experimental cygwin support in rustc Cygwin support in rustc May 14, 2025
@Berrysoft
Copy link
Contributor Author

r? @jieyouxu

@rustbot rustbot assigned jieyouxu and unassigned compiler-errors May 14, 2025
@rustbot
Copy link
Collaborator

rustbot commented May 16, 2025

The Miri subtree was changed

cc @rust-lang/miri

Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

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

Seems fine, I'll r+ after PR CI is green.

@jieyouxu
Copy link
Member

@bors r+

@bors
Copy link
Collaborator

bors commented May 16, 2025

📌 Commit 12c8fb8 has been approved by jieyouxu

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-cygwin Target: *-pc-cygwin S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants