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

zig: Update to latest released version #4838

Closed
wants to merge 1 commit into from

Conversation

nazar-stasiv
Copy link
Contributor

Summary

  • Aligning LLVM and Zig releases is a PITA
  • Ship precompiled binary, so no more of that BS
  • Fix maintainer file too

Test Plan

  • zig init; zig build run; zig build test

Checklist

  • Package was built and tested against unstable

**Summary**
- Aligning LLVM and Zig releases is a PITA
- Ship precompiled binary, so no more of that BS
- Fix maintainer file too

**Test Plan**
- zig init; zig build run; zig build test

**Checklist**
- [X] Package was built and tested against unstable
@GZGavinZhao
Copy link
Member

This is building without LLVM extensions, which lacks some features that we need, in particular compiling C/C++ with Zig. Closing this in favor of #4844.

@GZGavinZhao
Copy link
Member

Sorry I read too quickly. We'd still like to build from source when possible, so if I can't fix #4844 we'll consider this one.

@GZGavinZhao GZGavinZhao reopened this Jan 17, 2025
@nazar-stasiv
Copy link
Contributor Author

This is building without LLVM extensions, which lacks some features that we need, in particular compiling C/C++ with Zig. Closing this in favor of #4844.

Prebuilt package is linked statically to supported LLVM, so your assumption is incorrect: CC=zig should work no problem.

@nazar-stasiv
Copy link
Contributor Author

nazar-stasiv commented Jan 17, 2025

Sorry I read too quickly. We'd still like to build from source when possible, so if I can't fix #4844 we'll consider this one.

In that case look no further than https://github.com/ziglang/zig/wiki/How-to-build-LLVM,-libclang,-and-liblld-from-source#posix

Also please update maintainers file with #4844
Thanks

PS You would want LLVM version referenced in 0.13.0 release notes which Solus doesn't ship anymore

@nazar-stasiv nazar-stasiv deleted the update_zig branch January 19, 2025 17:21
@ReillyBrogan
Copy link
Contributor

The reason the other PR was preferred is that regardless of whether or not it's a PITA we really do need to build such compilers from source in order for them to make sense to be in the repo. Otherwise it would make more sense for users/packages to just download the pre-compiled toolchain at build-time (we could have build ghostty this way FWIW). While there are a few pre-compiled packages that we have exceptions for it's almost always for something that's proprietary and that can't be built from source anyway (like Discord).

I think this is ultimately my fault since I didn't realize that Zig applications are so tied to the version of Zig and thought that a snapshot would be fine (as it was the only way to build against LLVM 19). I think next time when we do LLVM upgrades we'll add a minimal version of the previous version if something needs it and just link Zig against that if it's not yet ready for the newer version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants