mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-03-17 20:34:51 +08:00
add patch point for shared ext build
This commit is contained in:
parent
3a17cec521
commit
34910d18e9
@ -401,10 +401,12 @@ class Extension
|
|||||||
if (Config::getExt($this->getName(), 'type') === 'addon') {
|
if (Config::getExt($this->getName(), 'type') === 'addon') {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
$this->builder->emitPatchPoint('before-shared-ext[' . $this->getName() . ']-build');
|
||||||
match (PHP_OS_FAMILY) {
|
match (PHP_OS_FAMILY) {
|
||||||
'Darwin', 'Linux' => $this->buildUnixShared(),
|
'Darwin', 'Linux' => $this->buildUnixShared(),
|
||||||
default => throw new WrongUsageException(PHP_OS_FAMILY . ' build shared extensions is not supported yet'),
|
default => throw new WrongUsageException(PHP_OS_FAMILY . ' build shared extensions is not supported yet'),
|
||||||
};
|
};
|
||||||
|
$this->builder->emitPatchPoint('after-shared-ext[' . $this->getName() . ']-build');
|
||||||
} catch (SPCException $e) {
|
} catch (SPCException $e) {
|
||||||
$e->bindExtensionInfo(['extension_name' => $this->getName()]);
|
$e->bindExtensionInfo(['extension_name' => $this->getName()]);
|
||||||
throw $e;
|
throw $e;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user