summaryrefslogtreecommitdiff
path: root/build.zig
diff options
context:
space:
mode:
Diffstat (limited to 'build.zig')
-rw-r--r--build.zig5
1 files changed, 5 insertions, 0 deletions
diff --git a/build.zig b/build.zig
index 903b7ea8..f59d1928 100644
--- a/build.zig
+++ b/build.zig
@@ -836,7 +836,10 @@ pub fn build(b: *std.Build) void {
image_mod.addCSourceFile(.{ .file = b.path("addons/image/stb.c"), .flags = &.{ "-std=c11", "-Wall", "-Wextra", "-Werror" } });
const image_addon = b.addLibrary(.{ .name = "image", .linkage = .dynamic, .root_module = image_mod });
for (builtin_mods) |m| m.addImport("image_addon", image_mod);
+ // The records the core and the terminal both name (src/plain/plain.zig).
+ const plain_mod = b.createModule(.{ .root_source_file = b.path("src/plain/plain.zig"), .target = target, .optimize = optimize });
for (core_mods) |m| wireCore(m, .{
+ .plain = plain_mod,
.kind = kind_mod,
.themes = themes_mod,
.tree_sitter = ts_mod,
@@ -2188,6 +2191,7 @@ fn library(b: *std.Build) void {
}
fn wireCore(m: *std.Build.Module, d: struct {
+ plain: ?*std.Build.Module = null,
kind: ?*std.Build.Module = null,
themes: ?*std.Build.Module = null,
tree_sitter: ?*std.Build.Module = null,
@@ -2202,6 +2206,7 @@ fn wireCore(m: *std.Build.Module, d: struct {
wuffs: ?*std.Build.Module = null,
xitdb: ?*std.Build.Module = null,
}) void {
+ if (d.plain) |x| m.addImport("plain", x);
if (d.kind) |x| m.addImport("pardes_addon", x);
if (d.themes) |x| m.addImport("generated_themes", x);
if (d.tree_sitter) |x| m.addImport("tree-sitter", x);