mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-08 01:15:37 +08:00
sockets doesn't install header?!
This commit is contained in:
21
src/SPC/builder/extension/sockets.php
Normal file
21
src/SPC/builder/extension/sockets.php
Normal file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace SPC\builder\extension;
|
||||
|
||||
use SPC\builder\Extension;
|
||||
use SPC\util\CustomExt;
|
||||
|
||||
#[CustomExt('sockets')]
|
||||
class sockets extends Extension
|
||||
{
|
||||
public function patchBeforeConfigure(): bool
|
||||
{
|
||||
if (file_exists(BUILD_INCLUDE_PATH . 'php/ext/sockets/php_sockets.h')) {
|
||||
return false;
|
||||
}
|
||||
copy(SOURCE_PATH . '/php-src/ext/sockets/php_sockets.h', BUILD_INCLUDE_PATH . 'php/ext/sockets/php_sockets.h');
|
||||
return true;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user