Add more exception and log

This commit is contained in:
crazywhalecc 2025-03-26 12:39:15 +08:00
parent ae23b721b3
commit 8cb93bc1fe
No known key found for this signature in database
GPG Key ID: 1F4BDD59391F2680
2 changed files with 5 additions and 2 deletions

View File

@ -303,6 +303,9 @@ class Extension
public function setBuildStatic(): void
{
if (!in_array('static', Config::getExtTarget($this->name))) {
throw new WrongUsageException("Extension [{$this->name}] does not support static build !");
}
$this->build_static = true;
}

View File

@ -238,8 +238,8 @@ class BuildPHPCommand extends BuildCommand
}
if (!empty($shared_extensions)) {
foreach ($shared_extensions as $ext) {
$path = FileSystem::convertPath("{$build_root_path}/ext/{$ext}.so");
logger()->info("Dynamic extension path{$fixed}: {$path}");
$path = FileSystem::convertPath("{$build_root_path}/lib/{$ext}.so");
logger()->info("Shared extension [{$ext}] path{$fixed}: {$path}");
}
}