We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6f0a613 commit 235e6acCopy full SHA for 235e6ac
test/standalone/compiler_rt_panic/build.zig
@@ -7,13 +7,15 @@ pub fn build(b: *std.Build) void {
7
const target = b.standardTargetOptions(.{});
8
const optimize = b.standardOptimizeOption(.{});
9
10
- if (target.getObjectFormat() != .elf) return;
+ const abi = target.getAbi();
11
+ if (target.getObjectFormat() != .elf or !(abi.isMusl() or abi.isGnu())) return;
12
13
const exe = b.addExecutable(.{
14
.name = "main",
15
.optimize = optimize,
16
.target = target,
17
});
18
+ exe.linkLibC();
19
exe.addCSourceFile("main.c", &.{});
20
exe.link_gc_sections = false;
21
exe.bundle_compiler_rt = true;
0 commit comments