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

Consider a secondary source of prebuilt artifacts #227

Open
dzbarsky opened this issue Oct 4, 2023 · 5 comments
Open

Consider a secondary source of prebuilt artifacts #227

dzbarsky opened this issue Oct 4, 2023 · 5 comments
Labels
enhancement New feature or request

Comments

@dzbarsky
Copy link
Contributor

dzbarsky commented Oct 4, 2023

We ran into an issue of prebuilt clang binaries needing a too-new version of glibc, and that sparked me to build our own clang distribution from source. I made it fully statically linked to avoid glibc issues in the future. See https://github.com/dzbarsky/static-clang/tags

Another reason we did this is because the normal distributions are huge (700MB compressed 5.5GB uncompressed).

I'm planning to continue to tag point releases as they come out, since everything is automated and it's very low effort. @siddharthab Curious to hear what you think of this approach, if you're interested in making this a more-supported option in the toolchain, we can expand the built archive to include the rest of the tools that I've currently stubbed out

@siddharthab
Copy link
Contributor

Interesting! Thanks. If you have the time to do it, you can add this as an additional source of URLs in this repo for auto detection.

Note that users can always explicitly specify their own URLs to bring their own distributions, so we should at the very least add a definition in the tests workspace as an example and run the basic tests in CI. And then maybe mention in the README that people can use your distributions.

As for the stubs you mentioned, it will be confusing if those files are empty. For example, I have used profdata before for use with bazel coverage.

@dzbarsky
Copy link
Contributor Author

dzbarsky commented Oct 4, 2023

Yep, agreed that I should fix the stubs to prevent confusion from some features not working :)

I think I'll make a use_static_distribution: bool flag on llvm_toolchain (bikeshed names welcome), wire that up to URLs, and then add a test workspace

@siddharthab
Copy link
Contributor

That sounds very good to me.

@siddharthab siddharthab added the enhancement New feature or request label Mar 12, 2024
@peakschris
Copy link
Contributor

@dzbarsky looks cool! Could these include clang-tidy and clang-format, perhaps in separate archives to avoid bloat? And could you support windows?

@peakschris
Copy link
Contributor

This PR is the context to my question: #342

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants