-lphp shared not static

This commit is contained in:
Marc 2025-07-24 23:47:01 +07:00 committed by GitHub
parent 8c5dc91895
commit 8ff52e2e36
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -536,13 +536,13 @@ class Extension
$libs = explode(' ', $allLibs);
foreach ($libs as $lib) {
$staticLib = BUILD_LIB_PATH . '/lib' . str_replace('-l', '', $lib) . '.a';
if (file_exists($staticLib)) {
$staticLibString .= " {$lib}";
} else {
if (!file_exists($staticLib) || $lib === '-lphp') {
$sharedLibString .= " {$lib}";
} else {
$staticLibString .= " {$lib}";
}
}
return [$staticLibString, $sharedLibString];
return [trim($staticLibString), trim($sharedLibString)];
}
private function getLibraryDependencies(bool $recursive = false): array