2023-07-15 17:15:38 +00:00
|
|
|
{ lib, stdenv, buildPecl, valgrind, pcre2, fetchFromGitHub }:
|
2023-01-11 07:51:40 +00:00
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
let
|
2024-01-02 11:29:13 +00:00
|
|
|
version = "22.1.2";
|
2023-01-11 07:51:40 +00:00
|
|
|
in buildPecl {
|
|
|
|
inherit version;
|
|
|
|
pname = "openswoole";
|
2022-04-27 09:35:20 +00:00
|
|
|
|
2023-01-11 07:51:40 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "openswoole";
|
|
|
|
repo = "swoole-src";
|
|
|
|
rev = "v${version}";
|
2024-01-02 11:29:13 +00:00
|
|
|
hash = "sha256-Z26E1PdKypB/MImCHFgA3rJW5LvVaLZsQUxRv0RcFuo=";
|
2023-01-11 07:51:40 +00:00
|
|
|
};
|
2022-04-27 09:35:20 +00:00
|
|
|
|
|
|
|
buildInputs = [ pcre2 ] ++ lib.optionals (!stdenv.isDarwin) [ valgrind ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
2023-01-11 07:51:40 +00:00
|
|
|
changelog = "https://github.com/openswoole/swoole-src/releases/tag/v${version}";
|
2022-04-27 09:35:20 +00:00
|
|
|
description = "Coroutine-based concurrency library and high performance programmatic server for PHP";
|
|
|
|
homepage = "https://www.openswoole.com/";
|
|
|
|
license = licenses.asl20;
|
2022-11-21 17:40:18 +00:00
|
|
|
longDescription = ''
|
|
|
|
Open Swoole allows you to build high-performance, async multi-tasking webservices and applications using an easy to use Coroutine API.\nOpen Swoole is a complete async solution that has built-in support for async programming via coroutines.
|
|
|
|
It offers a range of multi-threaded I/O modules (HTTP Server, WebSockets, TaskWorkers, Process Pools) out of the box and support for popular PHP clients like PDO for MySQL, and CURL.
|
|
|
|
You can use the sync or async, Coroutine API to write whole applications or create thousands of light weight Coroutines within one Linux process.
|
|
|
|
'';
|
2022-04-27 09:35:20 +00:00
|
|
|
maintainers = teams.php.members;
|
|
|
|
};
|
|
|
|
}
|