mirror of
https://github.com/crazywhalecc/static-php-cli.git
synced 2026-07-02 14:25:41 +08:00
Add libssh2
This commit is contained in:
@@ -20,3 +20,5 @@ libssh2:
|
||||
- libssh2
|
||||
static-libs@unix:
|
||||
- libssh2.a
|
||||
static-libs@windows:
|
||||
- libssh2.lib
|
||||
|
||||
@@ -8,10 +8,22 @@ use StaticPHP\Attribute\Package\BuildFor;
|
||||
use StaticPHP\Attribute\Package\Library;
|
||||
use StaticPHP\Package\LibraryPackage;
|
||||
use StaticPHP\Runtime\Executor\UnixCMakeExecutor;
|
||||
use StaticPHP\Runtime\Executor\WindowsCMakeExecutor;
|
||||
|
||||
#[Library('libssh2')]
|
||||
class libssh2
|
||||
{
|
||||
#[BuildFor('Windows')]
|
||||
public function buildWin(LibraryPackage $lib): void
|
||||
{
|
||||
WindowsCMakeExecutor::create($lib)
|
||||
->addConfigureArgs(
|
||||
'-DENABLE_ZLIB_COMPRESSION=ON',
|
||||
'-DBUILD_TESTING=OFF'
|
||||
)
|
||||
->build();
|
||||
}
|
||||
|
||||
#[BuildFor('Linux')]
|
||||
#[BuildFor('Darwin')]
|
||||
public function build(LibraryPackage $lib): void
|
||||
|
||||
Reference in New Issue
Block a user