mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-03-18 12:54:52 +08:00
Merge branch 'crazywhalecc:refactor' into refactor
This commit is contained in:
commit
0b3aefaefe
17
src/SPC/builder/extension/opcache.php
Normal file
17
src/SPC/builder/extension/opcache.php
Normal file
@ -0,0 +1,17 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace SPC\builder\extension;
|
||||
|
||||
use SPC\builder\Extension;
|
||||
use SPC\util\CustomExt;
|
||||
|
||||
#[CustomExt('opcache')]
|
||||
class opcache extends Extension
|
||||
{
|
||||
public function getDistName(): string
|
||||
{
|
||||
return 'Zend Opcache';
|
||||
}
|
||||
}
|
||||
@ -72,7 +72,7 @@ trait UnixBuilderTrait
|
||||
}
|
||||
foreach ($this->exts as $ext) {
|
||||
logger()->debug('testing ext: ' . $ext->getName());
|
||||
[$ret] = shell()->execWithResult(BUILD_ROOT_PATH . '/bin/php --ri ' . $ext->getDistName(), false);
|
||||
[$ret] = shell()->execWithResult(BUILD_ROOT_PATH . '/bin/php --ri "' . $ext->getDistName() . '"', false);
|
||||
if ($ret !== 0) {
|
||||
throw new RuntimeException('extension ' . $ext->getName() . ' failed compile check');
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user