authorgravatar for squeek502@hotmail.comRyan Liptak <squeek502@hotmail.com> 2024-03-23 08:29:18-07:00
committergravatar for ypsvlq@gmail.comElaine Gibson <ypsvlq@gmail.com> 2024-03-27 10:06:06+00:00
log4e428415e575c183050d8108af697ac8aeb9a493
treed2d035b46e7a0f67d6fad82c6b0dbfb833bcd39f
parentadd74427b9adc9e1b0d39a0fba9d001c0953a659

Build.Step.Compile: Add `mingw_unicode_entry_point` field

Corresponds to the `-municode` CLI flag

1 files changed, 7 insertions(+), 0 deletions(-)

lib/std/Build/Step/Compile.zig+7
...@@ -161,6 +161,9 @@ dll_export_fns: ?bool = null,...@@ -161,6 +161,9 @@ dll_export_fns: ?bool = null,
161161
162subsystem: ?std.Target.SubSystem = null,162subsystem: ?std.Target.SubSystem = null,
163163
164/// (Windows) When targeting the MinGW ABI, use the unicode entry point (wmain/wWinMain)
165mingw_unicode_entry_point: bool = false,
166
164/// How the linker must handle the entry point of the executable.167/// How the linker must handle the entry point of the executable.
165entry: Entry = .default,168entry: Entry = .default,
166169
...@@ -1583,6 +1586,10 @@ fn make(step: *Step, prog_node: *std.Progress.Node) !void {...@@ -1583,6 +1586,10 @@ fn make(step: *Step, prog_node: *std.Progress.Node) !void {
1583 });1586 });
1584 }1587 }
15851588
1589 if (self.mingw_unicode_entry_point) {
1590 try zig_args.append("-municode");
1591 }
1592
1586 if (self.error_limit) |err_limit| try zig_args.appendSlice(&.{1593 if (self.error_limit) |err_limit| try zig_args.appendSlice(&.{
1587 "--error-limit",1594 "--error-limit",
1588 b.fmt("{}", .{err_limit}),1595 b.fmt("{}", .{err_limit}),