diff options
author | Alyssa Ross <hi@alyssa.is> | 2023-06-16 06:56:35 +0000 |
---|---|---|
committer | Alyssa Ross <hi@alyssa.is> | 2023-06-16 06:56:35 +0000 |
commit | 99fcaeccb89621dd492203ce1f2d551c06f228ed (patch) | |
tree | 41cb730ae07383004789779b0f6e11cb3f4642a3 /nixpkgs/pkgs/development/libraries/ngtcp2 | |
parent | 59c5f5ac8682acc13bb22bc29c7cf02f7d75f01f (diff) | |
parent | 75a5ebf473cd60148ba9aec0d219f72e5cf52519 (diff) | |
download | nixlib-99fcaeccb89621dd492203ce1f2d551c06f228ed.tar nixlib-99fcaeccb89621dd492203ce1f2d551c06f228ed.tar.gz nixlib-99fcaeccb89621dd492203ce1f2d551c06f228ed.tar.bz2 nixlib-99fcaeccb89621dd492203ce1f2d551c06f228ed.tar.lz nixlib-99fcaeccb89621dd492203ce1f2d551c06f228ed.tar.xz nixlib-99fcaeccb89621dd492203ce1f2d551c06f228ed.tar.zst nixlib-99fcaeccb89621dd492203ce1f2d551c06f228ed.zip |
Merge branch 'nixos-unstable' of https://github.com/NixOS/nixpkgs
Conflicts: nixpkgs/nixos/modules/config/console.nix nixpkgs/nixos/modules/services/mail/mailman.nix nixpkgs/nixos/modules/services/mail/public-inbox.nix nixpkgs/nixos/modules/services/mail/rss2email.nix nixpkgs/nixos/modules/services/networking/ssh/sshd.nix nixpkgs/pkgs/applications/networking/instant-messengers/dino/default.nix nixpkgs/pkgs/applications/networking/irc/weechat/default.nix nixpkgs/pkgs/applications/window-managers/sway/default.nix nixpkgs/pkgs/build-support/go/module.nix nixpkgs/pkgs/build-support/rust/build-rust-package/default.nix nixpkgs/pkgs/development/interpreters/python/default.nix nixpkgs/pkgs/development/node-packages/overrides.nix nixpkgs/pkgs/development/tools/b4/default.nix nixpkgs/pkgs/servers/dict/dictd-db.nix nixpkgs/pkgs/servers/mail/public-inbox/default.nix nixpkgs/pkgs/tools/security/pinentry/default.nix nixpkgs/pkgs/tools/text/unoconv/default.nix nixpkgs/pkgs/top-level/all-packages.nix
Diffstat (limited to 'nixpkgs/pkgs/development/libraries/ngtcp2')
-rw-r--r-- | nixpkgs/pkgs/development/libraries/ngtcp2/default.nix | 23 | ||||
-rw-r--r-- | nixpkgs/pkgs/development/libraries/ngtcp2/gnutls.nix | 53 |
2 files changed, 67 insertions, 9 deletions
diff --git a/nixpkgs/pkgs/development/libraries/ngtcp2/default.nix b/nixpkgs/pkgs/development/libraries/ngtcp2/default.nix index 90372cc97a26..e85a7674a263 100644 --- a/nixpkgs/pkgs/development/libraries/ngtcp2/default.nix +++ b/nixpkgs/pkgs/development/libraries/ngtcp2/default.nix @@ -1,34 +1,39 @@ { lib, stdenv, fetchFromGitHub -, autoreconfHook, pkg-config, file -, libev, nghttp3, quictls +, cmake , cunit, ncurses +, libev, nghttp3, quictls , withJemalloc ? false, jemalloc +, curlHTTP3 }: stdenv.mkDerivation rec { pname = "ngtcp2"; - version = "0.7.0"; + version = "0.15.0"; src = fetchFromGitHub { owner = "ngtcp2"; repo = pname; rev = "v${version}"; - sha256 = "sha256-REAN5TW0miWXI3HFxtW3znTKTrhsBbNqu1VfjC2w0no="; + hash = "sha256-FWNWpRuCUyqTIyLZkBFKrd2urjSCqHp20mBAXOcJm14="; }; outputs = [ "out" "dev" "doc" ]; - nativeBuildInputs = [ autoreconfHook pkg-config file ]; + nativeBuildInputs = [ cmake ]; + nativeCheckInputs = [ cunit ncurses ]; buildInputs = [ libev nghttp3 quictls ] ++ lib.optional withJemalloc jemalloc; - checkInputs = [ cunit ncurses ]; - preConfigure = '' - substituteInPlace ./configure --replace /usr/bin/file ${file}/bin/file - ''; + cmakeFlags = [ + "-DENABLE_STATIC_LIB=OFF" + ]; doCheck = true; enableParallelBuilding = true; + passthru.tests = { + inherit curlHTTP3; + }; + meta = with lib; { homepage = "https://github.com/ngtcp2/ngtcp2"; description = "ngtcp2 project is an effort to implement QUIC protocol which is now being discussed in IETF QUICWG for its standardization."; diff --git a/nixpkgs/pkgs/development/libraries/ngtcp2/gnutls.nix b/nixpkgs/pkgs/development/libraries/ngtcp2/gnutls.nix new file mode 100644 index 000000000000..f19672e566d1 --- /dev/null +++ b/nixpkgs/pkgs/development/libraries/ngtcp2/gnutls.nix @@ -0,0 +1,53 @@ +{ lib, stdenv, fetchFromGitHub +, autoreconfHook, pkg-config +, gnutls +, cunit, ncurses, knot-dns +}: + +stdenv.mkDerivation rec { + pname = "ngtcp2"; + version = "0.13.1"; + + src = fetchFromGitHub { + owner = "ngtcp2"; + repo = "ngtcp2"; + rev = "v${version}"; + sha256 = "sha256-bkTbnf7vyTxA623JVGUgrwAuXK7d8kzijOK1F4Sh4yY="; + }; + + outputs = [ "out" "dev" ]; + + nativeBuildInputs = [ autoreconfHook pkg-config ]; + buildInputs = [ gnutls ]; + + configureFlags = [ "--with-gnutls=yes" ]; + enableParallelBuilding = true; + + doCheck = true; + nativeCheckInputs = [ cunit ] + ++ lib.optional stdenv.isDarwin ncurses; + + passthru.tests = knot-dns.passthru.tests; # the only consumer so far + + meta = with lib; { + homepage = "https://github.com/ngtcp2/ngtcp2"; + description = "an 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. +*/ + |