2021-03-06 03:13:05 +00:00
|
|
|
const std = @import("std");
|
2018-09-17 22:08:56 +01:00
|
|
|
|
2021-03-06 03:13:05 +00:00
|
|
|
pub fn build(b: *std.build.Builder) void {
|
|
|
|
// Standard release options allow the person running `zig build` to select
|
|
|
|
// between Debug, ReleaseSafe, ReleaseFast, and ReleaseSmall.
|
2018-09-17 22:08:56 +01:00
|
|
|
const mode = b.standardReleaseOptions();
|
2021-03-06 03:13:05 +00:00
|
|
|
|
2018-09-17 22:08:56 +01:00
|
|
|
const lib = b.addStaticLibrary("$", "src/main.zig");
|
|
|
|
lib.setBuildMode(mode);
|
2019-07-04 20:32:44 +01:00
|
|
|
lib.install();
|
2018-09-17 22:08:56 +01:00
|
|
|
|
2021-10-29 18:37:17 +01:00
|
|
|
const main_tests = b.addTest("src/main.zig");
|
2018-09-17 22:08:56 +01:00
|
|
|
main_tests.setBuildMode(mode);
|
|
|
|
|
|
|
|
const test_step = b.step("test", "Run library tests");
|
|
|
|
test_step.dependOn(&main_tests.step);
|
|
|
|
}
|