Skip to content

build: using zig 0.6.0 will cause a compiler error #210

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

Closed
Tracked by #212
perillo opened this issue Apr 2, 2023 · 0 comments
Closed
Tracked by #212

build: using zig 0.6.0 will cause a compiler error #210

perillo opened this issue Apr 2, 2023 · 0 comments

Comments

@perillo
Copy link
Contributor

perillo commented Apr 2, 2023

A comment in build.zig says:

/// Check the zig version to make sure it can compile the examples properly.
/// This will compile with Zig 0.6.0 and later.

However I tested with zig 0.6.0 and got a compiler error:

const needed_version = std.SemanticVersion.parse("0.11.0-dev.2157") catch unreachable;
                          ^
./build.zig:531:13: note: referenced here
        , .{needed_version});
            ^
/home/manlio/.local/share/sdk/zig/0.6.0/lib/zig/std/special/build_runner.zig:133:24: note: referenced here
        .ErrorUnion => try root.build(builder),
                       ^

I will fix it.

@perillo perillo mentioned this issue Apr 2, 2023
4 tasks
vamega pushed a commit to vamega/ziglings that referenced this issue Jul 25, 2023
The version check for Zig 0.6.0 was incorrect since commit
6e57678 (Use a zig build script to run ziglings).

Move compatibility support to a separate file, in order to simplify
build.zig.

In case of incompatible version, exit with code 3 instead of 0, in order
to detect the case of failure in a test (to be implemented).

Remove the use of comptime when checking compatibility at the start of
the build function, since it is not necessary.

Closes ratfactor#210.
fleimgruber pushed a commit to fleimgruber/ziglings that referenced this issue Oct 26, 2023
The version check for Zig 0.6.0 was incorrect since commit
971ab7f (Use a zig build script to run ziglings).

Move compatibility support to a separate file, in order to simplify
build.zig.

In case of incompatible version, exit with code 3 instead of 0, in order
to detect the case of failure in a test (to be implemented).

Remove the use of comptime when checking compatibility at the start of
the build function, since it is not necessary.

Closes ratfactor#210.
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

No branches or pull requests

1 participant