update build.zig in threads
This commit is contained in:
parent
48e0a65413
commit
7761accd98
@ -4,19 +4,17 @@ pub fn build(b: *std.build.Builder) void {
|
|||||||
const target = b.standardTargetOptions(.{});
|
const target = b.standardTargetOptions(.{});
|
||||||
const optimize = b.standardOptimizeOption(.{});
|
const optimize = b.standardOptimizeOption(.{});
|
||||||
|
|
||||||
{
|
const exe = b.addExecutable(.{
|
||||||
const exe = b.addExecutable(.{
|
.name = "threads-example",
|
||||||
.name = "threads-simple",
|
.root_source_file = .{ .path = "main.c" },
|
||||||
.root_source_file = .{ .path = "main.c" },
|
.optimize = optimize,
|
||||||
.optimize = optimize,
|
.target = target
|
||||||
.target = target
|
});
|
||||||
});
|
exe.linkLibC();
|
||||||
exe.linkLibC();
|
|
||||||
|
|
||||||
const run_cmd = b.addRunArtifact(exe);
|
const run_cmd = b.addRunArtifact(exe);
|
||||||
const run_step = b.step("run", "Run simple program");
|
const run_step = b.step("run", "Run simple program");
|
||||||
run_step.dependOn(&run_cmd.step);
|
run_step.dependOn(&run_cmd.step);
|
||||||
|
|
||||||
b.installArtifact(exe);
|
b.installArtifact(exe);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user