mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
gnu: Add zig.
* gnu/packages/patches/zig-disable-libc-note-test.patch, gnu/packages/patches/zig-use-system-paths.patch: New files. * gnu/packages/zig.scm: New file. * gnu/local.mk (GNU_SYSTEM_MODULES, dist_patch_DATA): Adjust accordingly.
This commit is contained in:
parent
84c6f17f16
commit
9f2c5e901e
4 changed files with 281 additions and 0 deletions
31
gnu/packages/patches/zig-disable-libc-note-test.patch
Normal file
31
gnu/packages/patches/zig-disable-libc-note-test.patch
Normal file
|
@ -0,0 +1,31 @@
|
|||
This test fails with "error.CompilationIncorrectlySucceeded".
|
||||
|
||||
diff --git a/test/compile_errors.zig b/test/compile_errors.zig
|
||||
index fd1255c..20d5548 100644
|
||||
--- a/test/compile_errors.zig
|
||||
+++ b/test/compile_errors.zig
|
||||
@@ -2751,15 +2751,15 @@ pub fn addCases(cases: *tests.CompileErrorContext) void {
|
||||
"tmp.zig:3:5: error: dependency on libc must be explicitly specified in the build command",
|
||||
});
|
||||
|
||||
- cases.addTest("libc headers note",
|
||||
- \\const c = @cImport(@cInclude("stdio.h"));
|
||||
- \\export fn entry() void {
|
||||
- \\ _ = c.printf("hello, world!\n");
|
||||
- \\}
|
||||
- , &[_][]const u8{
|
||||
- "tmp.zig:1:11: error: C import failed",
|
||||
- "tmp.zig:1:11: note: libc headers not available; compilation does not link against libc",
|
||||
- });
|
||||
+// cases.addTest("libc headers note",
|
||||
+// \\const c = @cImport(@cInclude("stdio.h"));
|
||||
+// \\export fn entry() void {
|
||||
+// \\ _ = c.printf("hello, world!\n");
|
||||
+// \\}
|
||||
+// , &[_][]const u8{
|
||||
+// "tmp.zig:1:11: error: C import failed",
|
||||
+// "tmp.zig:1:11: note: libc headers not available; compilation does not link against libc",
|
||||
+// });
|
||||
}
|
||||
|
||||
cases.addTest("comptime vector overflow shows the index",
|
Loading…
Add table
Add a link
Reference in a new issue