Merge pull request #198051 from sikmir/nanomq

This commit is contained in:
Sandro 2022-11-10 17:05:21 +01:00 committed by GitHub
commit 4f9fa9172c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 38 additions and 0 deletions

View File

@ -0,0 +1,36 @@
{ lib, stdenv, fetchFromGitHub, cmake, ninja, mbedtls, sqlite }:
stdenv.mkDerivation rec {
pname = "nanomq";
version = "0.13.0";
src = fetchFromGitHub {
owner = "emqx";
repo = "nanomq";
rev = version;
hash = "sha256-fxV/X34yohh/bxOsnoVngBKiwqABQDthLgZxvomC0+g=";
fetchSubmodules = true;
};
postPatch = ''
substituteInPlace CMakeLists.txt \
--replace "DESTINATION /etc" "DESTINATION $out/etc"
'';
nativeBuildInputs = [ cmake ninja ];
buildInputs = [ mbedtls sqlite ];
cmakeFlags = [
"-DNNG_ENABLE_TLS=ON"
"-DNNG_ENABLE_SQLITE=ON"
];
meta = with lib; {
description = "An ultra-lightweight and blazing-fast MQTT broker for IoT edge";
homepage = "https://nanomq.io/";
license = licenses.mit;
maintainers = with maintainers; [ sikmir ];
platforms = platforms.unix;
};
}

View File

@ -21339,6 +21339,8 @@ with pkgs;
mosquitto = callPackage ../servers/mqtt/mosquitto { };
nanomq = callPackage ../servers/mqtt/nanomq { };
mps = callPackage ../development/libraries/mps { stdenv = gcc10StdenvCompat; };
libmpeg2 = callPackage ../development/libraries/libmpeg2 { };