fix xz shared build

This commit is contained in:
henderkes
2026-02-20 13:05:49 +07:00
parent fa670cce4a
commit 17d699d4a5
2 changed files with 9 additions and 2 deletions

View File

@@ -283,7 +283,7 @@ class SPCConfigUtil
$libs = array_reverse(Config::getLib($library, 'static-libs', []));
foreach ($libs as $lib) {
// check file existence
if (!file_exists(BUILD_LIB_PATH . "/{$lib}")) {
if (!file_exists(BUILD_LIB_PATH . "/{$lib}") && getenv('SPC_LINK_STATIC')) {
throw new WrongUsageException("Library file '{$lib}' for lib [{$library}] does not exist in '" . BUILD_LIB_PATH . "'. Please build it first.");
}
$lib_names[] = $this->getShortLibName($lib);