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

Build release artifact against older Glibc #13214

Merged
merged 5 commits into from Sep 11, 2022

Conversation

SpencerSharkey
Copy link
Contributor

When GitHub deprecated Ubuntu 18.04 runners, rust-analyzer was forced to bump runners to 20.04 which includes an updated Glib. This renders RA incompatible with the still popular Ubuntu 18.04 and other slightly older distro versions.

Until a deprecation plan is announced on RA's side, I propose binaries shall be built against older glibc to maintain compatibility.

This PR changes the Release CI workflow to build the linux-x64/x86_64-unknown-linux-gnu release in an Ubuntu 18.04 container.

Fixes #13081 and #13085

rustup update --no-self-update stable
rustup target add ${{ matrix.target }}
rustup component add rust-src
uses: actions-rs/toolchain@v1
Copy link
Member

Choose a reason for hiding this comment

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

Is this actually needed? We were using it before, but it's unmaintained and doesn't do much anyway.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

the container needs the toolchain explicitly installed as ubuntu:18.04 doesn't come with rustup

Copy link
Member

Choose a reason for hiding this comment

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

Oh, right. I think it's better to install it from rustup.rs, though.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

good idea. i took a page from dtolnay/rust-toolchain's install script which installs from rustup.sh.

Copy link
Member

Choose a reason for hiding this comment

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

Do we also want --profile minimal there?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

sure, that's in. seems to be working.

Copy link
Member

Choose a reason for hiding this comment

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

Sorry, I think we also need --components rust-src because otherwise the analysis-stats down below will fail.

Copy link
Member

Choose a reason for hiding this comment

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

Ah, never mind, that's done just below.

@lnicola
Copy link
Member

lnicola commented Sep 11, 2022

I still think that long-term we should either support only more recent distros or use the rust-lang/rust CI images, but this doesn't seem too bad, and it probably makes some users happy in the meanwhile.

@lnicola
Copy link
Member

lnicola commented Sep 11, 2022

Well, I'll merge this later today if nobody objects, then trigger an early nightly.

@lnicola
Copy link
Member

lnicola commented Sep 11, 2022

@SpencerSharkey thanks for looking into this. I expect it to break rather soon-ish, but we can probably switch to CentOS 7 in a pinch.

@lnicola
Copy link
Member

lnicola commented Sep 11, 2022

@bors r+

@bors
Copy link
Collaborator

bors commented Sep 11, 2022

📌 Commit 73d7599 has been approved by lnicola

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented Sep 11, 2022

⌛ Testing commit 73d7599 with merge 2e9f120...

@bors
Copy link
Collaborator

bors commented Sep 11, 2022

☀️ Test successful - checks-actions
Approved by: lnicola
Pushing 2e9f120 to master...

@kting28
Copy link

kting28 commented Jan 23, 2023

Latest 2023 release still seems to require GLIBC_2.25. I see this issue has been closed for a while. Is this still being propagated to the releases?

@lnicola
Copy link
Member

lnicola commented Jan 23, 2023

@kting28 it's built on Ubuntu 18.04, which has GLIBC 2.27. What are you using with a version older than 2.25?

@kting28
Copy link

kting28 commented Jan 23, 2023

@kting28 it's built on Ubuntu 18.04, which has GLIBC 2.27. What are you using with a version older than 2.25?

In that case never mind. I didn't realize the machines I have (SUSE Enterprise Server 12) is even older than 18.04. I will have to compile rust-analyzer from source then. Thanks for the update!

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.

2022-08-22 release updated GLIBC version dependency
4 participants