From c802b44dff608b86d95e5ea3f9c415aebaafc1de Mon Sep 17 00:00:00 2001 From: Laurent Cheylus Date: Sat, 28 Feb 2026 18:26:53 +0100 Subject: [PATCH] fix(loader): link with libc on OpenBSD to compile parser Fix tree-sitter/tree-sitter#5333 Signed-off-by: Laurent Cheylus (cherry picked from commit 2f747dc9b1c795d39b4f211f24a715ea887701b3) --- crates/loader/src/loader.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/crates/loader/src/loader.rs b/crates/loader/src/loader.rs index fa2d9561b..de471e2f6 100644 --- a/crates/loader/src/loader.rs +++ b/crates/loader/src/loader.rs @@ -1193,6 +1193,8 @@ impl Loader { } else { command.arg("-shared"); command.arg("-Wl,--no-undefined"); + #[cfg(target_os = "openbsd")] + command.arg("-lc"); } command.args(cc_config.get_files()); command.arg("-o").arg(output_path);