1 Star 0 Fork 0

朕与将军解战袍 / zbinrw

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
build.zig 1.49 KB
一键复制 编辑 原始数据 按行查看 历史
朕与将军解战袍 提交于 2023-08-15 15:50 . v0.0.1-beta
const std = @import("std");
// Although this function looks imperative, note that its job is to
// declaratively construct a build graph that will be executed by an external
// runner.
pub fn build(b: *std.Build) void {
// Standard target options allows the person running `zig build` to choose
// what target to build for. Here we do not override the defaults, which
// means any target is allowed, and the default is native. Other options
// for restricting supported target set are available.
const target = b.standardTargetOptions(.{});
// Standard optimization options allow the person running `zig build` to select
// between Debug, ReleaseSafe, ReleaseFast, and ReleaseSmall. Here we do not
// set a preferred release mode, allowing the user to decide how to optimize.
const optimize = b.standardOptimizeOption(.{});
// Creates a step for unit testing. This only builds the test executable
// but does not run it.
const zbinrw_tests = b.addTest(.{
.root_source_file = .{ .path = "zbinrw.zig" },
.target = target,
.optimize = optimize,
});
const run_zbinrw_tests = b.addRunArtifact(zbinrw_tests);
// This creates a build step. It will be visible in the `zig build --help` menu,
// and can be selected like this: `zig build test`
// This will evaluate the `test` step rather than the default, which is "install".
const test_step = b.step("test", "Run library tests");
test_step.dependOn(&run_zbinrw_tests.step);
}
1
https://gitee.com/L_Lawliet_moon/zbinrw.git
git@gitee.com:L_Lawliet_moon/zbinrw.git
L_Lawliet_moon
zbinrw
zbinrw
main

搜索帮助

53164aa7 5694891 3bd8fe86 5694891