push sheeet
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s

This commit is contained in:
Dark Steveneq
2025-10-09 14:15:47 +02:00
commit 646b892680
49168 changed files with 5897842 additions and 0 deletions

View File

@@ -0,0 +1,67 @@
{
lib,
stdenv,
fetchurl,
cmake,
brotli,
libev,
nghttp3,
openssl,
withJemalloc ? false,
jemalloc,
curl,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "ngtcp2";
version = "1.15.1";
src = fetchurl {
url = "https://github.com/ngtcp2/ngtcp2/releases/download/v${finalAttrs.version}/ngtcp2-${finalAttrs.version}.tar.bz2";
hash = "sha256-Bbf6cvldAd3fvDVuHL89VPx1h1wvY2CGW5gIsDNM75c=";
};
outputs = [
"out"
"dev"
"doc"
];
nativeBuildInputs = [ cmake ];
buildInputs = [
brotli
libev
nghttp3
openssl
]
++ lib.optional withJemalloc jemalloc;
cmakeFlags =
if stdenv.hostPlatform.isStatic then
[
# The examples try to link against `ngtcp2_crypto_ossl` and `ngtcp2` libraries.
# This works in the dynamic case where the targets have the same name, but not here where they're suffixed with `_static`.
(lib.cmakeBool "ENABLE_LIB_ONLY" true)
(lib.cmakeBool "ENABLE_SHARED_LIB" false)
(lib.cmakeBool "ENABLE_STATIC_LIB" true)
]
else
[
(lib.cmakeBool "ENABLE_STATIC_LIB" false)
];
doCheck = true;
passthru.tests = {
inherit curl;
};
meta = {
homepage = "https://github.com/ngtcp2/ngtcp2";
changelog = "https://github.com/ngtcp2/ngtcp2/releases/tag/v${finalAttrs.version}";
description = "Implementation of the QUIC protocol (RFC9000)";
license = lib.licenses.mit;
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ izorkin ];
};
})

View File

@@ -0,0 +1,65 @@
{
lib,
stdenv,
fetchFromGitHub,
autoreconfHook,
pkg-config,
gnutls,
cunit,
ncurses,
knot-dns,
}:
stdenv.mkDerivation rec {
pname = "ngtcp2";
version = "1.15.1";
src = fetchFromGitHub {
owner = "ngtcp2";
repo = "ngtcp2";
rev = "v${version}";
hash = "sha256-cXYmnE7WqZulGrLQvjFyHVhCGfxB3nafWKeNugu+zL8=";
};
outputs = [
"out"
"dev"
];
nativeBuildInputs = [
autoreconfHook
pkg-config
];
buildInputs = [ gnutls ];
configureFlags = [ "--with-gnutls=yes" ];
enableParallelBuilding = true;
doCheck = true;
nativeCheckInputs = [ cunit ] ++ lib.optional stdenv.hostPlatform.isDarwin ncurses;
passthru.tests = knot-dns.passthru.tests; # the only consumer so far
meta = with lib; {
homepage = "https://github.com/ngtcp2/ngtcp2";
description = "Effort to implement RFC9000 QUIC protocol";
license = licenses.mit;
platforms = platforms.unix;
maintainers = with maintainers; [
vcunat # for knot-dns
];
};
}
/*
Why split from ./default.nix?
ngtcp2 libs contain helpers to plug into various crypto libs (gnutls, patched openssl, ...).
Building multiple of them while keeping closures separable would be relatively complicated.
Separating the builds is easier for now; the missed opportunity to share the 0.3--0.4 MB
library isn't such a big deal.
Moreover upstream still commonly does incompatible changes, so agreeing
on a single version might be hard sometimes. That's why it seemed simpler
to completely separate the nix expressions, too.
*/