Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 153 lines 2.7 kB view raw
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 autoconf-archive, 6 autoreconfHook, 7 bison, 8 flex, 9 openssl, 10 libcap, 11 curl, 12 which, 13 eventlog, 14 pkg-config, 15 glib, 16 hiredis, 17 systemd, 18 perl, 19 python3, 20 riemann_c_client, 21 protobufc, 22 paho-mqtt-c, 23 python3Packages, 24 libnet, 25 json_c, 26 libuuid, 27 libivykis, 28 libxslt, 29 docbook_xsl, 30 pcre2, 31 mongoc, 32 rabbitmq-c, 33 libesmtp, 34 rdkafka, 35 gperf, 36 withGrpc ? true, 37 grpc, 38 # see https://github.com/syslog-ng/syslog-ng/pull/5263 39 protobuf_29, 40}: 41let 42 python-deps = 43 ps: with ps; [ 44 boto3 45 botocore 46 cachetools 47 certifi 48 charset-normalizer 49 google-auth 50 idna 51 kubernetes 52 oauthlib 53 pyasn1 54 pyasn1-modules 55 python-dateutil 56 pyyaml 57 requests 58 requests-oauthlib 59 rsa 60 six 61 urllib3 62 websocket-client 63 ply 64 ]; 65 py = python3.withPackages python-deps; 66in 67stdenv.mkDerivation (finalAttrs: { 68 pname = "syslog-ng"; 69 version = "4.9.0"; 70 71 src = fetchFromGitHub { 72 owner = "syslog-ng"; 73 repo = "syslog-ng"; 74 rev = "syslog-ng-${finalAttrs.version}"; 75 hash = "sha256-/hLrUwJhA0jesOl7gmWHfTVO2M7IG8QNPRzc/TIGTH4="; 76 fetchSubmodules = true; 77 }; 78 nativeBuildInputs = [ 79 autoreconfHook 80 autoconf-archive 81 pkg-config 82 which 83 bison 84 flex 85 libxslt 86 perl 87 gperf 88 python3Packages.setuptools 89 ]; 90 91 buildInputs = [ 92 libcap 93 curl 94 openssl 95 eventlog 96 glib 97 py 98 systemd 99 riemann_c_client 100 protobufc 101 libnet 102 json_c 103 libuuid 104 libivykis 105 mongoc 106 rabbitmq-c 107 libesmtp 108 pcre2 109 paho-mqtt-c 110 hiredis 111 rdkafka 112 ] 113 ++ (lib.optionals withGrpc [ 114 protobuf_29 115 grpc 116 ]); 117 118 configureFlags = [ 119 "--enable-manpages" 120 "--with-docbook=${docbook_xsl}/xml/xsl/docbook/manpages/docbook.xsl" 121 "--enable-dynamic-linking" 122 "--enable-systemd" 123 "--enable-smtp" 124 "--with-python-packages=none" 125 "--with-hiredis=system" 126 "--with-ivykis=system" 127 "--with-librabbitmq-client=system" 128 "--with-mongoc=system" 129 "--with-jsonc=system" 130 "--with-systemd-journal=system" 131 "--with-systemdsystemunitdir=$(out)/etc/systemd/system" 132 "--without-compile-date" 133 ] 134 ++ (lib.optionals withGrpc [ "--enable-grpc" ]); 135 136 outputs = [ 137 "out" 138 "man" 139 ]; 140 141 enableParallelBuilding = true; 142 143 meta = { 144 homepage = "https://www.syslog-ng.com"; 145 description = "Next-generation syslogd with advanced networking and filtering capabilities"; 146 license = with lib.licenses; [ 147 gpl2Plus 148 lgpl21Plus 149 ]; 150 maintainers = with lib.maintainers; [ vifino ]; 151 platforms = lib.platforms.linux; 152 }; 153})