diff options
Diffstat (limited to 'lib/std')
| -rw-r--r-- | lib/std/build.zig | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/lib/std/build.zig b/lib/std/build.zig index 869671c785..381488d800 100644 --- a/lib/std/build.zig +++ b/lib/std/build.zig @@ -1262,7 +1262,6 @@ pub const LibExeObjStep = struct { disable_stack_probing: bool, disable_sanitize_c: bool, sanitize_thread: bool, - no_red_zone: bool = false, rdynamic: bool, c_std: Builder.CStd, override_lib_dir: ?[]const u8, @@ -1333,6 +1332,8 @@ pub const LibExeObjStep = struct { /// Position Independent Executable pie: ?bool = null, + red_zone: ?bool = null, + subsystem: ?builtin.SubSystem = null, /// Overrides the default stack size @@ -2261,8 +2262,12 @@ pub const LibExeObjStep = struct { if (self.disable_stack_probing) { try zig_args.append("-fno-stack-check"); } - if (self.no_red_zone) { - try zig_args.append("-fno-red-zone"); + if (self.red_zone) |red_zone| { + if (red_zone) { + try zig_args.append("-mred-zone"); + } else { + try zig_args.append("-mno-red-zone"); + } } if (self.disable_sanitize_c) { try zig_args.append("-fno-sanitize-c"); |
