authorgravatar for michaldrozd@protonmail.chfardragon <michaldrozd@protonmail.ch> 2026-05-31 10:01:33+00:00
committergravatar for michaldrozd@protonmail.chfardragon <michaldrozd@protonmail.ch> 2026-06-05 14:59:18+02:00
loga608ecd335df46b7d13dfaef3372b1120b774921
treeab6a17365e0dfb6bdcc0c93263b7af76ae6f1d35
parent5434f85c47f6412a8d5faf681419c15533bb388c

Fix config_header build.zig


1 files changed, 22 insertions(+), 1 deletions(-)

test/standalone/config_header/build.zig+22-1
......@@ -1,6 +1,9 @@
11const std = @import("std");
22
33pub fn build(b: *std.Build) void {
4 const test_step = b.step("test", "Test it");
5 b.default_step = test_step;
6
47 const config_header = b.addConfigHeader(
58 .{ .style = .{ .autoconf_undef = b.path("config.h.in") } },
69 .{
......@@ -23,6 +26,24 @@ pub fn build(b: *std.Build) void {
2326
2427 const check_config_header = b.addCheckFile(config_header.getOutputFile(), .{ .expected_exact = @embedFile("config.h") });
2528
26 const test_step = b.step("test", "Test it");
29 const config_header_autoconf_at = b.addConfigHeader(
30 .{ .style = .{
31 .autoconf_at = b.path("autoconf_at/autoconf_at.txt.in"),
32 } },
33 .{
34 .undefined = null,
35 .defined = {},
36 .boolean_true = true,
37 .boolean_false = false,
38 .integer = 42,
39 .string = "text",
40 .string_at = "@string@",
41 },
42 );
43 const check_config_header_autoconf_at = b.addCheckFile(config_header_autoconf_at.getOutputFile(), .{
44 .expected_exact = @embedFile("autoconf_at/autoconf_at.txt"),
45 });
46
2747 test_step.dependOn(&check_config_header.step);
48 test_step.dependOn(&check_config_header_autoconf_at.step);
2849}