@@ -17,7 +17,7 @@ pub fn build(b: *Builder) !void {
17
17
18
18
const rel_zig_exe = try os .path .relative (b .allocator , b .build_root , b .zig_exe );
19
19
const langref_out_path = os .path .join (b .allocator , b .cache_root , "langref.html" ) catch unreachable ;
20
- var docgen_cmd = b .addCommand (null , b .env_map , [][]const u8 {
20
+ var docgen_cmd = b .addCommand (null , b .env_map , [][]const u8 . {
21
21
docgen_exe .getOutputPath (),
22
22
rel_zig_exe ,
23
23
"doc" ++ os .path .sep_str ++ "langref.html.in" ,
@@ -31,12 +31,12 @@ pub fn build(b: *Builder) !void {
31
31
const test_step = b .step ("test" , "Run all the tests" );
32
32
33
33
// find the stage0 build artifacts because we're going to re-use config.h and zig_cpp library
34
- const build_info = try b .exec ([][]const u8 {
34
+ const build_info = try b .exec ([][]const u8 . {
35
35
b .zig_exe ,
36
36
"BUILD_INFO" ,
37
37
});
38
38
var index : usize = 0 ;
39
- var ctx = Context {
39
+ var ctx = Context. {
40
40
.cmake_binary_dir = nextValue (& index , build_info ),
41
41
.cxx_compiler = nextValue (& index , build_info ),
42
42
.llvm_config_exe = nextValue (& index , build_info ),
@@ -141,29 +141,29 @@ fn addCppLib(b: *Builder, lib_exe_obj: var, cmake_binary_dir: []const u8, lib_na
141
141
lib_exe_obj .addObjectFile (os .path .join (b .allocator , cmake_binary_dir , "zig_cpp" , b .fmt ("{}{}{}" , lib_prefix , lib_name , lib_exe_obj .target .libFileExt ())) catch unreachable );
142
142
}
143
143
144
- const LibraryDep = struct {
144
+ const LibraryDep = struct . {
145
145
libdirs : ArrayList ([]const u8 ),
146
146
libs : ArrayList ([]const u8 ),
147
147
system_libs : ArrayList ([]const u8 ),
148
148
includes : ArrayList ([]const u8 ),
149
149
};
150
150
151
151
fn findLLVM (b : * Builder , llvm_config_exe : []const u8 ) ! LibraryDep {
152
- const libs_output = try b .exec ([][]const u8 {
152
+ const libs_output = try b .exec ([][]const u8 . {
153
153
llvm_config_exe ,
154
154
"--libs" ,
155
155
"--system-libs" ,
156
156
});
157
- const includes_output = try b .exec ([][]const u8 {
157
+ const includes_output = try b .exec ([][]const u8 . {
158
158
llvm_config_exe ,
159
159
"--includedir" ,
160
160
});
161
- const libdir_output = try b .exec ([][]const u8 {
161
+ const libdir_output = try b .exec ([][]const u8 . {
162
162
llvm_config_exe ,
163
163
"--libdir" ,
164
164
});
165
165
166
- var result = LibraryDep {
166
+ var result = LibraryDep. {
167
167
.libs = ArrayList ([]const u8 ).init (b .allocator ),
168
168
.system_libs = ArrayList ([]const u8 ).init (b .allocator ),
169
169
.includes = ArrayList ([]const u8 ).init (b .allocator ),
@@ -268,7 +268,7 @@ fn configureStage2(b: *Builder, exe: var, ctx: Context) !void {
268
268
dependOnLib (exe , ctx .llvm );
269
269
270
270
if (exe .target .getOs () == builtin .Os .linux ) {
271
- const libstdcxx_path_padded = try b .exec ([][]const u8 {
271
+ const libstdcxx_path_padded = try b .exec ([][]const u8 . {
272
272
ctx .cxx_compiler ,
273
273
"-print-file-name=libstdc++.a" ,
274
274
});
@@ -298,7 +298,7 @@ fn configureStage2(b: *Builder, exe: var, ctx: Context) !void {
298
298
exe .linkSystemLibrary ("c" );
299
299
}
300
300
301
- const Context = struct {
301
+ const Context = struct . {
302
302
cmake_binary_dir : []const u8 ,
303
303
cxx_compiler : []const u8 ,
304
304
llvm_config_exe : []const u8 ,
0 commit comments