22 lines
611 B
Zig
22 lines
611 B
Zig
const std = @import("std");
|
|
|
|
pub fn build(b: *std.build.Builder) void {
|
|
const target = b.standardTargetOptions(.{});
|
|
const optimize = b.standardOptimizeOption(.{});
|
|
|
|
_ = b.addModule("zig-glib-log", .{
|
|
.source_file = .{ .path = "src/main.zig" },
|
|
});
|
|
|
|
const test_exe = b.addTest(.{
|
|
.root_source_file = .{ .path = "src/main.zig" },
|
|
.target = target,
|
|
.optimize = optimize,
|
|
});
|
|
|
|
test_exe.linkLibC();
|
|
test_exe.linkSystemLibrary("glib-2.0");
|
|
|
|
const test_step = b.step("test", "run tests");
|
|
test_step.dependOn(&b.addRunArtifact(test_exe).step);
|
|
}
|