Skip to content

Commit 79c2ceb

Browse files
committed
build: findLLVM correctly handles system libraries
1 parent e0a1466 commit 79c2ceb

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

build.zig

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,11 @@ fn findLLVM(b: &Builder) -> ?LibraryDep {
128128
if (mem.startsWith(u8, lib_arg, "-l")) {
129129
%%result.system_libs.append(lib_arg[2..]);
130130
} else {
131-
%%result.libs.append(lib_arg);
131+
if (os.path.isAbsolute(lib_arg)) {
132+
%%result.libs.append(lib_arg);
133+
} else {
134+
%%result.system_libs.append(lib_arg);
135+
}
132136
}
133137
}
134138
}

0 commit comments

Comments
 (0)