25 lines
679 B
Zig
25 lines
679 B
Zig
const std = @import("std");
|
|
|
|
pub fn build(b: *std.Build) void {
|
|
const target = b.standardTargetOptions(.{});
|
|
const optimize = b.standardOptimizeOption(.{});
|
|
|
|
const zigmulator = b.addModule("zigmulator", .{
|
|
.root_source_file = b.path("src/simulator.zig"),
|
|
.target = target,
|
|
.optimize = optimize,
|
|
});
|
|
|
|
const exe = b.addExecutable(.{
|
|
.name = "example",
|
|
.root_module = b.createModule(.{
|
|
.root_source_file = b.path("examples/example.zig"),
|
|
.target = target,
|
|
.optimize = optimize,
|
|
}),
|
|
});
|
|
exe.root_module.addImport("zigmulator", zigmulator);
|
|
|
|
b.installArtifact(exe);
|
|
}
|