2021-12-06 16:07:01 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub
|
2023-03-27 19:17:25 +00:00
|
|
|
, cmake
|
2024-04-21 15:54:59 +00:00
|
|
|
, CoreServices
|
2023-02-09 11:40:11 +00:00
|
|
|
, curlHTTP3
|
2021-12-06 16:07:01 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "nghttp3";
|
2024-10-04 16:56:33 +00:00
|
|
|
version = "1.6.0";
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ngtcp2";
|
|
|
|
repo = pname;
|
2022-04-27 09:35:20 +00:00
|
|
|
rev = "v${version}";
|
2024-10-04 16:56:33 +00:00
|
|
|
hash = "sha256-5QsJLN79SkbrCfIGfeJ91AUEf9/V6BWkNE60wOkxdow=";
|
2024-04-21 15:54:59 +00:00
|
|
|
fetchSubmodules = true;
|
2021-12-06 16:07:01 +00:00
|
|
|
};
|
|
|
|
|
2022-06-16 17:23:12 +00:00
|
|
|
outputs = [ "out" "dev" "doc" ];
|
|
|
|
|
2023-03-27 19:17:25 +00:00
|
|
|
nativeBuildInputs = [ cmake ];
|
2024-09-26 11:04:55 +00:00
|
|
|
buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [
|
2024-04-21 15:54:59 +00:00
|
|
|
CoreServices
|
|
|
|
];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
2023-03-27 19:17:25 +00:00
|
|
|
cmakeFlags = [
|
2024-04-21 15:54:59 +00:00
|
|
|
(lib.cmakeBool "ENABLE_STATIC_LIB" false)
|
2023-03-27 19:17:25 +00:00
|
|
|
];
|
2021-12-06 16:07:01 +00:00
|
|
|
|
|
|
|
doCheck = true;
|
|
|
|
|
2023-02-09 11:40:11 +00:00
|
|
|
passthru.tests = {
|
|
|
|
inherit curlHTTP3;
|
|
|
|
};
|
|
|
|
|
2021-12-06 16:07:01 +00:00
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/ngtcp2/nghttp3";
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "nghttp3 is an implementation of HTTP/3 mapping over QUIC and QPACK in C";
|
2021-12-06 16:07:01 +00:00
|
|
|
license = licenses.mit;
|
2022-02-10 20:34:41 +00:00
|
|
|
platforms = platforms.unix;
|
2021-12-06 16:07:01 +00:00
|
|
|
maintainers = with maintainers; [ izorkin ];
|
|
|
|
};
|
|
|
|
}
|