Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion build.zig
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,24 @@ pub fn build(b: *std.Build) void {
.optimize = optimize,
});

_ = b.addModule("jetkv", .{ .root_source_file = .{ .path = "src/jetkv.zig" } });
const jetkv_module = b.addModule("jetkv", .{ .root_source_file = .{ .path = "src/jetkv.zig" } });

const run_lib_unit_tests = b.addRunArtifact(lib_unit_tests);

const test_step = b.step("test", "Run unit tests");
test_step.dependOn(&run_lib_unit_tests.step);

if (target.result.os.tag != .windows) {
const args_dep = b.dependency("args", .{ .target = target, .optimize = optimize });

const fuzzer = b.addExecutable(.{
.name = "fuzzer",
.root_source_file = .{ .path = "utils/fuzzer.zig" },
.target = b.host,
});
fuzzer.root_module.addImport("jetkv", jetkv_module);
fuzzer.root_module.addImport("args", args_dep.module("args"));

b.installArtifact(fuzzer);
}
}
7 changes: 6 additions & 1 deletion build.zig.zon
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
.{
.name = "jetkv",
.version = "0.0.0",
.dependencies = .{},
.dependencies = .{
.args = .{
.url = "https://github.com/MasterQ32/zig-args/archive/adb65692a3e3e1d7ea00e4f865ef1b1718326573.tar.gz",
.hash = "1220e23828fcdbf6fdcd53b7cd422e041570bc52d65d4fb97ac76cd6fad6a88dccc1",
},
},
.paths = .{
"",
},
Expand Down
Loading