From 80a9f0b9426e235d602136cb9bedf0177edc0c7d Mon Sep 17 00:00:00 2001 From: Michael Dusan Date: Thu, 9 Jan 2025 22:48:09 -0500 Subject: [PATCH] bsd: fix stage3 linking on freebsd and dragonfly --- src/target.zig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/target.zig b/src/target.zig index 087f5d2d10..d67fc797ce 100644 --- a/src/target.zig +++ b/src/target.zig @@ -324,7 +324,7 @@ pub fn libcFullLinkFlags(target: std.Target) []const []const u8 { // The linking order of these is significant and should match the order other // c compilers such as gcc or clang use. const result: []const []const u8 = switch (target.os.tag) { - .netbsd, .openbsd => &.{ "-lm", "-lpthread", "-lc", "-lutil" }, + .dragonfly, .freebsd, .netbsd, .openbsd => &.{ "-lm", "-lpthread", "-lc", "-lutil" }, // Solaris releases after 10 merged the threading libraries into libc. .solaris, .illumos => &.{ "-lm", "-lsocket", "-lnsl", "-lc" }, .haiku => &.{ "-lm", "-lroot", "-lpthread", "-lc", "-lnetwork" },