diff options
| author | 2024-02-27 11:16:41 -0400 | |
|---|---|---|
| committer | 2024-02-27 11:16:41 -0400 | |
| commit | f6418d582fc2294983bfa647c7148a263af13db5 (patch) | |
| tree | 8f05af609928553bd91c61c31580d78a0de68736 /build.zig | |
| parent | Removed equality functions from Normalizer (diff) | |
| download | zg-f6418d582fc2294983bfa647c7148a263af13db5.tar.gz zg-f6418d582fc2294983bfa647c7148a263af13db5.tar.xz zg-f6418d582fc2294983bfa647c7148a263af13db5.zip | |
Using NormPropsData in NormData; No Ziglyph deps in NOrmalizer
Diffstat (limited to 'build.zig')
| -rw-r--r-- | build.zig | 19 |
1 files changed, 18 insertions, 1 deletions
| @@ -61,6 +61,15 @@ pub fn build(b: *std.Build) void { | |||
| 61 | const run_hangul_gen_exe = b.addRunArtifact(hangul_gen_exe); | 61 | const run_hangul_gen_exe = b.addRunArtifact(hangul_gen_exe); |
| 62 | const hangul_gen_out = run_hangul_gen_exe.addOutputFileArg("hangul.bin.z"); | 62 | const hangul_gen_out = run_hangul_gen_exe.addOutputFileArg("hangul.bin.z"); |
| 63 | 63 | ||
| 64 | const normp_gen_exe = b.addExecutable(.{ | ||
| 65 | .name = "normp", | ||
| 66 | .root_source_file = .{ .path = "codegen/normp.zig" }, | ||
| 67 | .target = b.host, | ||
| 68 | .optimize = .Debug, | ||
| 69 | }); | ||
| 70 | const run_normp_gen_exe = b.addRunArtifact(normp_gen_exe); | ||
| 71 | const normp_gen_out = run_normp_gen_exe.addOutputFileArg("normp.bin.z"); | ||
| 72 | |||
| 64 | const ccc_gen_exe = b.addExecutable(.{ | 73 | const ccc_gen_exe = b.addExecutable(.{ |
| 65 | .name = "ccc", | 74 | .name = "ccc", |
| 66 | .root_source_file = .{ .path = "codegen/ccc.zig" }, | 75 | .root_source_file = .{ .path = "codegen/ccc.zig" }, |
| @@ -149,6 +158,13 @@ pub fn build(b: *std.Build) void { | |||
| 149 | }); | 158 | }); |
| 150 | hangul_data.addAnonymousImport("hangul", .{ .root_source_file = hangul_gen_out }); | 159 | hangul_data.addAnonymousImport("hangul", .{ .root_source_file = hangul_gen_out }); |
| 151 | 160 | ||
| 161 | const normp_data = b.createModule(.{ | ||
| 162 | .root_source_file = .{ .path = "src/NormPropsData.zig" }, | ||
| 163 | .target = target, | ||
| 164 | .optimize = optimize, | ||
| 165 | }); | ||
| 166 | normp_data.addAnonymousImport("normp", .{ .root_source_file = normp_gen_out }); | ||
| 167 | |||
| 152 | const norm_data = b.createModule(.{ | 168 | const norm_data = b.createModule(.{ |
| 153 | .root_source_file = .{ .path = "src/NormData.zig" }, | 169 | .root_source_file = .{ .path = "src/NormData.zig" }, |
| 154 | .target = target, | 170 | .target = target, |
| @@ -158,6 +174,7 @@ pub fn build(b: *std.Build) void { | |||
| 158 | norm_data.addImport("CombiningData", ccc_data); | 174 | norm_data.addImport("CombiningData", ccc_data); |
| 159 | norm_data.addImport("CompatData", compat_data); | 175 | norm_data.addImport("CompatData", compat_data); |
| 160 | norm_data.addImport("HangulData", hangul_data); | 176 | norm_data.addImport("HangulData", hangul_data); |
| 177 | norm_data.addImport("NormPropsData", normp_data); | ||
| 161 | 178 | ||
| 162 | const norm = b.addModule("Normalizer", .{ | 179 | const norm = b.addModule("Normalizer", .{ |
| 163 | .root_source_file = .{ .path = "src/Normalizer.zig" }, | 180 | .root_source_file = .{ .path = "src/Normalizer.zig" }, |
| @@ -200,7 +217,7 @@ pub fn build(b: *std.Build) void { | |||
| 200 | exe_unit_tests.root_module.addImport("code_point", code_point); | 217 | exe_unit_tests.root_module.addImport("code_point", code_point); |
| 201 | // exe_unit_tests.root_module.addImport("GraphemeData", grapheme_data); | 218 | // exe_unit_tests.root_module.addImport("GraphemeData", grapheme_data); |
| 202 | // exe_unit_tests.root_module.addImport("grapheme", grapheme); | 219 | // exe_unit_tests.root_module.addImport("grapheme", grapheme); |
| 203 | exe_unit_tests.root_module.addImport("ziglyph", ziglyph.module("ziglyph")); | 220 | // exe_unit_tests.root_module.addImport("ziglyph", ziglyph.module("ziglyph")); |
| 204 | // exe_unit_tests.root_module.addAnonymousImport("normp", .{ .root_source_file = normp_gen_out }); | 221 | // exe_unit_tests.root_module.addAnonymousImport("normp", .{ .root_source_file = normp_gen_out }); |
| 205 | // exe_unit_tests.root_module.addImport("DisplayWidthData", dw_data); | 222 | // exe_unit_tests.root_module.addImport("DisplayWidthData", dw_data); |
| 206 | exe_unit_tests.root_module.addImport("NormData", norm_data); | 223 | exe_unit_tests.root_module.addImport("NormData", norm_data); |