mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-03-18 12:54:52 +08:00
26 lines
558 B
PHP
26 lines
558 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
declare(strict_types=1);
|
||
|
|
|
||
|
|
namespace SPC\builder\extension;
|
||
|
|
|
||
|
|
use SPC\builder\Extension;
|
||
|
|
use SPC\util\CustomExt;
|
||
|
|
|
||
|
|
#[CustomExt('swoole')]
|
||
|
|
class swoole extends Extension
|
||
|
|
{
|
||
|
|
public function getUnixConfigureArg(): string
|
||
|
|
{
|
||
|
|
$arg = '--enable-swoole';
|
||
|
|
if ($this->builder->getLib('openssl')) {
|
||
|
|
$arg .= ' --enable-openssl';
|
||
|
|
} else {
|
||
|
|
$arg .= ' --disable-openssl --without-openssl';
|
||
|
|
}
|
||
|
|
// curl hook is buggy for static php
|
||
|
|
$arg .= ' --disable-swoole-curl';
|
||
|
|
return $arg;
|
||
|
|
}
|
||
|
|
}
|