@@ -25,7 +25,7 @@ pub fn build_12(b: *Build) void {
25
25
log .info ("enable TLS support" , .{});
26
26
if (! target .query .isNative ()) {
27
27
log .info ("when enable tls, not support cross compile" , .{});
28
- std .os .exit (1 );
28
+ std .posix .exit (1 );
29
29
}
30
30
}
31
31
@@ -109,7 +109,7 @@ fn build_examples_12(b: *Build, optimize: OptimizeMode, target: Build.ResolvedTa
109
109
var iter_dir =
110
110
std .fs .openDirAbsolute (examples_path , .{ .iterate = true }) catch | err | {
111
111
log .err ("open examples_path failed, err is {}" , .{err });
112
- std .os .exit (1 );
112
+ std .posix .exit (1 );
113
113
};
114
114
defer iter_dir .close ();
115
115
@@ -121,7 +121,7 @@ fn build_examples_12(b: *Build, optimize: OptimizeMode, target: Build.ResolvedTa
121
121
const example_name = entry .name ;
122
122
const path = std .fmt .allocPrint (b .allocator , "src/examples/{s}/main.zig" , .{example_name }) catch | err | {
123
123
log .err ("fmt path for examples failed, err is {}" , .{err });
124
- std .os .exit (1 );
124
+ std .posix .exit (1 );
125
125
};
126
126
127
127
const exe = b .addExecutable (.{
@@ -143,20 +143,20 @@ fn build_examples_12(b: *Build, optimize: OptimizeMode, target: Build.ResolvedTa
143
143
144
144
const cwd = std .fmt .allocPrint (b .allocator , "src/examples/{s}" , .{example_name }) catch | err | {
145
145
log .err ("fmt path for examples failed, err is {}" , .{err });
146
- std .os .exit (1 );
146
+ std .posix .exit (1 );
147
147
};
148
148
exe_run .setCwd (.{
149
149
.path = cwd ,
150
150
});
151
151
152
152
const step_name = std .fmt .allocPrint (b .allocator , "run_{s}" , .{example_name }) catch | err | {
153
153
log .err ("fmt step_name for examples failed, err is {}" , .{err });
154
- std .os .exit (1 );
154
+ std .posix .exit (1 );
155
155
};
156
156
157
157
const step_desc = std .fmt .allocPrint (b .allocator , "run_{s}" , .{example_name }) catch | err | {
158
158
log .err ("fmt step_desc for examples failed, err is {}" , .{err });
159
- std .os .exit (1 );
159
+ std .posix .exit (1 );
160
160
};
161
161
162
162
const exe_run_step = b .step (step_name , step_desc );
@@ -167,6 +167,6 @@ fn build_examples_12(b: *Build, optimize: OptimizeMode, target: Build.ResolvedTa
167
167
}
168
168
} else | err | {
169
169
log .err ("iterate examples_path failed, err is {}" , .{err });
170
- std .os .exit (1 );
170
+ std .posix .exit (1 );
171
171
}
172
172
}
0 commit comments