nng: added tls and mbedtls support (#188668)
This commit is contained in:
parent
b03c796395
commit
376fcb9dce
2 changed files with 14 additions and 3 deletions
|
@ -9686,6 +9686,12 @@
|
|||
github = "numkem";
|
||||
githubId = 332423;
|
||||
};
|
||||
nviets = {
|
||||
email = "nathan.g.viets@gmail.com";
|
||||
github = "nviets";
|
||||
githubId = 16027994;
|
||||
name = "Nathan Viets";
|
||||
};
|
||||
nyanloutre = {
|
||||
email = "paul@nyanlout.re";
|
||||
github = "nyanloutre";
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ lib, stdenv, fetchFromGitHub, cmake, ninja }:
|
||||
{ lib, stdenv, fetchFromGitHub, cmake, ninja, mbedtlsSupport ? true, mbedtls }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "nng";
|
||||
|
@ -11,9 +11,13 @@ stdenv.mkDerivation rec {
|
|||
sha256 = "sha256-qbjMLpPk5FxH710Mf8AIraY0mERbaxVVhTT94W0EV+k=";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [ cmake ninja ];
|
||||
nativeBuildInputs = [ cmake ninja ]
|
||||
++ lib.optionals mbedtlsSupport [ mbedtls ];
|
||||
|
||||
cmakeFlags = [ "-G Ninja" ];
|
||||
buildInputs = lib.optional mbedtlsSupport [ mbedtls ];
|
||||
|
||||
cmakeFlags = [ "-G Ninja" "-DNNG_ENABLE_TLS=ON" ]
|
||||
++ lib.optionals mbedtlsSupport [ "-DMBEDTLS_ROOT_DIR=${mbedtls}" ];
|
||||
|
||||
meta = with lib; {
|
||||
homepage = "https://nng.nanomsg.org/";
|
||||
|
@ -21,5 +25,6 @@ stdenv.mkDerivation rec {
|
|||
license = licenses.mit;
|
||||
mainProgram = "nngcat";
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ nviets ];
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue