projects/guix·blob python-team · refs

454 lines · 16.2 KiB

1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2016, 2022 Ricardo Wurmus <[email protected]>
3;;; Copyright © 2016, 2017, 2018, 2026 Ludovic Courtès <[email protected]>
4;;; Copyright © 2017 Stefan Reichör <[email protected]>
5;;; Copyright © 2017 Eric Bavier <[email protected]>
6;;; Copyright © 2018–2022 Tobias Geerinckx-Rice <[email protected]>
7;;; Copyright © 2019 Gábor Boskovits <[email protected]>
8;;; Copyright © 2019 Meiyo Peng <[email protected]>
9;;; Copyright © 2020 Marius Bakke <[email protected]>
10;;; Copyright © 2021 Guillaume Le Vaillant <[email protected]>
11;;; Copyright © 2025 Matthew Elwin <[email protected]>
12;;; Copyright © 2025 Nicolas Graves <[email protected]>
13;;;
14;;; This file is part of GNU Guix.
15;;;
16;;; GNU Guix is free software; you can redistribute it and/or modify it
17;;; under the terms of the GNU General Public License as published by
18;;; the Free Software Foundation; either version 3 of the License, or (at
19;;; your option) any later version.
20;;;
21;;; GNU Guix is distributed in the hope that it will be useful, but
22;;; WITHOUT ANY WARRANTY; without even the implied warranty of
23;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24;;; GNU General Public License for more details.
25;;;
26;;; You should have received a copy of the GNU General Public License
27;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
28
29(define-module (gnu packages logging)
30 #:use-module ((guix licenses) #:prefix license:)
31 #:use-module (guix gexp)
32 #:use-module (guix packages)
33 #:use-module (guix utils)
34 #:use-module (guix download)
35 #:use-module (guix git-download)
36 #:use-module (guix build-system cmake)
37 #:use-module (guix build-system gnu)
38 #:use-module (gnu packages)
39 #:use-module (gnu packages apr)
40 #:use-module (gnu packages autotools)
41 #:use-module (gnu packages bison)
42 #:use-module (gnu packages c)
43 #:use-module (gnu packages check)
44 #:use-module (gnu packages cmake)
45 #:use-module (gnu packages compression)
46 #:use-module (gnu packages curl)
47 #:use-module (gnu packages cyrus-sasl)
48 #:use-module (gnu packages databases)
49 #:use-module (gnu packages compiler-tools)
50 #:use-module (gnu packages geo)
51 #:use-module (gnu packages gnupg)
52 #:use-module (gnu packages kerberos)
53 #:use-module (gnu packages linux)
54 #:use-module (gnu packages ncurses)
55 #:use-module (gnu packages networking)
56 #:use-module (gnu packages perl)
57 #:use-module (gnu packages pkg-config)
58 #:use-module (gnu packages pretty-print)
59 #:use-module (gnu packages python)
60 #:use-module (gnu packages python-build)
61 #:use-module (gnu packages python-check)
62 #:use-module (gnu packages python-web)
63 #:use-module (gnu packages python-xyz)
64 #:use-module (gnu packages tcl)
65 #:use-module (gnu packages tls))
66
67(define-public log4cpp
68 (package
69 (name "log4cpp")
70 (version "1.1.3")
71 (source (origin
72 (method url-fetch)
73 (uri (string-append "mirror://sourceforge/log4cpp/log4cpp-"
74 (version-major+minor version) ".x%20%28new%29"
75 "/log4cpp-" (version-major+minor version)
76 "/log4cpp-" version ".tar.gz"))
77 (sha256
78 (base32
79 "07gmr3jyaf2239n9sp6h7hwdz1pv7b7aka8n06gmr2fnlmaymfrc"))))
80 (build-system gnu-build-system)
81 (arguments
82 '(#:phases
83 (modify-phases %standard-phases
84 (add-after 'unpack 'do-not-call-stime
85 (lambda _
86 ;; Patch out use of 'stime' which was removed from glibc 2.31.
87 ;; The test would not work in the build container anyway.
88 (substitute* "tests/testDailyRollingFileAppender.cpp"
89 (("if \\(stime\\(&now\\) == -1\\)")
90 "if (1)"))
91 #t)))))
92 (synopsis "Log library for C++")
93 (description
94 "Log4cpp is library of C++ classes for flexible logging to files, syslog,
95IDSA and other destinations. It is modeled after the Log4j Java library,
96staying as close to their API as is reasonable.")
97 (home-page "https://log4cpp.sourceforge.net/")
98 (license license:lgpl2.1+)))
99
100(define-public log4cxx
101 (package
102 (name "log4cxx")
103 (version "1.4.0")
104 (source
105 (origin
106 (method url-fetch)
107 (uri (string-append "mirror://apache/logging/log4cxx/" version
108 "/apache-log4cxx-" version ".tar.gz"))
109 (sha256
110 (base32 "15kgxmqpbg8brf7zd8mmzr7rvm9zrigz3ak34xb18v2ld8siyb9x"))))
111 (build-system cmake-build-system)
112 (native-inputs (list apr apr-util pkg-config zip))
113 (home-page "https://logging.apache.org/log4cxx/")
114 (synopsis "C++ logging library patterned after Apache log4j")
115 (description
116 "The log4cxx packages provides a C++ logging framework patterned
117after Apache log4j which uses the Apache Portable Runtime for most
118platform-specific code.")
119 (license license:asl2.0)))
120
121(define-public logmich
122 ;; XXX: Does not release anymore.
123 (let ((commit "2610fad6768e5b493b52ff08d60d1eb8825f1ab6")
124 (revision "1"))
125 (package
126 (name "logmich")
127 (version (git-version "0.1.0" revision commit))
128 (source
129 (origin
130 (method git-fetch)
131 (uri (git-reference
132 (url "https://github.com/logmich/logmich")
133 (commit commit)))
134 (file-name (git-file-name name version))
135 (sha256
136 (base32 "02bnnrz0fh216pyn05axhizkmglsyfc29qry4s928dyy4spypynq"))))
137 (build-system cmake-build-system)
138 (arguments
139 (list
140 #:configure-flags
141 #~(list "-DBUILD_TESTS=ON")))
142 (inputs (list fmt-8))
143 (native-inputs (list tinycmmc))
144 (home-page "https://github.com/logmich/logmich")
145 (synopsis "Trivial logging library")
146 (description
147 "This package provides a bare-bones logging library for C++, with only
148a @code{printf}-like syntax and five logging levels.")
149 (license license:gpl3+))))
150
151(define-public glog
152 (package
153 (name "glog")
154 (version "0.5.0")
155 (home-page "https://github.com/google/glog")
156 (source (origin
157 (method git-fetch)
158 (uri (git-reference (url home-page)
159 (commit (string-append "v" version))))
160 (sha256
161 (base32
162 "17014q25c99qyis6l3fwxidw6222bb269fdlr74gn7pzmzg4lvg3"))
163 (file-name (git-file-name name version))
164 (patches (search-patches "glog-windows-h-nonwindows.patch"))))
165 (build-system cmake-build-system)
166 (native-inputs
167 (list perl ;for tests
168 autoconf automake libtool))
169 (synopsis "C++ logging library")
170 (description
171 "Google glog is a library that implements application-level logging.
172This library provides logging APIs based on C++-style streams and various
173helper macros. You can log a message by simply streaming things to log at a
174particular severity level. It allows logging to be controlled from the
175command line.")
176 (license license:bsd-3)))
177
178(define-public glog-next
179 (package
180 (inherit glog)
181 (version "0.7.1")
182 (home-page "https://github.com/google/glog")
183 (source (origin
184 (method git-fetch)
185 (uri (git-reference (url home-page)
186 (commit (string-append "v" version))))
187 (sha256
188 (base32
189 "1zh482ga8mndsw277h9wrq4i5xffji0li3v0xha1i6j1llzicz7s"))
190 (file-name (git-file-name "glog" version))))
191 (arguments
192 (list #:phases
193 #~(modify-phases %standard-phases
194 (add-before 'check 'set-temporary-directory
195 (lambda _
196 ;; By default tests produce junk straight under
197 ;; /tmp/guix-build-glog*, which confuses the
198 ;; 'install-license-files' phase. Set 'TMPDIR' so that
199 ;; junk is out of the way.
200 (setenv "TMPDIR"
201 (string-append (getcwd) "/test-tmp"))
202 (mkdir (getenv "TMPDIR")))))))))
203
204(define-public plog
205 (package
206 (name "plog")
207 (version "1.1.10")
208 (source (origin
209 (method git-fetch)
210 (uri (git-reference
211 (url "https://github.com/SergiusTheBest/plog")
212 (commit version)))
213 (file-name (git-file-name name version))
214 (sha256
215 (base32
216 "1kxqz3vn98y1qij60sxn0ldv5q2xh2zbp7v8cd9m21sf1yp636im"))))
217 (build-system cmake-build-system)
218 (arguments
219 (list #:configure-flags
220 #~'("-DPLOG_BUILD_TESTS=ON")))
221 (home-page "https://github.com/SergiusTheBest/plog")
222 (synopsis "C++ logging library")
223 (description
224 "Plog is a C++ logging library that is designed to be simple, small and
225flexible. It is created as an alternative to existing large libraries and
226provides some unique features such as CSV log format and wide string support.")
227 (license license:expat)))
228
229(define-public multitail
230 (package
231 (name "multitail")
232 (version "7.1.5")
233 (source
234 (origin
235 (method git-fetch)
236 (uri (git-reference
237 (url "https://github.com/folkertvanheusden/multitail")
238 (commit version)))
239 (file-name (git-file-name name version))
240 (sha256
241 (base32 "11kkd2rg3qc7ck5iyha0f8l5lqc1bvwypn80di0h77h7p106blvk"))))
242 (build-system cmake-build-system)
243 (arguments
244 (list
245 #:tests? #f ;no test suite
246 #:phases #~(modify-phases %standard-phases
247 (add-after 'unpack 'patch-curses-headers
248 (lambda _
249 (substitute* "mt.h"
250 (("ncursesw/") "")))))))
251 (inputs (list ncurses))
252 (home-page "https://vanheusden.com/multitail/")
253 (synopsis "Monitor multiple log files")
254 (description
255 "MultiTail can monitor, color, filter, and merge log files and command
256output in multiple windows in a terminal.")
257 (license license:gpl2+)))
258
259(define-public spdlog
260 (package
261 (name "spdlog")
262 (version "1.17.0")
263 (source
264 (origin
265 (method git-fetch)
266 (uri (git-reference
267 (url "https://github.com/gabime/spdlog")
268 (commit (string-append "v" version))))
269 (file-name (git-file-name name version))
270 (sha256
271 (base32 "0dhvr6dqjddrwc7af6x1j6kf9x5z1gnfy8isk03dqp0ic51f3gbc"))
272 (modules '((guix build utils)))
273 (snippet #~(delete-file-recursively "include/spdlog/fmt/bundled"))))
274 (build-system cmake-build-system)
275 (outputs '("out" "bin"))
276 (arguments
277 (list #:configure-flags
278 #~(list "-DSPDLOG_BUILD_BENCH=ON"
279 "-DSPDLOG_BUILD_SHARED=ON"
280 "-DSPDLOG_FMT_EXTERNAL=ON"
281 #$@(if (%current-target-system)
282 '()
283 '("-DSPDLOG_BUILD_TESTS=ON")))
284 #:phases
285 #~(modify-phases %standard-phases
286 (add-after 'unpack 'patch
287 (lambda _
288 (substitute* "bench/CMakeLists.txt"
289 ;; Add install command for each benchmark program.
290 (("add_executable\\(([^ ]+) .*$" all target)
291 (string-append all
292 "install(TARGETS "
293 target
294 " DESTINATION "
295 #$output:bin "/bin"
296 ")\n"))))))))
297 (native-inputs (list catch2))
298 (inputs (list googlebenchmark))
299 (propagated-inputs (list fmt))
300 (home-page "https://github.com/gabime/spdlog")
301 (synopsis "Fast C++ logging library")
302 (description "Spdlog is a very fast header-only/compiled C++ logging
303library.")
304 (license license:expat)))
305
306(define-public rsyslog
307 (package
308 (name "rsyslog")
309 (version "8.2512.0")
310 (source
311 (origin
312 (method git-fetch)
313 (uri (git-reference
314 (url "https://github.com/rsyslog/rsyslog.git")
315 (commit (string-append "v" version))))
316 (file-name (git-file-name name version))
317 (sha256
318 (base32 "1w0yg5gwj0153z4vpcqayij6m6asji4jyshlji0i4gz1kic53mab"))))
319 (build-system gnu-build-system)
320 (arguments
321 (list
322 #:phases
323 '(modify-phases %standard-phases
324 ;; autogen.sh calls configure at the end of the script.
325 (replace 'bootstrap
326 (lambda _ (invoke "autoreconf" "-vfi"))))
327 #:configure-flags
328 ;; Rsyslog comes with a plethora of optional modules. We enable most of
329 ;; them for a full-featured build.
330 '(list "--enable-kmsg"
331 "--enable-liblogging_stdlog"
332 "--enable-unlimited_select"
333 "--enable-usertools"
334
335 ;; Input plugins
336 "--enable-imbatchreport"
337 "--enable-imczmq"
338 "--enable-imdiag" ;for full tests
339 "--enable-imdocker"
340 "--enable-imfile"
341 "--enable-imkafka"
342 "--enable-improg"
343 "--enable-impstats"
344 "--enable-imptcp"
345 "--enable-imtuxedoulog"
346
347 ;; Output plugins
348 "--enable-clickhouse"
349 "--enable-elasticsearch"
350 "--enable-mail"
351 "--enable-omczmq"
352 "--enable-omfile_hardened"
353 "--enable-omhttp"
354 "--enable-omhttpfs"
355 "--enable-omkafka"
356 "--enable-omprog"
357 "--enable-omruleset"
358 "--enable-omstdout"
359 "--enable-omtcl"
360 "--enable-omudpspoof"
361 "--enable-omuxsock"
362
363 ;; Parser Modules
364 "--enable-pmaixforwardedfrom"
365 "--enable-pmciscoios"
366 "--enable-pmcisconames"
367 "--enable-pmdb2diag"
368 "--enable-pmlastmsg"
369 "--enable-pmnormalize"
370 "--enable-pmnull"
371 "--enable-pmpanngfw"
372 "--enable-pmsnare"
373
374 ;; Message Modification Modules
375 "--enable-mmanon"
376 "--enable-mmaudit"
377 "--enable-mmcount"
378 "--enable-mmdarwin"
379 "--enable-mmdblookup"
380 "--enable-mmfields"
381 "--enable-mmjsonparse"
382 "--enable-mmkubernetes"
383 "--enable-mmnormalize"
384 "--enable-mmpstrucdata"
385 "--enable-mmrfc5424addhmac"
386 "--enable-mmrm1stspace"
387 "--enable-mmsequence"
388 "--enable-mmsnmptrapd"
389 "--enable-mmtaghostname"
390 "--enable-mmutf8fix"
391
392 ;; Database Support
393 "--enable-libdbi"
394 "--enable-mysql"
395 "--enable-pgsql"
396
397 ;; Protocol Support
398 "--enable-openssl"
399 "--enable-gnutls"
400 "--enable-gssapi-krb5"
401 "--enable-snmp"
402
403 ;; Function modules
404 "--enable-fmhash_xxhash"
405
406 ;; Needed to build rscryutil.1.gz.
407 "--enable-generate-man-pages")))
408 (native-inputs
409 (list autoconf
410 automake
411 bison
412 flex
413 libtool
414 pkg-config
415 python-docutils)) ; rst2man for man pages
416 (inputs
417 (list curl
418 cyrus-sasl
419 czmq
420 gnutls
421 libdbi
422 libestr
423 libfastjson
424 libgcrypt
425 liblogging
426 liblognorm
427 libmaxminddb
428 libnet
429 librdkafka
430 lz4
431 (list mariadb "dev")
432 (list mariadb "lib")
433 mit-krb5
434 net-snmp
435 openssl
436 postgresql
437 tcl
438 (list util-linux "lib")
439 zeromq
440 zlib))
441 (home-page "https://www.rsyslog.com/")
442 (synopsis "RSYSLOG is a flexible and fast system for log processing")
443 (description
444 "Rsyslog offers high-performance, great security features and a modular
445design. While it started as a regular syslogd, rsyslog has evolved into a
446kind of swiss army knife of logging, being able to accept inputs from a wide
447variety of sources, transform them, and output the results to diverse
448destinations.")
449 ;; Most of the source code is licensed under the LGPL3+ with many source
450 ;; files licensed under the terms of the ASL2.0. Some modules are
451 ;; licensed under GPL3+.
452 (license (list license:lgpl3+
453 license:gpl3+
454 license:asl2.0))))