mirror of
https://github.com/nine-lives-later/zzmq.git
synced 2024-09-29 04:48:46 +08:00
305b54d994
(examples are still wip) See https://github.com/nine-lives-later/zzmq/pull/3 Thanks to https://github.com/7Zifle for most of the work!
26 lines
666 B
Zig
26 lines
666 B
Zig
const std = @import("std");
|
|
|
|
pub fn build(b: *std.Build) !void {
|
|
const target = b.standardTargetOptions(.{});
|
|
const optimize = b.standardOptimizeOption(.{});
|
|
|
|
_ = b.addModule("zzmq", .{
|
|
.root_source_file = .{ .path = "src/zzmq.zig" },
|
|
});
|
|
|
|
const lib_test = b.addTest(.{
|
|
.root_source_file = .{ .path = "src/zzmq.zig" },
|
|
.target = target,
|
|
.optimize = optimize,
|
|
});
|
|
|
|
lib_test.linkSystemLibrary("zmq");
|
|
lib_test.linkLibC();
|
|
|
|
const run_test = b.addRunArtifact(lib_test);
|
|
run_test.has_side_effects = true;
|
|
|
|
const test_step = b.step("test", "Run tests");
|
|
test_step.dependOn(&run_test.step);
|
|
}
|