summary refs log tree commit diff
path: root/pkgs/tools/system/syslog-ng/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/tools/system/syslog-ng/default.nix')
-rw-r--r--pkgs/tools/system/syslog-ng/default.nix87
1 files changed, 73 insertions, 14 deletions
diff --git a/pkgs/tools/system/syslog-ng/default.nix b/pkgs/tools/system/syslog-ng/default.nix
index b19cbde0aa5..f511323f9e5 100644
--- a/pkgs/tools/system/syslog-ng/default.nix
+++ b/pkgs/tools/system/syslog-ng/default.nix
@@ -1,20 +1,73 @@
-{ lib, stdenv, fetchurl, openssl, libcap, curl, which
-, eventlog, pkg-config, glib, python3, systemd, perl
-, riemann_c_client, protobufc, pcre, libnet
-, json_c, libuuid, libivykis, mongoc, rabbitmq-c
+{ lib
+, stdenv
+, fetchFromGitHub
+, autoconf-archive
+, autoreconfHook
+, bison
+, flex
+, openssl
+, libcap
+, curl
+, which
+, eventlog
+, pkg-config
+, glib
+, hiredis
+, systemd
+, perl
+, python3
+, riemann_c_client
+, protobufc
+, pcre
+, paho-mqtt-c
+, libnet
+, json_c
+, libuuid
+, libivykis
+, libxslt
+, docbook_xsl
+, pcre2
+, mongoc
+, rabbitmq-c
 , libesmtp
+, rdkafka
 }:
-
+let
+  python-deps = ps: with ps; [
+    boto3
+    botocore
+    cachetools
+    certifi
+    charset-normalizer
+    google-auth
+    idna
+    kubernetes
+    oauthlib
+    pyasn1
+    pyasn1-modules
+    python-dateutil
+    pyyaml
+    requests
+    requests-oauthlib
+    rsa
+    six
+    urllib3
+    websocket-client
+    ply
+  ];
+  py = python3.withPackages python-deps;
+in
 stdenv.mkDerivation rec {
   pname = "syslog-ng";
-  version = "3.38.1";
+  version = "4.4.0";
 
-  src = fetchurl {
-    url = "https://github.com/${pname}/${pname}/releases/download/${pname}-${version}/${pname}-${version}.tar.gz";
-    sha256 = "sha256-VJH2htC4KbabLg/A1mpi9RmRqvruAFR1v6OPqzmUQfc=";
+  src = fetchFromGitHub {
+    owner = "syslog-ng";
+    repo = "syslog-ng";
+    rev = "syslog-ng-${version}";
+    hash = "sha256-NXwd4dyPfnHO3yjl3GPAMQYqenfpp7xFOil2G1e66w4=";
   };
-
-  nativeBuildInputs = [ pkg-config which ];
+  nativeBuildInputs = [ autoreconfHook autoconf-archive pkg-config which bison flex libxslt perl ];
 
   buildInputs = [
     libcap
@@ -22,8 +75,7 @@ stdenv.mkDerivation rec {
     openssl
     eventlog
     glib
-    perl
-    python3
+    py
     systemd
     riemann_c_client
     protobufc
@@ -35,13 +87,20 @@ stdenv.mkDerivation rec {
     mongoc
     rabbitmq-c
     libesmtp
+    pcre2
+    paho-mqtt-c
+    hiredis
+    rdkafka
   ];
 
   configureFlags = [
     "--enable-manpages"
+    "--with-docbook=${docbook_xsl}/xml/xsl/docbook/manpages/docbook.xsl"
     "--enable-dynamic-linking"
     "--enable-systemd"
     "--enable-smtp"
+    "--with-python-packages=none"
+    "--with-hiredis=system"
     "--with-ivykis=system"
     "--with-librabbitmq-client=system"
     "--with-mongoc=system"
@@ -59,7 +118,7 @@ stdenv.mkDerivation rec {
     homepage = "https://www.syslog-ng.com";
     description = "Next-generation syslogd with advanced networking and filtering capabilities";
     license = with licenses; [ gpl2Plus lgpl21Plus ];
-    maintainers = with maintainers; [ ];
+    maintainers = with maintainers; [ vifino ];
     platforms = platforms.linux;
   };
 }