Skip to content

Commit d5dfac3

Browse files
committed
Add build.zig
1 parent dec01ce commit d5dfac3

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

build.zig

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
const std = @import("std");
2+
3+
pub fn build(b: *std.build.Builder) void {
4+
// Standard release options allow the person running `zig build` to select
5+
// between Debug, ReleaseSafe, ReleaseFast, and ReleaseSmall.
6+
const mode = b.standardReleaseOptions();
7+
8+
const lib = b.addStaticLibrary("cf", "cf.zig");
9+
lib.setBuildMode(mode);
10+
lib.install();
11+
12+
const main_tests = b.addTest("cf.zig");
13+
main_tests.setBuildMode(mode);
14+
15+
const test_step = b.step("test", "Run library tests");
16+
test_step.dependOn(&main_tests.step);
17+
}

0 commit comments

Comments
 (0)