| author | |
| committer | |
| log | 57afdfc8fae667e69850650ebb8606805d0d2272 |
| tree | 99bfdad275c3fc0dc00415377ca40f3d577cf89a |
| parent | b1fc3fe1c42d50a40eee985f059a4f43a5f1ce1a |
in whole cache mode, build artifacts are communicated by accessing the
whole cache information, for which there is a helper method called
toCrtFile2 files changed, 2 insertions(+), 17 deletions(-)
src/Compilation.zig+1-11| ... | ... | @@ -2336,11 +2336,6 @@ fn wholeCacheModeSetBinFilePath( |
| 2336 | 2336 | |
| 2337 | 2337 | if (whole.bin_sub_path) |sub_path| { |
| 2338 | 2338 | @memcpy(sub_path[digest_start..][0..digest.len], digest); |
| 2339 | ||
| 2340 | comp.bin_file.?.emit = .{ | |
| 2341 | .directory = comp.local_cache_directory, | |
| 2342 | .sub_path = sub_path, | |
| 2343 | }; | |
| 2344 | 2339 | } |
| 2345 | 2340 | |
| 2346 | 2341 | if (whole.implib_sub_path) |sub_path| { |
| ... | ... | @@ -6243,12 +6238,7 @@ fn buildOutputFromZig( |
| 6243 | 6238 | try comp.updateSubCompilation(sub_compilation, misc_task_tag, prog_node); |
| 6244 | 6239 | |
| 6245 | 6240 | assert(out.* == null); |
| 6246 | out.* = .{ | |
| 6247 | .full_object_path = try sub_compilation.bin_file.?.emit.directory.join(gpa, &.{ | |
| 6248 | sub_compilation.bin_file.?.emit.sub_path, | |
| 6249 | }), | |
| 6250 | .lock = sub_compilation.bin_file.?.toOwnedLock(), | |
| 6251 | }; | |
| 6241 | out.* = try sub_compilation.toCrtFile(); | |
| 6252 | 6242 | } |
| 6253 | 6243 | |
| 6254 | 6244 | pub fn build_crt_file( |
src/musl.zig+1-6| ... | ... | @@ -276,12 +276,7 @@ pub fn buildCRTFile(comp: *Compilation, crt_file: CRTFile, prog_node: *std.Progr |
| 276 | 276 | const basename = try comp.gpa.dupe(u8, "libc.so"); |
| 277 | 277 | errdefer comp.gpa.free(basename); |
| 278 | 278 | |
| 279 | comp.crt_files.putAssumeCapacityNoClobber(basename, .{ | |
| 280 | .full_object_path = try sub_compilation.bin_file.?.emit.directory.join(comp.gpa, &.{ | |
| 281 | sub_compilation.bin_file.?.emit.sub_path, | |
| 282 | }), | |
| 283 | .lock = sub_compilation.bin_file.?.toOwnedLock(), | |
| 284 | }); | |
| 279 | comp.crt_files.putAssumeCapacityNoClobber(basename, try sub_compilation.toCrtFile()); | |
| 285 | 280 | }, |
| 286 | 281 | } |
| 287 | 282 | } |