Revert "Change oniguruma link target from `oniguruma` to `onig`" to prefer using pkg-config (#2939)

This reverts commit daa0fe00b1. It is
correct to use the pkg-config name instead of the literal dylib name.
Sorry I didn't know about pkg-config needing to be installed at the time
and zig searching for the lib directly as a fallback
pull/2938/head^2
Mitchell Hashimoto 2024-12-12 06:31:49 -08:00 committed by GitHub
commit 1587cf5657
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 2 deletions

View File

@ -1120,8 +1120,7 @@ fn addDeps(
});
step.root_module.addImport("oniguruma", oniguruma_dep.module("oniguruma"));
if (b.systemIntegrationOption("oniguruma", .{})) {
// Oniguruma is compiled and distributed as libonig.so
step.linkSystemLibrary2("onig", dynamic_link_opts);
step.linkSystemLibrary2("oniguruma", dynamic_link_opts);
} else {
step.linkLibrary(oniguruma_dep.artifact("oniguruma"));
try static_libs.append(oniguruma_dep.artifact("oniguruma").getEmittedBin());