feat!: support zig 0.16#635
Conversation
|
@aherrmann I think this somehow surfaces that the removal of |
I haven't looked at the changes, yet. But, I encountered the same issue in the Bazel 9 upgrade PR and therefore kept the workaround alive: 02914a0 |
|
I think there is another issue then because this PR is rebased on |
aherrmann
left a comment
There was a problem hiding this comment.
I'm only about half-way through, but pushing these comments already.
Ok so actually this has been there since rules_cc 0.2.18. I'm not 100% sure but it seems that the issue is because the |
Thanks for the valid points ! changes were so wide things got lost. It makes me wonder if we should provide support for previous Zig versions. |
|
All first review addressed |
It is not automatically tested, but, the purpose of those tests is to check that docs generation works properly, and the source doc strings make their way into the generated docs.
|
Fixed and green |
The runfiles decltest is meant as an example how to use the library. As such it shouldn't use testutils, since those won't be available to users.
aherrmann
left a comment
There was a problem hiding this comment.
Thank you for putting this together! Some small comments. I also found and fixed a remote execution failure with the runfiles decltest.
| @@ -1,133 +0,0 @@ | |||
| { | |||
There was a problem hiding this comment.
This one should not be left empty, but should be updated to the latest 0.17 dev. Otherwise, we're not testing the extra-versions feature.
| zig.index(file = "extra-versions.json") | ||
| zig.toolchain(zig_version = "0.16.0-dev.381+bc512648d") |
There was a problem hiding this comment.
Needs to be updated to a 0.17 dev test.
| ) | ||
|
|
||
| TEST_VERSIONS = TOOL_VERSIONS.keys() + [ | ||
| "0.16.0-dev.381+bc512648d", |
|
|
||
| test "zig_target_toolchain attribute dynamic_linker configures the interpreter" { | ||
| if (true) { | ||
| // Zig 0.16 rejects custom dynamic linkers for some compiler sub-steps. |
There was a problem hiding this comment.
Is this related to https://codeberg.org/ziglang/zig/issues/31760 ?
Does it fail on all test platforms or just some? I.e. is it possible to keep this test alive on platforms where it works, or is it completely unsupported by Zig 0.16?
There was a problem hiding this comment.
Gating this only for 0.16 instead of skipping all the time. Sadly, this happens all the time in zig 0.16 for subcompilation steps like compiler-rt or libc (in which this test is about), start files etc...
Co-authored-by: Andreas Herrmann <andreash87@gmx.ch>
Co-authored-by: Andreas Herrmann <andreash87@gmx.ch>
Co-authored-by: Andreas Herrmann <andreash87@gmx.ch>
|
Finally green ! |
Closes #625
This PR is a mix of upstream of
zml/rules_zig+ additional fixes to comply with currentaherrmann/rules_zig.It's mainly porting all zig source code to support zig 0.16.x AND zig 0.15.x
The only changes non related to tests are:
zigandzig translate-cinstead of CLI args since in zig 0.16, those variables are not always read from the CLI args (I think it's a bug from zig).BREAKING CHANGE