Use `table_0_fields` build option
parent
1c445fae9b
commit
807d128e20
|
|
@ -42,8 +42,8 @@
|
||||||
.lazy = true,
|
.lazy = true,
|
||||||
},
|
},
|
||||||
.uucode = .{
|
.uucode = .{
|
||||||
.url = "https://github.com/jacobsandlund/uucode/archive/539c710408cda93d2fa28825d67cb5685d963fc1.tar.gz",
|
.url = "https://github.com/jacobsandlund/uucode/archive/35c0a6b7d653fa91a46c5d0ca07f9742a466f0ad.tar.gz",
|
||||||
.hash = "uucode-0.0.0-ZZjBPpz5OgBrcQOasHVZYLtDHcLPx9al7RH4QXJZ8XCK",
|
.hash = "uucode-0.0.0-ZZjBPn4dOwCKhxEJJqsTGrnmITqhnQvvISkhOXvSHcRE",
|
||||||
},
|
},
|
||||||
.zig_wayland = .{
|
.zig_wayland = .{
|
||||||
// codeberg ifreund/zig-wayland
|
// codeberg ifreund/zig-wayland
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ help_strings: HelpStrings,
|
||||||
metallib: ?*MetallibStep,
|
metallib: ?*MetallibStep,
|
||||||
unicode_tables: UnicodeTables,
|
unicode_tables: UnicodeTables,
|
||||||
framedata: GhosttyFrameData,
|
framedata: GhosttyFrameData,
|
||||||
uucode_table_data: std.Build.LazyPath,
|
uucode_tables_zig: std.Build.LazyPath,
|
||||||
|
|
||||||
/// Used to keep track of a list of file sources.
|
/// Used to keep track of a list of file sources.
|
||||||
pub const LazyPathList = std.ArrayList(std.Build.LazyPath);
|
pub const LazyPathList = std.ArrayList(std.Build.LazyPath);
|
||||||
|
|
@ -26,26 +26,12 @@ pub fn init(b: *std.Build, cfg: *const Config) !SharedDeps {
|
||||||
.help_strings = try .init(b, cfg),
|
.help_strings = try .init(b, cfg),
|
||||||
.unicode_tables = try .init(b),
|
.unicode_tables = try .init(b),
|
||||||
.framedata = try .init(b),
|
.framedata = try .init(b),
|
||||||
.uucode_table_data = b.dependency("uucode", .{
|
.uucode_tables_zig = b.dependency("uucode", .{
|
||||||
// TODO: i'll add a nicer option to configure the tables rather
|
.table_0_fields = @as([]const []const u8, &[_][]const u8{
|
||||||
// than needing to type out the zig code as a string.
|
"general_category",
|
||||||
.@"table_configs.zig" = @as(
|
"has_emoji_presentation",
|
||||||
[]const u8,
|
}),
|
||||||
\\const types = @import("types.zig");
|
}).namedLazyPath("tables.zig"),
|
||||||
\\const config = @import("config.zig");
|
|
||||||
\\
|
|
||||||
\\pub const configs = [_]types.TableConfig{
|
|
||||||
\\ .override(&config.default, .{
|
|
||||||
\\ .fields = &.{
|
|
||||||
\\ "general_category",
|
|
||||||
\\ "has_emoji_presentation",
|
|
||||||
\\ },
|
|
||||||
\\ }),
|
|
||||||
\\};
|
|
||||||
\\
|
|
||||||
,
|
|
||||||
),
|
|
||||||
}).namedLazyPath("table_data.zig"),
|
|
||||||
|
|
||||||
// Setup by retarget
|
// Setup by retarget
|
||||||
.options = undefined,
|
.options = undefined,
|
||||||
|
|
@ -439,7 +425,7 @@ pub fn add(
|
||||||
if (b.lazyDependency("uucode", .{
|
if (b.lazyDependency("uucode", .{
|
||||||
.target = target,
|
.target = target,
|
||||||
.optimize = optimize,
|
.optimize = optimize,
|
||||||
.@"table_data.zig" = self.uucode_table_data,
|
.@"tables.zig" = self.uucode_tables_zig,
|
||||||
})) |dep| {
|
})) |dep| {
|
||||||
step.root_module.addImport("uucode", dep.module("uucode"));
|
step.root_module.addImport("uucode", dep.module("uucode"));
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue