| ... | @@ -1383,8 +1383,15 @@ pub fn flushModule(self: *Elf, comp: *Compilation, prog_node: *std.Progress.Node | ... | @@ -1383,8 +1383,15 @@ pub fn flushModule(self: *Elf, comp: *Compilation, prog_node: *std.Progress.Node |
| 1383 | // libc dep | 1383 | // libc dep |
| 1384 | self.error_flags.missing_libc = false; | 1384 | self.error_flags.missing_libc = false; |
| 1385 | if (self.base.options.link_libc) { | 1385 | if (self.base.options.link_libc) { |
| 1386 | if (self.base.options.libc_installation != null) { | 1386 | if (self.base.options.libc_installation) |lc| { |
| 1387 | @panic("TODO explicit libc_installation"); | 1387 | const flags = target_util.libcFullLinkFlags(target); |
| | 1388 | try system_libs.ensureUnusedCapacity(flags.len); |
| | 1389 | for (flags) |flag| { |
| | 1390 | const lib_path = try std.fmt.allocPrint(arena, "{s}{c}lib{s}.so", .{ |
| | 1391 | lc.crt_dir.?, fs.path.sep, flag["-l".len..], |
| | 1392 | }); |
| | 1393 | system_libs.appendAssumeCapacity(.{ .path = lib_path }); |
| | 1394 | } |
| 1388 | } else if (target.isGnuLibC()) { | 1395 | } else if (target.isGnuLibC()) { |
| 1389 | try system_libs.ensureUnusedCapacity(glibc.libs.len + 1); | 1396 | try system_libs.ensureUnusedCapacity(glibc.libs.len + 1); |
| 1390 | for (glibc.libs) |lib| { | 1397 | for (glibc.libs) |lib| { |