aboutsummaryrefslogtreecommitdiff
path: root/src/link.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/link.cpp')
-rw-r--r--src/link.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/link.cpp b/src/link.cpp
index 424b06169e..613768cec8 100644
--- a/src/link.cpp
+++ b/src/link.cpp
@@ -150,6 +150,10 @@ static const char *getLDMOption(const ZigTarget *t) {
if (t->env_type == ZigLLVM_GNUX32) {
return "elf32_x86_64";
}
+ // Any target elf will use the freebsd osabi if suffixed with "_fbsd".
+ if (t->os == OsFreeBSD) {
+ return "elf_x86_64_fbsd";
+ }
return "elf_x86_64";
default:
zig_unreachable();