mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-08 01:15:37 +08:00
add ext-gearman
This commit is contained in:
20
src/Package/Extension/gearman.php
Normal file
20
src/Package/Extension/gearman.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Package\Extension;
|
||||
|
||||
use StaticPHP\Attribute\Package\CustomPhpConfigureArg;
|
||||
use StaticPHP\Attribute\Package\Extension;
|
||||
use StaticPHP\Package\PackageInstaller;
|
||||
|
||||
#[Extension('gearman')]
|
||||
class gearman
|
||||
{
|
||||
#[CustomPhpConfigureArg('Linux')]
|
||||
#[CustomPhpConfigureArg('Darwin')]
|
||||
public function getUnixConfigureArg(bool $shared, PackageInstaller $installer): string
|
||||
{
|
||||
return '--with-gearman=' . ($shared ? 'shared,' : '') . $installer->getLibraryPackage('libgearman')->getBuildRootPath();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user