1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2018 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2012, 2013, 2014, 2015, 2016 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2013, 2017 Cyril Roelandt <tipecaml@gmail.com>
5 ;;; Copyright © 2014, 2016 David Thompson <davet@gnu.org>
6 ;;; Copyright © 2014, 2015, 2016, 2018 Mark H Weaver <mhw@netris.org>
7 ;;; Copyright © 2014, 2015 Eric Bavier <bavier@member.fsf.org>
8 ;;; Copyright © 2015, 2016 Sou Bunnbu <iyzsong@gmail.com>
9 ;;; Copyright © 2015 Leo Famulari <leo@famulari.name>
10 ;;; Copyright © 2015 Eric Dvorsak <eric@dvorsak.fr>
11 ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
12 ;;; Copyright © 2016 Christopher Allan Webber <cwebber@dustycloud.org>
13 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
14 ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is>
15 ;;; Copyright © 2016, 2017, 2018 Roel Janssen <roel@gnu.org>
16 ;;; Copyright © 2016 David Craven <david@craven.ch>
17 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
18 ;;; Copyright © 2016 Andy Patterson <ajpatter@uwaterloo.ca>
19 ;;; Copyright © 2016 Danny Milosavljevic <dannym+a@scratchpost.org>
20 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
21 ;;; Copyright © 2017, 2018 Julien Lepiller <julien@lepiller.eu>
22 ;;; Copyright © 2017, 2020 Thomas Danckaert <post@thomasdanckaert.be>
23 ;;; Copyright © 2017 Jelle Licht <jlicht@fsfe.org>
24 ;;; Copyright © 2017 Adriano Peluso <catonano@gmail.com>
25 ;;; Copyright © 2017 Arun Isaac <arunisaac@systemreboot.net>
26 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
27 ;;; Copyright © 2017, 2018 Alex Vong <alexvong1995@gmail.com>
28 ;;; Copyright © 2017, 2018 Ben Woodcroft <donttrustben@gmail.com>
29 ;;; Copyright © 2017 Rutger Helling <rhelling@mykolab.com>
30 ;;; Copyright © 2017, 2018 Pierre Langlois <pierre.langlois@gmx.com>
31 ;;; Copyright © 2015, 2017, 2018, 2019 Ricardo Wurmus <rekado@elephly.net>
32 ;;; Copyright © 2017 Kristofer Buffington <kristoferbuffington@gmail.com>
33 ;;; Copyright © 2018 Amirouche Boubekki <amirouche@hypermove.net>
34 ;;; Copyright © 2018 Joshua Sierles, Nextjournal <joshua@nextjournal.com>
35 ;;; Copyright © 2018 Maxim Cournoyer <maxim.cournoyer@gmail.com>
36 ;;; Copyright © 2019 Jack Hill <jackhill@jackhill.us>
37 ;;; Copyright © 2019 Alex Griffin <a@ajgrf.com>
38 ;;; Copyright © 2019 Gábor Boskovits <boskovits@gmail.com>
39 ;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com>
40 ;;; Copyright © 2019, 2021 Guillaume Le Vaillant <glv@posteo.net>
41 ;;; Copyright © 2020 Pierre Neidhardt <mail@ambrevar.xyz>
42 ;;; Copyright © 2020 Nicolò Balzarotti <nicolo@nixo.xyz>
43 ;;; Copyright © 2020 Tanguy Le Carrour <tanguy@bioneland.org>
44 ;;; Copyright © 2020 Lars-Dominik Braun <ldb@leibniz-psychology.org>
45 ;;; Copyright © 2020 Guy Fleury Iteriteka <gfleury@disroot.org>
46 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
47 ;;; Copyright © 2020 Vinicius Monego <monego@posteo.net>
48 ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
49 ;;; Copyright © 2021 Sharlatan Hellseher <sharlatanus@gmail.com>
50 ;;; Copyright © 2021 Greg Hogan <code@greghogan.com>
52 ;;; This file is part of GNU Guix.
54 ;;; GNU Guix is free software; you can redistribute it and/or modify it
55 ;;; under the terms of the GNU General Public License as published by
56 ;;; the Free Software Foundation; either version 3 of the License, or (at
57 ;;; your option) any later version.
59 ;;; GNU Guix is distributed in the hope that it will be useful, but
60 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
61 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
62 ;;; GNU General Public License for more details.
64 ;;; You should have received a copy of the GNU General Public License
65 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
67 (define-module (gnu packages databases)
68 #:use-module (gnu packages)
69 #:use-module (gnu packages admin)
70 #:use-module (gnu packages algebra)
71 #:use-module (gnu packages autotools)
72 #:use-module (gnu packages avahi)
73 #:use-module (gnu packages base)
74 #:use-module (gnu packages bash)
75 #:use-module (gnu packages bison)
76 #:use-module (gnu packages boost)
77 #:use-module (gnu packages check)
78 #:use-module (gnu packages cmake)
79 #:use-module (gnu packages compression)
80 #:use-module (gnu packages crypto)
81 #:use-module (gnu packages curl)
82 #:use-module (gnu packages cyrus-sasl)
83 #:use-module (gnu packages dbm)
84 #:use-module (gnu packages emacs)
85 #:use-module (gnu packages flex)
86 #:use-module (gnu packages gcc)
87 #:use-module (gnu packages gettext)
88 #:use-module (gnu packages glib)
89 #:use-module (gnu packages gnupg)
90 #:use-module (gnu packages golang)
91 #:use-module (gnu packages guile)
92 #:use-module (gnu packages icu4c)
93 #:use-module (gnu packages jemalloc)
94 #:use-module (gnu packages language)
95 #:use-module (gnu packages libedit)
96 #:use-module (gnu packages libevent)
97 #:use-module (gnu packages linux)
98 #:use-module (gnu packages lisp)
99 #:use-module (gnu packages lisp-xyz)
100 #:use-module (gnu packages logging)
101 #:use-module (gnu packages man)
102 #:use-module (gnu packages maths)
103 #:use-module (gnu packages multiprecision)
104 #:use-module (gnu packages ncurses)
105 #:use-module (gnu packages onc-rpc)
106 #:use-module (gnu packages parallel)
107 #:use-module (gnu packages pcre)
108 #:use-module (gnu packages perl)
109 #:use-module (gnu packages perl-check)
110 #:use-module (gnu packages perl-web)
111 #:use-module (gnu packages pkg-config)
112 #:use-module (gnu packages popt)
113 #:use-module (gnu packages protobuf)
114 #:use-module (gnu packages python)
115 #:use-module (gnu packages python-crypto)
116 #:use-module (gnu packages python-science)
117 #:use-module (gnu packages python-web)
118 #:use-module (gnu packages python-xyz)
119 #:use-module (gnu packages rdf)
120 #:use-module (gnu packages readline)
121 #:use-module (gnu packages regex)
122 #:use-module (gnu packages rpc)
123 #:use-module (gnu packages ruby)
124 #:use-module (gnu packages serialization)
125 #:use-module (gnu packages sphinx)
126 #:use-module (gnu packages sqlite)
127 #:use-module (gnu packages tcl)
128 #:use-module (gnu packages terminals)
129 #:use-module (gnu packages textutils)
130 #:use-module (gnu packages time)
131 #:use-module (gnu packages tls)
132 #:use-module (gnu packages valgrind)
133 #:use-module (gnu packages web)
134 #:use-module (gnu packages xml)
135 #:use-module ((guix licenses) #:prefix license:)
136 #:use-module (guix packages)
137 #:use-module (guix download)
138 #:use-module (guix bzr-download)
139 #:use-module (guix git-download)
140 #:use-module (guix hg-download)
141 #:use-module (guix build-system emacs)
142 #:use-module (guix build-system gnu)
143 #:use-module (guix build-system go)
144 #:use-module (guix build-system perl)
145 #:use-module (guix build-system python)
146 #:use-module (guix build-system ruby)
147 #:use-module (guix build-system cmake)
148 #:use-module (guix build-system scons)
149 #:use-module (guix build-system trivial)
150 #:use-module (guix utils)
151 #:use-module (srfi srfi-1)
152 #:use-module (srfi srfi-26)
153 #:use-module (ice-9 match))
155 (define-public 4store
162 (url "https://github.com/4store/4store")
163 (commit (string-append "v" version))))
164 (file-name (git-file-name name version))
166 (base32 "1kzdfmwpzy64cgqlkcz5v4klwx99w0jk7afckyf7yqbqb4rydmpk"))
167 (patches (search-patches "4store-unset-preprocessor-directive.patch"
168 "4store-fix-buildsystem.patch"))))
169 (build-system gnu-build-system)
173 ("autoconf" ,autoconf)
174 ("automake" ,automake)
175 ("gettext" ,gettext-minimal)
177 ("pcre" ,pcre "bin") ;for 'pcre-config'
178 ("pkg-config" ,pkg-config)))
184 ("readline" ,readline)
186 ("cyrus-sasl" ,cyrus-sasl)
188 ("util-linux" ,util-linux "lib")))
189 ;; http://www.4store.org has been down for a while now.
190 (home-page "https://github.com/4store/4store")
191 (synopsis "Clustered RDF storage and query engine")
192 (description "4store is a RDF/SPARQL store written in C, supporting
193 either single machines or networked clusters.")
194 (license license:gpl3+)))
196 (define-public go-gopkg.in-mgo.v2
198 (name "go-gopkg.in-mgo.v2")
199 (version "2016.08.01")
203 (url "https://github.com/go-mgo/mgo")
204 (commit (string-append "r" version))))
205 (file-name (git-file-name name version))
208 "0rwbi1z63w43b0z9srm8m7iz1fdwx7bq7n2mz862d6liiaqa59jd"))))
209 (build-system go-build-system)
211 `(#:import-path "gopkg.in/mgo.v2"
212 ;; TODO: The tests fail as MongoDB fails to start
213 ;; Error parsing command line: unrecognised option '--chunkSize'
216 (modify-phases %standard-phases
217 (delete 'reset-gzip-timestamps)
218 (add-before 'check 'start-mongodb
219 (lambda* (#:key tests? #:allow-other-keys)
221 (with-directory-excursion "src/gopkg.in/mgo.v2"
222 (invoke "make" "startdb")))
224 (add-after 'check 'stop'mongodb
225 (lambda* (#:key tests? #:allow-other-keys)
227 (with-directory-excursion "src/gopkg.in/mgo.v2"
228 (invoke "make" "stopdb")))
231 `(("go-gopkg.in-check.v1" ,go-gopkg.in-check.v1)
233 ("daemontools" ,daemontools)))
234 (synopsis "@code{mgo} offers a rich MongoDB driver for Go.")
236 "@code{mgo} (pronounced as mango) is a MongoDB driver for the Go language.
237 It implements a rich selection of features under a simple API following
238 standard Go idioms.")
239 (home-page "https://labix.org/mgo")
240 (license license:bsd-2)))
242 (define-public ephemeralpg
250 "https://eradman.com/ephemeralpg/code/ephemeralpg-"
253 (base32 "1ap22ki8yz6agd0qybcjgs4b9izw1rwwcgpxn3jah2ccfyax34s6"))))
254 (build-system gnu-build-system)
256 `(#:make-flags (list (string-append "CC=" ,(cc-for-target))
257 (string-append "PREFIX=" %output))
259 (modify-phases %standard-phases
260 (delete 'configure) ; no configure script
261 (add-after 'install 'wrap
262 (lambda* (#:key inputs outputs #:allow-other-keys)
263 (let ((out (assoc-ref outputs "out")))
264 (wrap-program (string-append out "/bin/pg_tmp")
266 (,(string-append (assoc-ref inputs "util-linux")
268 ,(string-append (assoc-ref inputs "postgresql")
271 ,(string-append out "/bin")))))
273 #:test-target "test"))
275 `(("postgresql" ,postgresql)
276 ("util-linux" ,util-linux)))
281 (home-page "https://eradman.com/ephemeralpg/")
282 (synopsis "Run temporary PostgreSQL databases")
284 "@code{pg_tmp} creates temporary PostgreSQL databases, suitable for tasks
285 like running software test suites. Temporary databases created with
286 @code{pg_tmp} have a limited shared memory footprint and are automatically
287 garbage-collected after a configurable number of seconds (the default is
289 (license license:isc)))
291 (define-public es-dump-restore
293 (name "es-dump-restore")
298 (uri (rubygems-uri "es_dump_restore" version))
301 "020yk7f1hw48clmf5501z3xv9shsdchyymcv0y2cci2c1xvr1mim"))))
302 (build-system ruby-build-system)
304 '(#:tests? #f)) ;; No testsuite.
306 `(("ruby-httpclient" ,ruby-httpclient)
307 ("ruby-multi-json" ,ruby-multi-json)
308 ("ruby-progress_bar" ,ruby-progress_bar)
309 ("ruby-rubyzip" ,ruby-rubyzip)
310 ("ruby-thor" ,ruby-thor)))
311 (synopsis "Utility for dumping and restoring ElasticSearch indexes")
313 "This package provides a utility for dumping the contents of an
314 ElasticSearch index to a compressed file and restoring the dumpfile back to an
315 ElasticSearch server")
316 (home-page "https://github.com/patientslikeme/es_dump_restore")
317 (license license:expat)))
319 (define-public firebird
324 (let ((revision "33374-0"))
327 (uri (string-append "https://github.com/FirebirdSQL/"
328 "firebird/releases/download/R"
329 (string-replace-substring version "." "_") "/"
330 "Firebird-" version "." revision ".tar.bz2"))
332 (base32 "0xpy1bncz36c6n28y7kllm1dkrdkn4vb4gw2n43f2351mznmrf5c"))
333 (modules '((guix build utils)))
337 delete-file-recursively
338 (list "extern/btyacc/test" ; TODO: package and remove entirely
343 "src/include/firebird/impl/boost"
346 "builds/install/arch-specific/solaris"
348 "src/msgs/templates.sql"
350 ;; Generated files missing sources.
351 "doc/Firebird-3-QuickStart.pdf"
352 (string-append "doc/Firebird-" ,version
354 "doc/README.SecureRemotePassword.html"))
356 (build-system gnu-build-system)
357 (outputs (list "debug" "out"))
360 (let ((out (assoc-ref %outputs "out")))
361 (list (string-append "--with-fbsbin=" out "/sbin")
362 (string-append "--with-fbdoc=" out "/share/doc/"
364 (string-append "--with-fbconf=" out "/lib/firebird")
365 (string-append "--with-fbintl=" out "/lib/firebird/intl")
366 (string-append "--with-fbmisc=" out "/lib/firebird/misc")
367 (string-append "--with-fbmsg=" out "/lib/firebird")
368 (string-append "--with-fbplugins=" out "/lib/firebird/plugins")
369 (string-append "--with-fbudf=" out "/lib/firebird/UDF")
370 "--with-fbglock=/run/firebird"
371 "--with-fblog=/var/log/firebird"
372 "--with-fbhelp=/var/lib/firebird/system"
373 "--with-fbsecure-db=/var/lib/firebird/secure"
375 "--without-fbsample-db"
376 "--with-system-editline"))
378 (list (string-append "CC=" ,(cc-for-target))
379 ;; The plugins/ can't find libfbclient otherwise.
380 (string-append "LDFLAGS=-Wl,-rpath="
381 (assoc-ref %outputs "out") "/lib"))
382 #:tests? #f ; no test suite
383 #:modules ((guix build gnu-build-system)
387 (modify-phases %standard-phases
388 (add-after 'unpack 'use-system-boost
390 (substitute* "src/include/firebird/Message.h"
391 (("\"\\./impl/boost/preprocessor/seq/for_each_i\\.hpp\"")
392 "<boost/preprocessor/seq/for_each_i.hpp>")
393 (("FB_BOOST_") "BOOST_"))
395 (add-after 'unpack 'patch-installation
398 "builds/install/arch-specific/linux/makeInstallImage.sh.in"
399 (("/bin/sh") (which "bash"))
400 ;; Remove shell script helpers from $PATH.
401 (("(addLibs|cp) .*\\.sh .*@FB_SBINDIR@") ":")
402 ;; Put files where Guix users expect them.
403 (("(License\\.txt.*)@FB_CONFDIR" match)
404 (string-append match "@FB_DOCDIR@"))
405 (("@FB_CONFDIR@(.*License\\.txt.*)" match)
406 (string-append "@FB_DOCDIR@" match))
407 (("(cp .*/doc/.*)@FB_CONFDIR@(.*)" _ head tail)
408 (string-append head "@FB_DOCDIR@" tail "\n")))
410 (list "builds/install/posix-common/changeServerMode.sh.in"
411 "builds/install/posix-common/install.sh.in")
412 ;; Skip phases that (could) cause problems in Guix.
413 (("check(InstallUser|IfServerRunning|Libraries)|addFirebirdUser")
415 ;; Skip phases that are merely pointless on Guix.
416 (("buildUninstallFile|installInitdScript|startFirebird") ":")
417 ;; Omit randomly generated password with bonus timestamp.
418 (("setDBAPassword") ":"))
420 ;; These promote proprietary workflows not relevant on Guix.
421 (for-each delete-file-recursively
422 (find-files "doc" "README\\.(build\\.msvc|NT|Win)"))
424 (add-after 'configure 'delete-init-scripts
426 (delete-file-recursively "gen/install/misc")
428 (add-before 'build 'set-build-environment-variables
430 ;; ‘isql’ needs to run & find libfbclient.so during the build.
431 ;; This doubles as a rudimentary test in lieu of a test suite.
432 (setenv "LD_LIBRARY_PATH"
433 (string-append (assoc-ref %build-inputs "icu4c") "/lib"))
435 (add-before 'install 'keep-embedded-debug-symbols
437 ;; Let the gnu-build-system separate & deal with them later.
438 ;; XXX Upstream would use ‘--strip-unneeded’, shaving a whole
439 ;; megabyte off Guix's 7.7M libEngine12.so, for example.
440 (substitute* "gen/Makefile.install"
441 (("readelf") "false"))
443 (add-after 'install 'prune-undesirable-files
444 (lambda* (#:key outputs #:allow-other-keys)
445 (let ((out (assoc-ref outputs "out")))
446 (with-directory-excursion out
447 ;; Remove example binaries.
448 (for-each delete-file-recursively
449 (find-files "." "example"))
450 ;; Delete (now-)empty directories.
452 (list "include/firebird/impl"
453 "lib/firebird/plugins/udr"))
457 ("editline" ,editline)
459 ("libtommath" ,libtommath)
462 (home-page "https://www.firebirdsql.org")
463 (synopsis "Relational database with many ANSI SQL standard features")
465 "Firebird is an SQL @acronym{RDBMS, relational database management system}
466 with rich support for ANSI SQL (e.g., @code{INSERT...RETURNING}) including
467 @acronym{UDFs, user-defined functions} and PSQL stored procedures, cursors, and
468 triggers. Transactions provide full ACID-compliant referential integrity.
470 The database requires very little manual maintenance once set up, making it
471 ideal for small business or embedded use.
473 When installed as a traditional local or remote (network) database server,
474 Firebird can grow to terabyte scale with proper tuning---although PostgreSQL
475 may be a better choice for such very large environments.
477 Firebird can also be embedded into stand-alone applications that don't want or
478 need a full client & server. Used in this manner, it offers richer SQL support
479 than SQLite as well as the option to seamlessly migrate to a client/server
482 `((lint-hidden-cve . ("CVE-2017-6369"))))
484 ;; See doc/license/README.license.usage.txt for rationale & details.
485 (list license:bsd-3 ; src/common/sha2/
486 license:bsd-4 ; src/common/enc.cpp
487 license:gpl2+ ; builds/posix/make.defaults
488 (license:non-copyleft "file:///builds/install/misc/IPLicense.txt"
489 "InterBase Public License v1.0")
490 (license:non-copyleft "file:///builds/install/misc/IDPLicense.txt"
491 "Initial Developer's Public License v1.0")
492 license:lgpl2.1 ; exception for OSI-compatible licences
493 license:mpl1.1 ; examples/interfaces/0{6,8}*.cpp
494 license:public-domain)))) ; including files without explicit licence
496 (define-public leveldb
503 (url "https://github.com/google/leveldb")
505 (file-name (git-file-name name version))
508 "0qrnhiyq7r4wa1a4wi82zgns35smj94mcjsc7kfs1k6ia9ys79z7"))))
509 (build-system cmake-build-system)
511 `(#:configure-flags '("-DBUILD_SHARED_LIBS=ON" "-DLEVELDB_BUILD_TESTS=ON")))
513 `(("snappy" ,snappy)))
514 (home-page "https://github.com/google/leveldb")
515 (synopsis "Fast key-value storage library")
517 "LevelDB is a fast key-value storage library that provides an ordered
518 mapping from string keys to string values.")
519 (license license:bsd-3)))
521 (define-public memcached
529 "https://memcached.org/files/memcached-" version ".tar.gz"))
531 (base32 "1lcjy1b9krnb2gk72qd1fvivlfiyfvknfi3wngyvyk9ifzijr9nm"))))
532 (build-system gnu-build-system)
534 `(("libevent" ,libevent)
535 ("cyrus-sasl" ,cyrus-sasl)))
536 (home-page "https://memcached.org/")
537 (synopsis "In-memory caching service")
538 (description "Memcached is an in-memory key-value store. It has a small
539 and generic API, and was originally intended for use with dynamic web
541 (license license:bsd-3)))
543 (define-public libmemcached
545 (name "libmemcached")
547 ;; We build from the sources since we want to build the extra HTML
548 ;; documentation which is not included with the release.
552 (url "lp:libmemcached/1.0")
553 (revision (string-append "tag:" version))))
554 (file-name (string-append name "-" version "-checkout"))
557 "1842s4dxdh21gdr46q4dgxigidcs6dkqnbnqjwb9l8r0bqx5nb10"))
559 (search-patches "libmemcached-build-with-gcc7.patch"))))
560 (build-system gnu-build-system)
562 `(("memcached" ,memcached)
564 ("autoconf" ,autoconf)
565 ("automake" ,automake)
569 ("python-sphinx" ,python-sphinx))) ;to build the HTML doc.
571 `(("libevent" ,libevent)
572 ("cyrus-sasl" ,cyrus-sasl)))
573 (outputs '("out" "doc"))
576 (modify-phases %standard-phases
577 (add-before 'bootstrap 'fix-configure.ac
578 ;; Move the AC_CONFIG_AUX_DIR macro use under AC_INIT, otherwise we
579 ;; get the error ``configure: error: cannot find install-sh,
580 ;; install.sh, or shtool in "." "./.." "./../.."`` (see:
581 ;; https://debbugs.gnu.org/cgi/bugreport.cgi?bug=19539 and
582 ;; https://bugs.launchpad.net/libmemcached/+bug/1803922).
584 (delete-file "bootstrap.sh") ;not useful in the context of Guix
585 (substitute* "configure.ac"
586 (("^AC_CONFIG_AUX_DIR\\(\\[build-aux\\]\\).*") "")
587 (("(^AC_INIT.*)" anchor)
588 (string-append anchor "AC_CONFIG_AUX_DIR([build-aux])\n")))
590 (add-before 'bootstrap 'disable-failing-tests
591 ;; See: https://bugs.launchpad.net/libmemcached/+bug/1803926
593 ;; Mark some heavily failing test suites as expected to fail.
594 (substitute* "Makefile.am"
595 (("(XFAIL_TESTS =[^\n]*)" xfail_tests)
596 (string-append xfail_tests " tests/testudp"
597 " tests/libmemcached-1.0/testapp"
598 " tests/libmemcached-1.0/testsocket")))
599 ;; Disable two tests of the unittest test suite.
600 (substitute* "libtest/unittest.cc"
601 ((".*echo_fubar_BINARY \\},.*") "")
602 ((".*application_doesnotexist_BINARY \\},.*") ""))
604 (add-after 'disable-dns-tests 'build-and-install-html-doc
605 (lambda* (#:key outputs #:allow-other-keys)
606 (let ((html (string-append (assoc-ref outputs "doc")
607 "/share/doc/libmemcached/html/")))
608 (invoke "make" "install-html")
609 ;; Cleanup useless files.
610 (for-each delete-file-recursively
611 (map (lambda (x) (string-append html x))
612 '("_sources" ".doctrees" ".buildinfo"))))
614 (home-page "https://libmemcached.org/")
615 (synopsis "C++ library for memcached")
616 (description "libMemcached is a library to use memcached in C/C++
617 applications. It comes with a complete reference guide and documentation of
618 the API, and provides features such as:
620 @item Asynchronous and synchronous transport support
621 @item Consistent hashing and distribution
622 @item Tunable hashing algorithm to match keys
623 @item Access to large object support
624 @item Local replication
626 (license license:bsd-3)))
628 (define-public python-pylibmc
630 (name "python-pylibmc")
635 (uri (pypi-uri "pylibmc" version))
637 (base32 "1sg7d9j0v6g3xg3finf4l1hb72c13vcyyi6rqrc9shbx903d93ca"))))
638 (build-system python-build-system)
641 (modify-phases %standard-phases
642 (add-before 'check 'start-memcached-daemon
643 ;; The test suite requires a memcached server.
645 (invoke "memcached" "-d"))))))
647 `(("memcached" ,memcached)
648 ("python-nose" ,python-nose)))
650 `(("libmemcached" ,libmemcached)
652 ("cyrus-sasl" ,cyrus-sasl)))
653 (home-page "http://sendapatch.se/projects/pylibmc/")
654 (synopsis "Python client for memcached")
656 "@code{pylibmc} is a client in Python for memcached. It is a wrapper
657 around TangentOrg’s libmemcached library, and can be used as a drop-in
658 replacement for the code@{python-memcached} library.")
659 (license license:bsd-3)))
661 (define-public python2-pylibmc
662 (package-with-python2 python-pylibmc))
664 ;; This is the last version of mongodb before they switched to the Server Side
665 ;; Public License (SSPL), which is not a FOSS license. As such, this package
666 ;; cannot be updated.
667 (define-public mongodb
673 (uri (string-append "https://github.com/mongodb/mongo/archive/r"
675 (file-name (string-append name "-" version ".tar.gz"))
677 (base32 "0676lvkljj7a5hdhv78dbykqnqrj9lbn9799mi84b8vbnzsq961r"))
678 (modules '((guix build utils)))
681 (for-each (lambda (dir)
682 (delete-file-recursively
683 (string-append "src/third_party/" dir)))
684 '("pcre-8.41" "scons-2.5.0" "snappy-1.1.3"
685 "valgrind-3.11.0" "wiredtiger"
686 "yaml-cpp-0.5.3" "zlib-1.2.8"))
690 (search-patch "mongodb-support-unknown-linux-distributions.patch")))))
691 (build-system scons-build-system)
693 `(("openssl" ,openssl-1.0)
695 ,@(match (%current-system)
696 ((or "x86_64-linux" "aarch64-linux" "mips64el-linux")
697 `(("wiredtiger" ,wiredtiger)))
699 ("yaml-cpp" ,yaml-cpp)
703 `(("valgrind" ,valgrind)
706 ("python2-pymongo" ,python2-pymongo)
707 ("python2-pyyaml" ,python2-pyyaml)
708 ("tzdata" ,tzdata-for-tests)))
710 `(#:scons ,scons-python2
712 (let ((common-options
713 `(;; "--use-system-tcmalloc" TODO: Missing gperftools
715 ;; wiredtiger is 64-bit only
716 ,,(if (any (cute string-prefix? <> (or (%current-target-system)
718 '("i686-linux" "armhf-linux"))
720 ``"--use-system-wiredtiger")
722 ;; build/opt/mongo/db/fts/unicode/string.o failed: Error 1
723 ;; --use-system-boost
724 "--use-system-snappy"
726 "--use-system-valgrind"
727 ;; "--use-system-stemmer" TODO: Missing relevant package
729 "--disable-warnings-as-errors"
730 ,(format #f "--jobs=~a" (parallel-job-count))
732 (modify-phases %standard-phases
733 (add-after 'unpack 'patch
735 ;; Remove use of GNU extensions in parse_number_test.cpp, to
736 ;; allow compiling with GCC 7 or later
737 ;; https://jira.mongodb.org/browse/SERVER-28063
738 (substitute* "src/mongo/base/parse_number_test.cpp"
739 (("0xabcab\\.defdefP-10")
740 "687.16784283419838"))
742 (add-after 'unpack 'scons-propagate-environment
744 ;; Modify the SConstruct file to arrange for
745 ;; environment variables to be propagated.
746 (substitute* "SConstruct"
747 (("^env = Environment\\(")
748 "env = Environment(ENV=os.environ, "))
750 (add-after 'unpack 'create-version-file
752 (call-with-output-file "version.json"
754 (display ,(simple-format #f "{
760 (apply invoke `("scons"
762 "mongod" "mongo" "mongos"))))
764 (lambda* (#:key tests? inputs #:allow-other-keys)
766 (string-append (assoc-ref inputs "tzdata")
769 ;; Note that with the tests, especially the unittests, the
770 ;; build can take up to ~45GB of space, as many tests are
771 ;; individual executable files, with some being hundreds of
772 ;; megabytes in size.
773 (apply invoke `("scons" ,@common-options "dbtest" "unittests"))
774 (substitute* "build/unittests.txt"
775 ;; TODO: Don't run the async_stream_test, as it hangs
776 (("^build\\/opt\\/mongo\\/executor\\/async\\_stream\\_test\n$")
778 ;; TODO: This test fails
779 ;; Expected 0UL != disks.size() (0 != 0) @src/mongo/util/procparser_test.cpp:476
780 (("^build\\/opt\\/mongo\\/util\\/procparser\\_test\n$")
782 (invoke "python" "buildscripts/resmoke.py"
783 "--suites=dbtest,unittests"
784 (format #f "--jobs=~a" (parallel-job-count))))
787 (lambda* (#:key outputs #:allow-other-keys)
788 (let ((bin (string-append (assoc-ref outputs "out") "/bin")))
789 (install-file "mongod" bin)
790 (install-file "mongos" bin)
791 (install-file "mongo" bin))
793 (home-page "https://www.mongodb.org/")
794 (synopsis "High performance and high availability document database")
796 "Mongo is a high-performance, high availability, schema-free
797 document-oriented database. A key goal of MongoDB is to bridge the gap
798 between key/value stores (which are fast and highly scalable) and traditional
799 RDBMS systems (which are deep in functionality).")
800 (license (list license:agpl3
801 ;; Some parts are licensed under the Apache License
811 (uri (pypi-uri "mycli" version))
813 (base32 "1lq2x95553vdmhw13cxcgsd2g2i32izhsb7hxd4m1iwf9b3msbpv"))))
814 (build-system python-build-system)
816 `(#:tests? #f)) ; tests expect a running MySQL
818 `(("python-cli-helpers" ,python-cli-helpers)
819 ("python-click" ,python-click)
820 ("python-configobj" ,python-configobj)
821 ("python-cryptography" ,python-cryptography)
822 ("python-prompt-toolkit" ,python-prompt-toolkit)
823 ("python-pygments" ,python-pygments)
824 ("python-pymysql" ,python-pymysql)
825 ("python-sqlparse" ,python-sqlparse)))
826 (home-page "http://mycli.net")
828 "Terminal Client for MySQL with AutoCompletion and Syntax Highlighting")
830 "MyCLI is a command line interface for MySQL, MariaDB, and Percona with
831 auto-completion and syntax highlighting.")
832 (license license:bsd-3)))
834 ;; XXX When updating, check whether boost-for-mysql is still needed.
835 ;; It might suffice to patch ‘cmake/boost.cmake’ as done in the past.
842 (uri (list (string-append
843 "https://dev.mysql.com/get/Downloads/MySQL-"
844 (version-major+minor version) "/"
845 name "-" version ".tar.gz")
847 "https://downloads.mysql.com/archives/get/file/"
848 name "-" version ".tar.gz")))
851 "1bb343mf7n0qg2qz497gxjsqprygrjz1q1pbz76hgqxnsy08sfxd"))))
852 (build-system cmake-build-system)
855 '("-DBUILD_CONFIG=mysql_release"
858 "-DDEFAULT_CHARSET=utf8"
859 "-DDEFAULT_COLLATION=utf8_general_ci"
860 "-DMYSQL_DATADIR=/var/lib/mysql"
861 "-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock"
862 "-DINSTALL_INFODIR=share/mysql/docs"
863 "-DINSTALL_MANDIR=share/man"
864 "-DINSTALL_PLUGINDIR=lib/mysql/plugin"
865 "-DINSTALL_SCRIPTDIR=bin"
866 "-DINSTALL_INCLUDEDIR=include/mysql"
867 "-DINSTALL_DOCREADMEDIR=share/mysql/docs"
868 "-DINSTALL_SUPPORTFILESDIR=share/mysql"
869 "-DINSTALL_MYSQLSHAREDIR=share/mysql"
870 "-DINSTALL_DOCDIR=share/mysql/docs"
871 "-DINSTALL_SHAREDIR=share/mysql"
872 ;; Get rid of test data.
873 "-DINSTALL_MYSQLTESTDIR="
874 "-DINSTALL_SQLBENCHDIR=")
875 #:phases (modify-phases %standard-phases
877 'install 'remove-extra-binaries
878 (lambda* (#:key outputs #:allow-other-keys)
879 (let ((out (assoc-ref outputs "out")))
880 ;; Remove the 3 *_embedded files, which weigh in at
882 (for-each delete-file
883 (find-files (string-append out "/bin")
889 ("pkg-config" ,pkg-config)))
891 `(("boost" ,boost-for-mysql)
893 ("libtirpc" ,libtirpc)
896 ("rpcsvc-proto" ,rpcsvc-proto) ; rpcgen
898 (home-page "https://www.mysql.com/")
899 (synopsis "Fast, easy to use, and popular database")
901 "MySQL is a fast, reliable, and easy to use relational database
902 management system that supports the standardized Structured Query
904 (license license:gpl2)))
906 (define-public mariadb
912 (uri (string-append "https://downloads.mariadb.com/MariaDB"
913 "/mariadb-" version "/source/mariadb-"
917 "1s3vfm73911cddjhgpcbkya6nz7ag2zygg56qqzwscn5ybv28j7b"))
918 (modules '((guix build utils)))
921 ;; Delete bundled snappy and xz.
922 (delete-file-recursively "storage/tokudb/PerconaFT/third_party")
923 (substitute* "storage/tokudb/PerconaFT/CMakeLists.txt"
924 ;; This file checks that the bundled sources are present and
925 ;; declares build procedures for them.
926 (("^include\\(TokuThirdParty\\)") ""))
927 (substitute* "storage/tokudb/PerconaFT/ft/CMakeLists.txt"
928 ;; Don't attempt to use the procedures we just removed.
929 ((" build_lzma build_snappy") ""))
931 ;; Preserve CMakeLists.txt for these.
932 (for-each (lambda (file)
933 (unless (string-suffix? "CMakeLists.txt" file)
935 (append (find-files "extra/wolfssl")
936 (find-files "zlib")))
938 (build-system cmake-build-system)
939 (outputs '("out" "lib" "dev"))
943 "-DBUILD_CONFIG=mysql_release"
944 ;; Linking with libarchive fails, like this:
946 ;; ld: /gnu/store/...-libarchive-3.2.2/lib/libarchive.a(archive_entry.o):
947 ;; relocation R_X86_64_32 against `.bss' can not be used when
948 ;; making a shared object; recompile with -fPIC
950 ;; For now, disable the features that that use libarchive (xtrabackup).
951 "-DWITH_LIBARCHIVE=OFF"
953 ;; Disable the TokuDB engine, because its test suite frequently fails,
954 ;; and loading it crashes the server: <https://bugs.gnu.org/35521>.
957 ;; Ensure the system libraries are used.
958 "-DWITH_JEMALLOC=yes"
963 "-DDEFAULT_CHARSET=utf8"
964 "-DDEFAULT_COLLATION=utf8_general_ci"
965 "-DMYSQL_DATADIR=/var/lib/mysql"
966 "-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock"
968 ;; Do not install the benchmark suite.
969 "-DINSTALL_SQLBENCHDIR=false"
971 (string-append "-DCMAKE_INSTALL_PREFIX=" (assoc-ref %outputs "lib"))
972 (string-append "-DCMAKE_INSTALL_RPATH=" (assoc-ref %outputs "lib")
974 (string-append "-DINSTALL_INFODIR=" (assoc-ref %outputs "out")
976 (string-append "-DINSTALL_MANDIR=" (assoc-ref %outputs "out")
978 (string-append "-DINSTALL_SCRIPTDIR=" (assoc-ref %outputs "out") "/bin")
979 (string-append "-DINSTALL_BINDIR=" (assoc-ref %outputs "out") "/bin")
980 "-DCMAKE_INSTALL_LIBDIR=lib"
981 "-DINSTALL_PLUGINDIR=lib/mysql/plugin"
982 (string-append "-DINSTALL_INCLUDEDIR=" (assoc-ref %outputs "dev")
984 (string-append "-DINSTALL_DOCREADMEDIR=" (assoc-ref %outputs "out")
986 (string-append "-DINSTALL_DOCDIR=" (assoc-ref %outputs "out")
988 (string-append "-DINSTALL_SUPPORTFILESDIR=" (assoc-ref %outputs "out")
989 "/share/mysql/support-files")
990 "-DINSTALL_MYSQLSHAREDIR=share/mysql"
991 "-DINSTALL_SHAREDIR=share")
993 (modify-phases %standard-phases
994 (add-after 'unpack 'adjust-output-references
996 ;; The build system invariably prepends $CMAKE_INSTALL_PREFIX
997 ;; to other variables such as $INSTALL_INCLUDEDIR, which does
998 ;; not work when the latter uses an absolute file name.
999 (substitute* "libmariadb/mariadb_config/mariadb_config.c.in"
1000 (("%s/@INSTALL_INCLUDEDIR@")
1001 (string-append "@INSTALL_INCLUDEDIR@"))
1002 ;; As of 10.5.8, the mariadb_config program tries to be
1003 ;; clever and computes the installation directory relative
1004 ;; to /proc/self/exe when running on Linux. Make it fall
1005 ;; back to the old behaviour.
1006 (("defined\\(__linux__\\)")
1008 (substitute* "libmariadb/mariadb_config/libmariadb.pc.in"
1009 (("\\$\\{prefix\\}/@INSTALL_INCLUDEDIR@")
1010 "@INSTALL_INCLUDEDIR@"))
1011 (substitute* "support-files/mariadb.pc.in"
1012 (("^(include|bin|script|doc|man)dir=\\$\\{prefix\\}/" _ dir)
1013 (string-append dir "dir=")))
1014 (substitute* "include/CMakeLists.txt"
1015 (("\\\\\\$\\{CMAKE_INSTALL_PREFIX\\}/\\$\\{INSTALL_INCLUDEDIR\\}")
1016 "${INSTALL_INCLUDEDIR}"))
1017 (substitute* "cmake/mariadb_connector_c.cmake"
1018 (("\\\\\\$\\{CMAKE_INSTALL_PREFIX\\}/\\$\\{INSTALL_BINDIR\\}")
1019 "${INSTALL_BINDIR}"))
1021 (add-after 'unpack 'adjust-tests
1023 (let ((disabled-tests
1024 '(;; These fail because root@hostname == root@localhost in
1025 ;; the build environment, causing a user count mismatch.
1026 ;; See <https://jira.mariadb.org/browse/MDEV-7761>.
1027 "funcs_1.is_columns_mysql"
1029 "main.explain_non_select"
1031 "main.stat_tables_innodb"
1032 "main.upgrade_MDEV-19650"
1033 "roles.acl_statistics"
1035 ;; FIXME: This test checks various table encodings and
1036 ;; fails because Guix defaults to UTF8 instead of the
1037 ;; upstream default latin1_swedish_ci. It's not easily
1038 ;; substitutable because several encodings are tested.
1041 ;; XXX: This test occasionally fails on i686-linux:
1042 ;; <https://jira.mariadb.org/browse/MDEV-24458>
1043 ,@(if (string-prefix? "i686" (%current-system))
1044 '("main.myisampack")
1047 ;; This file contains a time bomb which makes it fail after
1048 ;; 2030-12-31. See <https://bugs.gnu.org/34351> for details.
1051 ;; This file contains a list of known-flaky tests for this
1052 ;; release. Append our own items.
1053 (unstable-tests (open-file "mysql-test/unstable-tests" "a")))
1054 (for-each (lambda (test)
1055 (format unstable-tests "~a : ~a\n"
1056 test "Disabled in Guix"))
1058 (close-port unstable-tests)
1060 ;; XXX: These fail because they expect a latin1 charset and
1061 ;; collation. See <https://jira.mariadb.org/browse/MDEV-21264>.
1062 (substitute* '("mysql-test/main/gis_notembedded.result"
1063 "mysql-test/main/system_mysql_db.result")
1064 (("latin1_swedish_ci") "utf8_general_ci")
1065 (("\tlatin1") "\tutf8"))
1067 (substitute* "mysql-test/suite/binlog/t/binlog_mysqlbinlog_stop_never.test"
1071 (substitute* "mysql-test/mysql-test-run.pl"
1072 (("/bin/ls") (which "ls"))
1073 (("/bin/sh") (which "sh")))
1075 (add-before 'configure 'disable-plugins
1077 (let ((disable-plugin (lambda (name)
1078 (call-with-output-file
1079 (string-append "plugin/" name
1082 (format port "\n")))))
1083 (disabled-plugins '(;; XXX: Causes a test failure.
1085 (for-each disable-plugin disabled-plugins)
1088 (lambda* (#:key (tests? #t) #:allow-other-keys)
1090 (with-directory-excursion "mysql-test"
1091 (invoke "./mtr" "--verbose"
1093 "--testcase-timeout=40"
1094 "--suite-timeout=600"
1095 "--parallel" (number->string (parallel-job-count))
1096 ;; Skip the replication tests: they are very I/O
1097 ;; intensive and frequently causes indeterministic
1098 ;; failures even on powerful hardware.
1100 "--skip-test-list=unstable-tests"))
1101 (format #t "test suite not run~%"))
1104 'install 'post-install
1105 (lambda* (#:key inputs outputs #:allow-other-keys)
1106 (let* ((out (assoc-ref outputs "out"))
1107 (dev (assoc-ref outputs "dev"))
1108 (lib (assoc-ref outputs "lib"))
1109 (openssl (assoc-ref inputs "openssl")))
1110 (substitute* (list (string-append out "/bin/mariadb-install-db")
1111 (string-append out "/bin/mysql_install_db"))
1113 (string-append "basedir=\"" out "\""))
1114 (("\\$basedir/share/mysql")
1115 (string-append lib "/share/mysql")))
1117 (with-directory-excursion lib
1119 (delete-file-recursively "mysql-test")
1120 ;; Remove static libraries.
1121 (for-each delete-file (find-files "lib" "\\.a$")))
1123 (with-directory-excursion out
1124 (delete-file "share/man/man1/mysql-test-run.pl.1")
1125 ;; Delete huge and unnecessary executables.
1126 (for-each delete-file (find-files "bin" "test$")))
1127 (mkdir-p (string-append dev "/share"))
1128 (mkdir-p (string-append dev "/bin"))
1129 (rename-file (string-append lib "/bin/mariadbd")
1130 (string-append out "/bin/mariadbd"))
1131 (rename-file (string-append lib "/bin/mysqld")
1132 (string-append out "/bin/mysqld"))
1133 (mkdir-p (string-append dev "/lib"))
1134 (rename-file (string-append lib "/lib/pkgconfig")
1135 (string-append dev "/lib/pkgconfig"))
1136 (rename-file (string-append lib "/bin/mariadb_config")
1137 (string-append dev "/bin/mariadb_config"))
1138 (rename-file (string-append out "/bin/mysql_config")
1139 (string-append dev "/bin/mysql_config"))
1141 ;; Embed an absolute reference to OpenSSL in mysql_config
1142 ;; and the pkg-config file to avoid propagation.
1143 ;; XXX: how to do this for mariadb_config.c.in?
1144 (substitute* (list (string-append dev "/bin/mysql_config")
1145 (string-append dev "/lib/pkgconfig/mariadb.pc"))
1146 (("-lssl -lcrypto" all)
1147 (string-append "-L" openssl "/lib " all)))
1154 `(("jemalloc" ,jemalloc)
1156 ("libxml2" ,libxml2)
1157 ("ncurses" ,ncurses)
1158 ("openssl" ,openssl)
1163 ;; The test suite is very resource intensive and can take more than three
1164 ;; hours on a x86_64 system. Give slow and busy machines some leeway.
1165 (properties '((timeout . 64800))) ;18 hours
1166 (home-page "https://mariadb.org/")
1167 (synopsis "SQL database server")
1169 "MariaDB is a multi-user and multi-threaded SQL database server, designed
1170 as a drop-in replacement of MySQL.")
1171 (license license:gpl2)))
1173 (define-public mariadb-connector-c
1175 (name "mariadb-connector-c")
1181 "https://downloads.mariadb.org/f/connector-c-" version
1182 "/mariadb-connector-c-" version "-src.tar.gz"
1183 "/from/https%3A//mirrors.ukfast.co.uk/sites/mariadb/?serve"))
1184 (file-name (string-append name "-" version ".tar.gz"))
1186 (base32 "0qzyahr8x9l1xz0l79wz3iahxz7648n1azc5yr7kx0dl113y2nig"))))
1188 `(("openssl" ,openssl)))
1189 (build-system cmake-build-system)
1191 '(#:tests? #f)) ; no tests
1192 (home-page "https://mariadb.com/kb/en/mariadb-connector-c/")
1193 (synopsis "Client library to connect to MySQL or MariaDB")
1194 (description "The MariaDB Connector/C is used to connect applications
1195 developed in C/C++ to MariaDB and MySQL databases.")
1196 (license license:lgpl2.1+)))
1198 ;; Don't forget to update the other postgresql packages when upgrading this one.
1199 (define-public postgresql-13
1202 (replacement postgresql-13.2)
1206 (uri (string-append "https://ftp.postgresql.org/pub/source/v"
1207 version "/postgresql-" version ".tar.bz2"))
1210 "07z6zwr58dckaa97yl9ml240z83d1lhgaxw9aq49i8lsp21mqd0j"))
1211 (patches (search-patches "postgresql-disable-resolve_symlinks.patch"))))
1212 (build-system gnu-build-system)
1214 `(#:configure-flags '("--with-uuid=e2fs" "--with-openssl"
1215 ;; PostgreSQL installs its own Makefile (should it?).
1216 ;; Prevent it from retaining needless references to
1217 ;; the build tools in order to save size.
1218 "MKDIR_P=mkdir -p" "INSTALL_BIN=install -c"
1221 (modify-phases %standard-phases
1222 (add-before 'configure 'patch-/bin/sh
1224 ;; Refer to the actual shell.
1225 (substitute* '("src/bin/pg_ctl/pg_ctl.c"
1226 "src/bin/psql/command.c")
1227 (("/bin/sh") (which "sh")))
1229 (add-after 'build 'build-contrib
1231 (invoke "make" "-C" "contrib")))
1232 (add-after 'install 'install-contrib
1234 (invoke "make" "-C" "contrib" "install"))))))
1236 `(("readline" ,readline)
1237 ("libuuid" ,util-linux "lib")
1238 ("openssl" ,openssl)
1240 (home-page "https://www.postgresql.org/")
1241 (synopsis "Powerful object-relational database system")
1243 "PostgreSQL is a powerful object-relational database system. It is fully
1244 ACID compliant, has full support for foreign keys, joins, views, triggers, and
1245 stored procedures (in multiple languages). It includes most SQL:2008 data
1246 types, including INTEGER, NUMERIC, BOOLEAN, CHAR, VARCHAR, DATE, INTERVAL, and
1247 TIMESTAMP. It also supports storage of binary large objects, including
1248 pictures, sounds, or video.")
1249 (license (license:x11-style "file://COPYRIGHT"))))
1251 (define-public postgresql-13.2
1253 (inherit postgresql-13)
1258 (uri (string-append "https://ftp.postgresql.org/pub/source/v"
1259 version "/postgresql-" version ".tar.bz2"))
1262 "1z5d847jnajcfr3wa6jn52a8xjhamvwzmz18xlm5nvxqip8grmsz"))
1263 (patches (search-patches "postgresql-disable-resolve_symlinks.patch"))))))
1265 (define-public postgresql-11
1267 (inherit postgresql-13)
1271 (inherit (package-source postgresql-13))
1272 (uri (string-append "https://ftp.postgresql.org/pub/source/v"
1273 version "/postgresql-" version ".tar.bz2"))
1276 "0v0qk298nxmpzpgsxcsxma328hdkyzd7fwjs0zsn6zavl5zpnq20"))))))
1278 (define-public postgresql-10
1280 (inherit postgresql-11)
1283 (inherit (package-source postgresql-11))
1284 (uri (string-append "https://ftp.postgresql.org/pub/source/v"
1285 version "/postgresql-" version ".tar.bz2"))
1288 "1cvv8qw0gkkczqhiwx6ns7w88dwkvdz4cvb2d4ff14363f5p2p53"))))))
1290 (define-public postgresql-9.6
1292 (inherit postgresql-10)
1295 (inherit (package-source postgresql-10))
1296 (uri (string-append "https://ftp.postgresql.org/pub/source/v"
1297 version "/postgresql-" version ".tar.bz2"))
1300 "0d0ngpadf1i7c0i2psaxcbmiwx8334ibcsn283n9fp4853pyl3wk"))))))
1302 (define-public postgresql postgresql-13)
1304 (define-public pgloader
1312 (url "https://github.com/dimitri/pgloader")
1313 (commit (string-append "v" version))))
1315 (base32 "06i1jd2za3ih5caj2b4vzlzags5j65vv8dfdbz0ggdrp40wfd5lh"))
1316 (file-name (git-file-name name version))))
1317 (build-system gnu-build-system)
1319 ;; NOTE: (Sharlatan-20210119T211511+0000) Tests are disabled due to being
1320 ;; dependent on Quicklisp, main build target is `pgloader-standalone' which
1321 ;; does not require Quicklisp workarounds. There is no `install' target
1322 ;; configured in Makefile.
1324 #:strip-binaries? #f
1326 (list "pgloader-standalone" "BUILDAPP_SBCL=buildapp")
1328 (modify-phases %standard-phases
1330 (add-after 'unpack 'set-home
1332 (setenv "HOME" "/tmp")
1334 (add-after 'unpack 'patch-Makefile
1336 (substitute* "Makefile"
1337 (("--sbcl.*") "--sbcl $(CL) --asdf-path . \\\n"))
1340 (lambda* (#:key outputs #:allow-other-keys)
1341 (let ((bin (string-append (assoc-ref outputs "out") "/bin")))
1343 (install-file "build/bin/pgloader" bin))
1346 `(("buildapp" ,buildapp)
1349 `(("alexandria" ,sbcl-alexandria)
1350 ("cl-abnf" ,sbcl-cl-abnf)
1351 ("cl-base64" ,sbcl-cl-base64)
1352 ("cl-csv" ,sbcl-cl-csv)
1353 ("cl-fad" ,sbcl-cl-fad)
1354 ("cl-log" ,sbcl-cl-log)
1355 ("cl-markdown" ,sbcl-cl-markdown)
1356 ("cl-mustache" ,sbcl-cl-mustache)
1357 ("cl-ppcre" ,sbcl-cl-ppcre)
1358 ("cl-sqlite" ,sbcl-cl-sqlite)
1359 ("closer-mop" ,sbcl-closer-mop)
1360 ("command-line-arguments" ,sbcl-command-line-arguments)
1362 ("drakma" ,sbcl-drakma)
1363 ("esrap" ,sbcl-esrap)
1364 ("flexi-streams" ,sbcl-flexi-streams)
1366 ("local-time" ,sbcl-local-time)
1367 ("lparallel" ,sbcl-lparallel)
1368 ("metabang-bind" ,sbcl-metabang-bind)
1369 ("mssql" ,sbcl-mssql)
1370 ("postmodern" ,sbcl-postmodern)
1371 ("py-configparser" ,sbcl-py-configparser)
1372 ("qmynd" ,sbcl-qmynd)
1374 ("split-sequence" ,sbcl-split-sequence)
1375 ("trivial-backtrace" ,sbcl-trivial-backtrace)
1376 ("usocket" ,sbcl-usocket)
1378 ("yason" ,sbcl-yason)
1380 (home-page "https://pgloader.io/")
1381 (synopsis "Tool to migrate data to PostgreSQL")
1383 "@code{pgloader} is a program that can load data or migrate databases from
1384 CSV, DB3, iXF, SQLite, MS-SQL or MySQL to PostgreSQL.")
1385 (license (license:x11-style "file://LICENSE"))))
1387 (define-public python-pymysql
1389 (name "python-pymysql")
1394 (uri (pypi-uri "PyMySQL" version))
1396 (base32 "1ry8lxgdc1p3k7gbw20r405jqi5lvhi5wk83kxdbiv8xv3f5kh6q"))))
1397 (build-system python-build-system)
1399 `(("python-unittest2" ,python-unittest2)))
1401 `(("python-cryptography" ,python-cryptography)))
1403 `(#:tests? #f)) ; tests expect a running MySQL
1404 (home-page "https://github.com/PyMySQL/PyMySQL/")
1405 (synopsis "Pure-Python MySQL driver")
1407 "PyMySQL is a pure-Python MySQL client library, based on PEP 249.
1408 Most public APIs are compatible with @command{mysqlclient} and MySQLdb.")
1409 (license license:expat)))
1411 (define-public python2-pymysql
1412 (package-with-python2 python-pymysql))
1421 (uri (string-append "http://fallabs.com/" name "/"
1422 name "-" version ".tar.gz"))
1425 "0gmpvhn02pkq280ffmn4da1g4mdr1xxz7l80b7y4n7km1mrzwrml"))))
1426 (build-system gnu-build-system)
1428 `(#:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath="
1429 (assoc-ref %outputs "out")
1431 #:make-flags (list "CFLAGS=-fPIC")))
1432 (home-page "https://fallabs.com/qdbm/")
1433 (synopsis "Key-value database")
1434 (description "QDBM is a library of routines for managing a
1435 database. The database is a simple data file containing key-value
1436 pairs. Every key and value is serial bytes with variable length.
1437 Binary data as well as character strings can be used as a key or a
1438 value. There is no concept of data tables or data types. Records are
1439 organized in a hash table or B+ tree.")
1440 (license license:lgpl2.1+)))
1442 (define-public recutils
1448 (uri (string-append "mirror://gnu/recutils/recutils-"
1452 "14xiln4immfsw8isnvwvq0h23f6z0wilpgsc4qzabnrzb5lsx3nz"))))
1453 (build-system gnu-build-system)
1455 (arguments '(#:configure-flags
1456 (list (string-append "--with-bash-headers="
1457 (assoc-ref %build-inputs "bash:include")
1460 (native-inputs `(("bc" ,bc)
1461 ("bash:include" ,bash "include")
1462 ("check" ,check-0.14)
1463 ("pkg-config" ,pkg-config)))
1465 ;; TODO: Add more optional inputs.
1466 (inputs `(("curl" ,curl)
1467 ("libgcrypt" ,libgcrypt)
1468 ("libuuid" ,util-linux "lib")))
1469 (synopsis "Manipulate plain text files as databases")
1471 "GNU Recutils is a set of tools and libraries for creating and
1472 manipulating text-based, human-editable databases. Despite being text-based,
1473 databases created with Recutils carry all of the expected features such as
1474 unique fields, primary keys, time stamps and more. Many different field
1475 types are supported, as is encryption.")
1476 (license license:gpl3+)
1477 (home-page "https://www.gnu.org/software/recutils/")))
1479 (define-public emacs-recutils
1482 (name "emacs-recutils")
1483 (build-system emacs-build-system)
1486 (modify-phases %standard-phases
1487 (add-after 'unpack 'change-directory
1493 (synopsis "Emacs mode for working with recutils database files")
1494 (description "This package provides an Emacs major mode @code{rec-mode}
1495 for working with GNU Recutils text-based, human-editable databases. It
1496 supports editing, navigation, and querying of recutils database files
1497 including field and record folding.")))
1499 (define-public rocksdb
1506 (url "https://github.com/facebook/rocksdb")
1507 (commit (string-append "v" version))))
1508 (file-name (git-file-name name version))
1511 "0n19p9cd13jg0lnibrzwkxs4xlrhyj3knypkd2ic41arbds0bdnl"))
1512 (modules '((guix build utils)))
1515 ;; TODO: unbundle gtest.
1516 (delete-file "build_tools/gnu_parallel")
1517 (substitute* "Makefile"
1518 (("build_tools/gnu_parallel") "parallel"))
1520 (build-system gnu-build-system)
1522 `(#:make-flags (list "CC=gcc" "V=1"
1523 ;; Ceph requires that RTTI is enabled.
1525 "date=1970-01-01" ; build reproducibly
1526 (string-append "INSTALL_PATH="
1527 (assoc-ref %outputs "out"))
1529 ;; Running the full test suite takes hours and require
1530 ;; a lot of disk space. Instead we only run a subset
1531 ;; (see .travis.yml and Makefile).
1532 "ROCKSDBTESTS_END=db_tailing_iter_test")
1533 #:test-target "check_some"
1534 ;; Many tests fail on 32-bit platforms. There are multiple reports about
1535 ;; this upstream, but it's not going to be supported any time soon.
1536 #:tests? (let ((system ,(or (%current-target-system)
1537 (%current-system))))
1538 (or (string-prefix? "x86_64-linux" system)
1539 (string-prefix? "aarch64-linux" system)))
1541 (modify-phases %standard-phases
1542 (add-after 'unpack 'patch-Makefile
1544 (substitute* "Makefile"
1545 ;; Don't depend on the static library when installing.
1546 (("install: install-static")
1547 "install: install-shared")
1548 (("#!/bin/sh") (string-append "#!" (which "sh"))))
1551 ;; The default target is only needed for tests and built on demand.
1553 (add-before 'check 'disable-optimizations
1555 ;; Prevent the build from passing '-march=native' to the compiler.
1556 (setenv "PORTABLE" "1")
1558 (add-before 'check 'disable-failing-tests
1560 (substitute* "Makefile"
1561 ;; These tests reliably fail due to "Too many open files".
1562 (("^[[:blank:]]+env_test[[:blank:]]+\\\\") "\\")
1563 (("^[[:blank:]]+persistent_cache_test[[:blank:]]+\\\\") "\\"))
1565 (add-after 'check 'build
1566 ;; The default build target is a debug build for tests. The
1567 ;; install target depends on the "shared_lib" release target
1568 ;; so we build it here for clarity.
1569 (lambda* (#:key (make-flags '()) parallel-build? #:allow-other-keys)
1570 (apply invoke "make" "shared_lib"
1571 `(,@(if parallel-build?
1572 `("-j" ,(number->string (parallel-job-count)))
1576 `(("parallel" ,parallel)
1579 ("python" ,python-2)
1584 ("jemalloc" ,jemalloc)
1588 (home-page "https://rocksdb.org/")
1589 (synopsis "Persistent key-value store for fast storage")
1591 "RocksDB is a library that forms the core building block for a fast
1592 key-value server, especially suited for storing data on flash drives. It
1593 has a @dfn{Log-Structured-Merge-Database} (LSM) design with flexible tradeoffs
1594 between @dfn{Write-Amplification-Factor} (WAF), @dfn{Read-Amplification-Factor}
1595 (RAF) and @dfn{Space-Amplification-Factor} (SAF). It has multi-threaded
1596 compactions, making it specially suitable for storing multiple terabytes of
1597 data in a single database. RocksDB is partially based on @code{LevelDB}.")
1598 ;; RocksDB is dual licensed under GPL2 and ASL 2.0. Some header
1599 ;; files carry the 3-clause BSD license.
1600 (license (list license:gpl2 license:asl2.0 license:bsd-3))))
1602 (define-public sparql-query
1604 (name "sparql-query")
1609 (url "https://github.com/tialaramex/sparql-query")
1612 (base32 "0a84a89idpjhj9w2y3fmvzv7ldps1cva1kxvfmh897k02kaniwxk"))
1613 (file-name (git-file-name name version))))
1614 (build-system gnu-build-system)
1618 ("libxml2" ,libxml2)
1619 ("ncurses" ,ncurses)
1620 ("readline" ,readline)))
1622 `(("pkg-config" ,pkg-config)))
1624 `(#:make-flags '("CC=gcc")
1626 (modify-phases %standard-phases
1628 ;; The Makefile uses git to obtain versioning information. This phase
1629 ;; substitutes the git invocation with the package version.
1630 (add-after 'unpack 'remove-git-dependency
1632 (substitute* "Makefile"
1634 (string-append "gitrev = \"v" ,version "\"")))
1636 ;; The install phase of the Makefile assumes $PREFIX/usr/local/bin.
1637 ;; This replacement does the same thing, except for using $PREFIX/bin
1640 (lambda* (#:key outputs #:allow-other-keys)
1641 (let* ((out (assoc-ref outputs "out"))
1642 (bin (string-append out "/bin")))
1643 (install-file "sparql-query" bin)
1644 (symlink (string-append bin "/sparql-query")
1645 (string-append bin "/sparql-update")))
1648 (lambda* (#:key make-flags #:allow-other-keys)
1649 (apply invoke "make" `(,@make-flags "scan-test"))
1650 (invoke "./scan-test"))))))
1651 (home-page "https://github.com/tialaramex/sparql-query/")
1652 (synopsis "Command-line tool for accessing SPARQL endpoints over HTTP")
1653 (description "Sparql-query is a command-line tool for accessing SPARQL
1654 endpoints over HTTP. It has been intentionally designed to @code{feel} similar to
1655 tools for interrogating SQL databases. For example, you can enter a query over
1656 several lines, using a semi-colon at the end of a line to indicate the end of
1657 your query. It also supports readline so that you can more easily recall and
1658 edit previous queries, even across sessions. It can be used non-interactively,
1659 for example from a shell script.")
1660 ;; Some files (like scan-sparql.c) contain a GPLv3+ license header, while
1661 ;; others (like sparql-query.c) contain a GPLv2+ license header.
1662 (license (list license:gpl3+))))
1664 (define-public sqitch
1672 "mirror://cpan/authors/id/D/DW/DWHEELER/App-Sqitch-v"
1675 (base32 "1ayiwg9kh3w0nbacbcln7h944z94vq5vnnd5diz86033bpbnq57f"))))
1676 (build-system perl-build-system)
1679 (modify-phases %standard-phases
1680 (add-before 'check 'set-check-environment
1683 (setenv "HOME" "/tmp")
1685 (add-after 'install 'wrap-program
1686 (lambda* (#:key outputs #:allow-other-keys)
1687 (let* ((out (assoc-ref outputs "out"))
1688 (path (getenv "PERL5LIB")))
1689 (wrap-program (string-append out "/bin/sqitch")
1690 `("PERL5LIB" ":" prefix
1691 (,(string-append out "/lib/perl5/site_perl"
1696 `(("perl-capture-tiny" ,perl-capture-tiny)
1697 ("perl-io-pager" ,perl-io-pager)
1698 ("perl-module-build" ,perl-module-build)
1699 ("perl-module-runtime" ,perl-module-runtime)
1700 ("perl-path-class" ,perl-path-class)
1701 ("perl-test-deep" ,perl-test-deep)
1702 ("perl-test-dir" ,perl-test-dir)
1703 ("perl-test-exception" ,perl-test-exception)
1704 ("perl-test-file" ,perl-test-file)
1705 ("perl-test-file-contents" ,perl-test-file-contents)
1706 ("perl-test-mockmodule" ,perl-test-mockmodule)
1707 ("perl-test-mockobject" ,perl-test-mockobject)
1708 ("perl-test-nowarnings" ,perl-test-nowarnings)
1709 ("perl-test-warn" ,perl-test-warn)))
1711 `(("perl-class-xsaccessor" ,perl-class-xsaccessor)
1712 ("perl-clone" ,perl-clone)
1713 ("perl-config-gitlike" ,perl-config-gitlike)
1714 ("perl-datetime" ,perl-datetime)
1715 ("perl-datetime-timezone" ,perl-datetime-timezone)
1716 ("perl-dbd-mysql" ,perl-dbd-mysql)
1717 ("perl-dbd-pg" ,perl-dbd-pg)
1718 ("perl-dbd-sqlite" ,perl-dbd-sqlite)
1719 ("perl-dbi" ,perl-dbi)
1720 ("perl-devel-stacktrace" ,perl-devel-stacktrace)
1721 ("perl-encode-locale" ,perl-encode-locale)
1722 ("perl-hash-merge" ,perl-hash-merge)
1723 ("perl-ipc-run3" ,perl-ipc-run3)
1724 ("perl-ipc-system-simple" ,perl-ipc-system-simple)
1725 ("perl-libintl-perl" ,perl-libintl-perl)
1726 ("perl-list-moreutils" ,perl-list-moreutils)
1727 ("perl-moo" ,perl-moo)
1728 ("perl-mysql-config" ,perl-mysql-config)
1729 ("perl-namespace-autoclean" ,perl-namespace-autoclean)
1730 ("perl-path-class" ,perl-path-class)
1731 ("perl-perlio-utf8_strict" ,perl-perlio-utf8_strict)
1732 ("perl-string-formatter" ,perl-string-formatter)
1733 ("perl-string-shellquote" ,perl-string-shellquote)
1734 ("perl-sub-exporter" ,perl-sub-exporter)
1735 ("perl-template-tiny" ,perl-template-tiny)
1736 ("perl-template-toolkit" ,perl-template-toolkit)
1737 ("perl-throwable" ,perl-throwable)
1738 ("perl-try-tiny" ,perl-try-tiny)
1739 ("perl-type-tiny" ,perl-type-tiny)
1740 ("perl-type-tiny-xs" ,perl-type-tiny-xs)
1741 ("perl-uri" ,perl-uri)
1742 ("perl-uri-db" ,perl-uri-db)))
1743 (home-page "https://sqitch.org/")
1744 (synopsis "Database change management tool")
1746 "Sqitch is a standalone change management system for database schemas,
1747 which uses SQL to describe changes.")
1748 (license license:x11)))
1750 (define-public sqlcrush
1751 ;; Unfortunately, there is no proper upstream release and may never be.
1752 (let ((commit "b5f6868f189566a26eecc78d0f0659813c1aa98a")
1756 (version (git-version "0.1.5" revision commit))
1760 (url "https://github.com/coffeeandscripts/sqlcrush")
1762 (file-name (git-file-name name version))
1765 "0x3wy40r93p0jv3nbwj9a77wa4ff697d13r0wffmm7q9h3mzsww8"))))
1766 (build-system python-build-system)
1768 `(("python-cryptography" ,python-cryptography)
1769 ("python-psycopg2" ,python-psycopg2)
1770 ("python-pymysql" ,python-pymysql)
1771 ("python-sqlalchemy" ,python-sqlalchemy)))
1772 (home-page "https://github.com/coffeeandscripts/sqlcrush")
1773 (synopsis "Text console-based database viewer and editor")
1775 "SQLcrush lets you view and edit a database directly from the text
1776 console through an ncurses interface. You can explore each table's structure,
1777 browse and edit the contents, add and delete entries, all while tracking your
1779 (license license:gpl3+)))) ; no headers, see README.md
1787 (uri (string-append "https://www.samba.org/ftp/tdb/tdb-"
1791 "06waz0k50c7v3chd08mzp2rv7w4k4q9isbxx3vhlfpx1vy9q61f8"))))
1792 (build-system gnu-build-system)
1795 (modify-phases %standard-phases
1797 (lambda* (#:key outputs #:allow-other-keys)
1798 (let ((out (assoc-ref outputs "out")))
1799 ;; The 'configure' script is a wrapper for Waf and
1800 ;; doesn't recognize things like '--enable-fast-install'.
1801 (invoke "./configure"
1802 (string-append "--prefix=" out))))))))
1804 `(;; TODO: Build the documentation.
1805 ;; ("docbook-xsl" ,docbook-xsl)
1806 ;; ("libxml2" ,libxml2)
1807 ;; ("libxslt" ,libxslt)
1808 ("python" ,python) ;for the Waf build system
1810 (home-page "https://tdb.samba.org/")
1811 (synopsis "Trivial database")
1813 "TDB is a Trivial Database. In concept, it is very much like GDBM,
1814 and BSD's DB except that it allows multiple simultaneous writers and uses
1815 locking internally to keep writers from trampling on each other. TDB is also
1817 (license license:lgpl3+)))
1819 (define-public perl-dbi
1826 "mirror://cpan/authors/id/T/TI/TIMB/DBI-"
1830 "1yinx39960y241vf2sknxj0dfz82a5m9gvklq5rw78k0nlyrjawa"))))
1831 (build-system perl-build-system)
1832 (synopsis "Database independent interface for Perl")
1833 (description "This package provides an database interface for Perl.")
1834 (home-page "https://metacpan.org/release/DBI")
1835 (license license:perl-license)))
1837 (define-public perl-dbix-class
1839 (name "perl-dbix-class")
1840 (version "0.082842")
1844 (uri (string-append "mirror://cpan/authors/id/R/RI/RIBASUSHI/"
1845 "DBIx-Class-" version ".tar.gz"))
1847 (base32 "1rh7idjjbibc1zmiaaarask434lh0lx7f2xyfwmy37k9fa0xcpmh"))))
1848 (build-system perl-build-system)
1850 `(("perl-dbd-sqlite" ,perl-dbd-sqlite)
1851 ("perl-file-temp" ,perl-file-temp)
1852 ("perl-module-install" ,perl-module-install)
1853 ("perl-package-stash" ,perl-package-stash)
1854 ("perl-test-deep" ,perl-test-deep)
1855 ("perl-test-exception" ,perl-test-exception)
1856 ("perl-test-warn" ,perl-test-warn)))
1858 `(("perl-class-accessor-grouped" ,perl-class-accessor-grouped)
1859 ("perl-class-c3-componentised" ,perl-class-c3-componentised)
1860 ("perl-class-inspector" ,perl-class-inspector)
1861 ("perl-config-any" ,perl-config-any)
1862 ("perl-context-preserve" ,perl-context-preserve)
1863 ("perl-data-dumper-concise" ,perl-data-dumper-concise)
1864 ("perl-data-page" ,perl-data-page)
1865 ("perl-dbi" ,perl-dbi)
1866 ("perl-devel-globaldestruction" ,perl-devel-globaldestruction)
1867 ("perl-hash-merge" ,perl-hash-merge)
1868 ("perl-module-find" ,perl-module-find)
1869 ("perl-moo" ,perl-moo)
1870 ("perl-mro-compat" ,perl-mro-compat)
1871 ("perl-namespace-clean" ,perl-namespace-clean)
1872 ("perl-path-class" ,perl-path-class)
1873 ("perl-scalar-list-utils" ,perl-scalar-list-utils)
1874 ("perl-scope-guard" ,perl-scope-guard)
1875 ("perl-sql-abstract-classic" ,perl-sql-abstract-classic)
1876 ("perl-sub-name" ,perl-sub-name)
1877 ("perl-text-balanced" ,perl-text-balanced)
1878 ("perl-try-tiny" ,perl-try-tiny)))
1879 (home-page "https://metacpan.org/release/DBIx-Class")
1880 (synopsis "Extensible and flexible object <-> relational mapper")
1881 (description "An SQL to OO mapper with an object API inspired by
1882 Class::DBI (with a compatibility layer as a springboard for porting) and a
1883 resultset API that allows abstract encapsulation of database operations. It
1884 aims to make representing queries in your code as perl-ish as possible while
1885 still providing access to as many of the capabilities of the database as
1886 possible, including retrieving related records from multiple tables in a
1887 single query, \"JOIN\", \"LEFT JOIN\", \"COUNT\", \"DISTINCT\", \"GROUP BY\",
1888 \"ORDER BY\" and \"HAVING\" support.")
1889 (license license:perl-license)))
1891 (define-public perl-dbix-class-cursor-cached
1893 (name "perl-dbix-class-cursor-cached")
1894 (version "1.001004")
1898 (uri (string-append "mirror://cpan/authors/id/A/AR/ARCANEZ/"
1899 "DBIx-Class-Cursor-Cached-" version ".tar.gz"))
1902 "09b2jahn2x12qm4f7qm1jzsxbz7qn1czp6a3fnl5l2i3l4r5421p"))))
1903 (build-system perl-build-system)
1905 `(("perl-cache-cache" ,perl-cache-cache)
1906 ("perl-dbd-sqlite" ,perl-dbd-sqlite)
1907 ("perl-module-install" ,perl-module-install)))
1909 `(("perl-carp-clan" ,perl-carp-clan)
1910 ("perl-dbix-class" ,perl-dbix-class)))
1911 (home-page "https://metacpan.org/release/DBIx-Class-Cursor-Cached")
1912 (synopsis "Cursor with built-in caching support")
1913 (description "DBIx::Class::Cursor::Cached provides a cursor class with
1914 built-in caching support.")
1915 (license license:perl-license)))
1917 (define-public perl-dbix-class-introspectablem2m
1919 (name "perl-dbix-class-introspectablem2m")
1920 (version "0.001002")
1924 (uri (string-append "mirror://cpan/authors/id/I/IL/ILMARI/"
1925 "DBIx-Class-IntrospectableM2M-" version ".tar.gz"))
1928 "1w47rh2241iy5x3a9bqsyd5kdp9sk43dksr99frzv4qn4jsazfn6"))))
1929 (build-system perl-build-system)
1931 `(("perl-module-install" ,perl-module-install)))
1933 `(("perl-dbix-class" ,perl-dbix-class)))
1934 (home-page "https://metacpan.org/release/DBIx-Class-IntrospectableM2M")
1935 (synopsis "Introspect many-to-many relationships")
1936 (description "Because the many-to-many relationships are not real
1937 relationships, they can not be introspected with DBIx::Class. Many-to-many
1938 relationships are actually just a collection of convenience methods installed
1939 to bridge two relationships. This DBIx::Class component can be used to store
1940 all relevant information about these non-relationships so they can later be
1941 introspected and examined.")
1942 (license license:perl-license)))
1944 (define-public perl-dbix-class-schema-loader
1946 (name "perl-dbix-class-schema-loader")
1951 (uri (string-append "mirror://cpan/authors/id/I/IL/ILMARI/"
1952 "DBIx-Class-Schema-Loader-" version ".tar.gz"))
1955 "0r57fv71ypxafb85cpxph1hdqii7ipjwvc19yb6fpkvq2ggcssg8"))))
1956 (build-system perl-build-system)
1958 `(("perl-config-any" ,perl-config-any)
1959 ("perl-config-general" ,perl-config-general)
1960 ("perl-dbd-sqlite" ,perl-dbd-sqlite)
1961 ("perl-dbix-class-introspectablem2m" ,perl-dbix-class-introspectablem2m)
1962 ("perl-module-install" ,perl-module-install)
1963 ("perl-moose" ,perl-moose)
1964 ("perl-moosex-markasmethods" ,perl-moosex-markasmethods)
1965 ("perl-moosex-nonmoose" ,perl-moosex-nonmoose)
1966 ("perl-namespace-autoclean" ,perl-namespace-autoclean)
1967 ("perl-test-deep" ,perl-test-deep)
1968 ("perl-test-differences" ,perl-test-differences)
1969 ("perl-test-exception" ,perl-test-exception)
1970 ("perl-test-pod" ,perl-test-pod)
1971 ("perl-test-warn" ,perl-test-warn)))
1973 `(("perl-class-unload" ,perl-class-unload)
1974 ("perl-class-inspector" ,perl-class-inspector)
1975 ("perl-class-accessor-grouped" ,perl-class-accessor-grouped)
1976 ("perl-class-c3-componentised" ,perl-class-c3-componentised)
1977 ("perl-carp-clan" ,perl-carp-clan)
1978 ("perl-data-dump" ,perl-data-dump)
1979 ("perl-dbix-class" ,perl-dbix-class)
1980 ("perl-hash-merge" ,perl-hash-merge)
1981 ("perl-list-moreutils" ,perl-list-moreutils)
1982 ("perl-lingua-en-inflect-phrase" ,perl-lingua-en-inflect-phrase)
1983 ("perl-lingua-en-inflect-number" ,perl-lingua-en-inflect-number)
1984 ("perl-lingua-en-tagger" ,perl-lingua-en-tagger)
1985 ("perl-namespace-clean" ,perl-namespace-clean)
1986 ("perl-mro-compat" ,perl-mro-compat)
1987 ("perl-scope-guard" ,perl-scope-guard)
1988 ("perl-string-camelcase" ,perl-string-camelcase)
1989 ("perl-string-toidentifier-en" ,perl-string-toidentifier-en)
1990 ("perl-sub-name" ,perl-sub-name)
1991 ("perl-try-tiny" ,perl-try-tiny)))
1992 (arguments `(#:tests? #f)) ;TODO: t/20invocations.t fails
1993 (home-page "https://metacpan.org/release/DBIx-Class-Schema-Loader")
1994 (synopsis "Create a DBIx::Class::Schema based on a database")
1995 (description "DBIx::Class::Schema::Loader automates the definition of a
1996 DBIx::Class::Schema by scanning database table definitions and setting up the
1997 columns, primary keys, unique constraints and relationships.")
1998 (license license:perl-license)))
2000 (define-public perl-dbd-pg
2002 (name "perl-dbd-pg")
2007 (uri (string-append "mirror://cpan/authors/id/T/TU/TURNSTEP/"
2008 "DBD-Pg-" version ".tar.gz"))
2011 "0gkqlvbmzbdm0g4k328nlkjdg3wrjm5i2n9jxj1i8sqxkm79rylz"))))
2012 (build-system perl-build-system)
2014 `(("perl-dbi" ,perl-dbi)))
2016 `(("perl-dbi" ,perl-dbi)
2017 ("postgresql" ,postgresql)))
2018 (home-page "https://metacpan.org/release/DBD-Pg")
2019 (synopsis "DBI PostgreSQL interface")
2020 (description "This package provides a PostgreSQL driver for the Perl5
2021 @dfn{Database Interface} (DBI).")
2022 (license license:perl-license)))
2024 (define-public perl-dbd-mysql
2026 (name "perl-dbd-mysql")
2031 (uri (string-append "mirror://cpan/authors/id/D/DV/DVEEDEN/"
2032 "DBD-mysql-" version ".tar.gz"))
2034 (base32 "0y4djb048i09dk19av7mzfb3khr72vw11p3ayw2p82jsy4gm8j2g"))))
2035 (build-system perl-build-system)
2038 (modify-phases %standard-phases
2039 (add-before 'configure 'skip-library-detection
2040 ;; Avoid depencies on perl-devel-checklib, openssl, and zlib. They
2041 ;; are really only needed for the test suite; their absence does not
2042 ;; affect the build or the end result.
2044 (substitute* "Makefile.PL"
2045 (("use Devel::CheckLib;" match)
2046 (string-append "# " match))
2050 ;; Tests require running MySQL server.
2053 `(("perl-dbi" ,perl-dbi)
2054 ("mysql" ,mariadb "lib")
2055 ("mysql-dev" ,mariadb "dev")))
2056 (home-page "https://metacpan.org/release/DBD-mysql")
2057 (synopsis "DBI MySQL interface")
2058 (description "This package provides a MySQL driver for the Perl5
2059 @dfn{Database Interface} (DBI).")
2060 (license license:perl-license)))
2062 (define-public perl-dbd-sqlite
2064 (name "perl-dbd-sqlite")
2069 "mirror://cpan/authors/id/I/IS/ISHIGAKI/DBD-SQLite-"
2073 "1zljln5nh61gj3k22a1fv2vhx5l83waizmarwkh77hk6kzzmvrw9"))))
2074 (build-system perl-build-system)
2075 (inputs `(("sqlite" ,sqlite)))
2076 (propagated-inputs `(("perl-dbi" ,perl-dbi)))
2077 (synopsis "SQlite interface for Perl")
2078 (description "DBD::SQLite is a Perl DBI driver for SQLite, that includes
2079 the entire thing in the distribution. So in order to get a fast transaction
2080 capable RDBMS working for your Perl project you simply have to install this
2081 module, and nothing else.")
2082 (license license:perl-license)
2083 (home-page "https://metacpan.org/release/DBD-SQLite")))
2085 (define-public perl-mysql-config
2087 (name "perl-mysql-config")
2093 "mirror://cpan/authors/id/D/DA/DARREN/MySQL-Config-"
2098 "1svn7ccw2gc4cazvc58j84rxhnc9vs01zpird0l8460598j475qr"))))
2099 (build-system perl-build-system)
2100 (home-page "https://metacpan.org/release/MySQL-Config")
2101 (synopsis "Parse and utilize MySQL's /etc/my.cnf and ~/.my.cnf files")
2103 "@code{MySQL::Config} emulates the @code{load_defaults} function from
2104 libmysqlclient. It will fill an array with long options, ready to be parsed by
2105 @code{Getopt::Long}.")
2106 (license license:perl-license)))
2108 (define-public perl-sql-abstract
2110 (name "perl-sql-abstract")
2115 (uri (string-append "mirror://cpan/authors/id/I/IL/ILMARI/"
2116 "SQL-Abstract-" version ".tar.gz"))
2118 (base32 "0jhw91b23wc9bkfwcgvka4x5ddxk58m9bcp5ay7a3vx77nla09p9"))))
2119 (build-system perl-build-system)
2121 `(("perl-module-install" ,perl-module-install)
2122 ("perl-test-deep" ,perl-test-deep)
2123 ("perl-test-exception" ,perl-test-exception)
2124 ("perl-test-warn" ,perl-test-warn)))
2126 `(("perl-hash-merge" ,perl-hash-merge)
2127 ("perl-moo" ,perl-moo)
2128 ("perl-mro-compat" ,perl-mro-compat)
2129 ("perl-text-balanced" ,perl-text-balanced)))
2130 (home-page "https://metacpan.org/release/SQL-Abstract")
2131 (synopsis "Generate SQL from Perl data structures")
2132 (description "This module was inspired by the excellent DBIx::Abstract.
2133 While based on the concepts used by DBIx::Abstract, the concepts used have
2134 been modified to make the SQL easier to generate from Perl data structures.
2135 The underlying idea is for this module to do what you mean, based on the data
2136 structures you provide it, so that you don't have to modify your code every
2137 time your data changes.")
2138 (license license:perl-license)))
2140 (define-public perl-sql-abstract-classic
2142 (name "perl-sql-abstract-classic")
2147 (uri (string-append "mirror://cpan/authors/id/R/RI/RIBASUSHI/"
2148 "SQL-Abstract-Classic-" version ".tar.gz"))
2150 (base32 "0a7g13hs3kdxrjn43sfli09mgsi9d6w0dfw6hlk268av17yisgaf"))))
2151 (build-system perl-build-system)
2153 `(("perl-test-deep" ,perl-test-deep)
2154 ("perl-test-exception" ,perl-test-exception)
2155 ("perl-test-warn" ,perl-test-warn)))
2157 `(("perl-mro-compat" ,perl-mro-compat)
2158 ("perl-sql-abstract" ,perl-sql-abstract)))
2159 (home-page "https://metacpan.org/release/SQL-Abstract-Classic")
2160 (synopsis "Generate SQL from Perl data structures")
2162 "This module is nearly identical to @code{SQL::Abstract} 1.81, and exists
2163 to preserve the ability of users to opt into the new way of doing things in
2164 later versions according to their own schedules.
2166 It is an abstract SQL generation module based on the concepts used by
2167 @code{DBIx::Abstract}, with several important differences, especially when it
2168 comes to @code{WHERE} clauses. These concepts were modified to make the SQL
2169 easier to generate from Perl data structures.
2171 The underlying idea is for this module to do what you mean, based on the data
2172 structures you provide it. You shouldn't have to modify your code every time
2173 your data changes, as this module figures it out.")
2174 (license license:perl-license)))
2176 (define-public perl-sql-splitstatement
2178 (name "perl-sql-splitstatement")
2183 (uri (string-append "mirror://cpan/authors/id/E/EM/EMAZEP/"
2184 "SQL-SplitStatement-" version ".tar.gz"))
2187 "0bqg45k4c9qkb2ypynlwhpvzsl4ssfagmsalys18s5c79ps30z7p"))))
2188 (build-system perl-build-system)
2190 `(("perl-test-exception" ,perl-test-exception)))
2192 `(("perl-class-accessor" ,perl-class-accessor)
2193 ("perl-list-moreutils" ,perl-list-moreutils)
2194 ("perl-regexp-common" ,perl-regexp-common)
2195 ("perl-sql-tokenizer" ,perl-sql-tokenizer)))
2196 (home-page "https://metacpan.org/release/SQL-SplitStatement")
2197 (synopsis "Split SQL code into atomic statements")
2198 (description "This module tries to split any SQL code, even including
2199 non-standard extensions, into the atomic statements it is composed of.")
2200 (license license:perl-license)))
2202 (define-public perl-sql-tokenizer
2204 (name "perl-sql-tokenizer")
2209 (uri (string-append "mirror://cpan/authors/id/I/IZ/IZUT/"
2210 "SQL-Tokenizer-" version ".tar.gz"))
2213 "1qa2dfbzdlr5qqdam9yn78z5w3al5r8577x06qan8wv58ay6ka7s"))))
2214 (build-system perl-build-system)
2215 (home-page "https://metacpan.org/release/SQL-Tokenizer")
2216 (synopsis "SQL tokenizer")
2217 (description "SQL::Tokenizer is a tokenizer for SQL queries. It does not
2218 claim to be a parser or query verifier. It just creates sane tokens from a
2220 (license license:perl-license)))
2222 (define-public unixodbc
2230 "ftp://ftp.unixodbc.org/pub/unixODBC/unixODBC-"
2233 (base32 "01xj65d02i3yjy7p9z08y9jakcs5szmz4rask868n7387nn3x0sj"))))
2234 (build-system gnu-build-system)
2235 (synopsis "Data source abstraction library")
2236 (description "Unixodbc is a library providing an API with which to access
2237 data sources. Data sources include SQL Servers and any software with an ODBC
2239 (license license:lgpl2.1+)
2240 ;; COPYING contains copy of lgpl2.1 - but copyright notices just say "LGPL"
2241 (home-page "http://www.unixodbc.org")))
2243 (define-public unqlite
2249 ;; Contains bug fixes against the official release, and has an
2250 ;; autotooled build system.
2251 (uri (string-append "https://github.com/aidin36/tocc/releases/"
2253 "unqlite-unofficial-" version ".tar.gz"))
2256 "1sbpvhg15gadq0mpcy16q7k3rkg4b4dicpnn5xifpkpn02sqik3s"))))
2257 (build-system gnu-build-system)
2258 (arguments `(#:tests? #f)) ;No check target
2259 (home-page "https://www.unqlite.org")
2260 (synopsis "In-memory key/value and document store")
2262 "UnQLite is an in-process software library which implements a
2263 self-contained, serverless, zero-configuration, transactional NoSQL
2264 database engine. UnQLite is a document store database similar to
2265 MongoDB, Redis, CouchDB, etc. as well as a standard Key/Value store
2266 similar to BerkeleyDB, LevelDB, etc.")
2267 (license license:bsd-2)))
2269 (define-public redis
2275 (uri (string-append "http://download.redis.io/releases/redis-"
2279 "0prwqap452m581nyc3cz642d1z3x9nd81896hlqdm3z8238z49y9"))
2280 (modules '((guix build utils)))
2282 ;; Delete bundled jemalloc, as the package will use the libc one
2283 '(begin (delete-file-recursively "deps/jemalloc")
2285 (build-system gnu-build-system)
2287 `(("procps" ,procps) ; for tests
2288 ("tcl" ,tcl))) ; for tests
2291 (modify-phases %standard-phases
2293 (add-after 'unpack 'use-correct-tclsh
2294 (lambda* (#:key inputs #:allow-other-keys)
2295 (substitute* "runtest"
2297 (string-append "TCLSH="
2298 (assoc-ref inputs "tcl")
2301 (add-after 'unpack 'adjust-tests
2303 ;; Disable failing tests
2304 (substitute* "tests/test_helper.tcl"
2305 ((" integration/replication[^-]") "")
2306 ((" integration/replication-4") "")
2307 ((" integration/replication-psync") ""))
2309 #:make-flags `("CC=gcc"
2312 ,(string-append "PREFIX="
2313 (assoc-ref %outputs "out")))))
2314 (synopsis "Key-value cache and store")
2315 (description "Redis is an advanced key-value cache and store. Redis
2316 supports many data structures including strings, hashes, lists, sets, sorted
2317 sets, bitmaps and hyperloglogs.")
2318 (home-page "https://redis.io/")
2319 (license license:bsd-3)))
2321 (define-public kyotocabinet
2323 (name "kyotocabinet")
2327 (uri (string-append "https://fallabs.com/kyotocabinet/pkg/"
2328 "kyotocabinet-" version ".tar.gz"))
2331 "079ymsahlrijswgwfr2la9yw5h57l752cprhp5dz31iamsj1vyv7"))))
2332 (build-system gnu-build-system)
2336 "--disable-opt" ;"-march=native". XXX this also turns off -O0.
2337 (string-append "LDFLAGS=-Wl,-rpath="
2338 (assoc-ref %outputs "out") "/lib"))))
2339 (inputs `(("zlib" ,zlib)))
2340 (home-page "https://fallabs.com/kyotocabinet/")
2342 "Kyoto Cabinet is a modern implementation of the DBM database")
2344 "Kyoto Cabinet is a standalone file-based database that supports Hash
2345 and B+ Tree data storage models. It is a fast key-value lightweight
2346 database and supports many programming languages. It is a NoSQL database.")
2347 (license license:gpl3+)))
2349 (define-public tokyocabinet
2351 (name "tokyocabinet")
2356 (uri (string-append "http://fallabs.com/tokyocabinet/"
2357 name "-" version ".tar.gz"))
2360 "140zvr0n8kvsl0fbn2qn3f2kh3yynfwnizn4dgbj47m975yg80x0"))))
2361 (build-system gnu-build-system)
2364 (list "--enable-pthread" "--enable-off64" "--enable-fastest"
2365 (string-append "LDFLAGS=-Wl,-rpath="
2366 (assoc-ref %outputs "out") "/lib"))))
2369 (home-page "http://fallabs.com/tokyocabinet/")
2370 (synopsis "Tokyo Cabinet is a modern implementation of the DBM database")
2372 "Tokyo Cabinet is a library of routines for managing a database.
2373 The database is a simple data file containing records, each is a pair of a
2374 key and a value. Every key and value is serial bytes with variable length.
2375 Both binary data and character string can be used as a key and a value.
2376 There is neither concept of data tables nor data types. Records are
2377 organized in hash table, B+ tree, or fixed-length array.")
2378 (license license:lgpl2.1+)))
2380 (define-public wiredtiger
2387 "http://source.wiredtiger.com/releases/wiredtiger-"
2388 version ".tar.bz2"))
2391 "0krwnb2zfbhvjaskwl875qzd3y626s84zcciq2mxr5c5riw3yh6s"))))
2392 (build-system gnu-build-system)
2394 '(#:configure-flags '("--enable-lz4" "--with-builtins=snappy,zlib")
2396 (modify-phases %standard-phases
2397 (add-before 'check 'disable-test/fops
2399 ;; XXX: timed out after 3600 seconds of silence
2400 (substitute* "Makefile"
2406 ("snappy" ,snappy)))
2407 (home-page "http://source.wiredtiger.com/")
2408 (synopsis "NoSQL data engine")
2410 "WiredTiger is an extensible platform for data management. It supports
2411 row-oriented storage (where all columns of a row are stored together),
2412 column-oriented storage (where columns are stored in groups, allowing for
2413 more efficient access and storage of column subsets) and log-structured merge
2414 trees (LSM), for sustained throughput under random insert workloads.")
2415 (license license:gpl3) ; or GPL-2
2416 ;; configure.ac: WiredTiger requires a 64-bit build.
2417 (supported-systems '("x86_64-linux" "mips64el-linux" "aarch64-linux"))))
2419 (define-public wiredtiger-3
2421 (inherit wiredtiger)
2426 (uri (string-append "http://source.wiredtiger.com/releases/wiredtiger-"
2427 version ".tar.bz2"))
2430 "014awypv579ascg4jbx4pndj2wld337m79yyzrzyr7hxrff139jx"))))))
2432 (define-public guile-wiredtiger
2434 (name "guile-wiredtiger")
2439 (url "https://framagit.org/a-guile-mind/guile-wiredtiger.git")
2440 (commit "340ad4bc2ff4dcc6216a2f5c6f9172ca320ac66b")))
2441 (file-name (string-append name "-" version "-checkout"))
2444 "15j36bvxxzil7qpwlmh1rffqpva3ynvrcpqhhqbj2c9208ayz595"))))
2445 (build-system gnu-build-system)
2447 '(#:parallel-tests? #f ;; tests can't be run in parallel, yet.
2449 (list (string-append "--with-libwiredtiger-prefix="
2450 (assoc-ref %build-inputs "wiredtiger")))
2451 #:make-flags '("GUILE_AUTO_COMPILE=0")))
2453 `(("autoconf" ,autoconf)
2454 ("automake" ,automake)
2455 ("pkg-config" ,pkg-config)))
2457 `(("wiredtiger" ,wiredtiger-3)
2458 ("guile" ,guile-2.2)))
2460 `(("guile-bytestructures" ,guile-bytestructures)))
2461 (synopsis "WiredTiger bindings for GNU Guile")
2463 "This package provides Guile bindings to the WiredTiger ``NoSQL''
2465 (home-page "https://framagit.org/a-guile-mind/guile-wiredtiger")
2466 (license license:gpl3+)))
2468 (define-public perl-db-file
2470 (name "perl-db-file")
2475 (uri (string-append "mirror://cpan/authors/id/P/PM/PMQS/DB_File-"
2478 (base32 "0q599h7g4jkzks5dxf1zifx9k7l9vif26r2dlgkzxkg6bfif5zyr"))))
2479 (build-system perl-build-system)
2480 (inputs `(("bdb" ,bdb)))
2481 (native-inputs `(("perl-test-pod" ,perl-test-pod)))
2483 `(#:phases (modify-phases %standard-phases
2485 'configure 'modify-config.in
2486 (lambda* (#:key inputs #:allow-other-keys)
2487 (substitute* "config.in"
2488 (("/usr/local/BerkeleyDB") (assoc-ref inputs "bdb")))
2490 (home-page "https://metacpan.org/release/DB_File")
2491 (synopsis "Perl5 access to Berkeley DB version 1.x")
2493 "The DB::File module provides Perl bindings to the Berkeley DB version 1.x.")
2494 (license license:perl-license)))
2504 (url "https://git.openldap.org/openldap/openldap.git")
2505 (commit (string-append "LMDB_" version))))
2506 (file-name (git-file-name name version))
2508 (base32 "012a8bs49cswsnzw7k4piis5b6dn4by85w7a7mai9i04xcjyy9as"))))
2509 (build-system gnu-build-system)
2511 `(#:test-target "test"
2513 (modify-phases %standard-phases
2515 (lambda* (#:key outputs #:allow-other-keys)
2516 (chdir "libraries/liblmdb")
2517 (substitute* "Makefile"
2518 (("/usr/local") (assoc-ref outputs "out")))
2520 (add-after 'install 'create-pkg-config-file
2521 (lambda* (#:key outputs #:allow-other-keys)
2522 (let ((out (assoc-ref outputs "out")))
2523 (mkdir-p (string-append out "/lib/pkgconfig"))
2524 (with-output-to-file (string-append out "/lib/pkgconfig/liblmdb.pc")
2526 (format #t "prefix=~a~@
2529 includedir=~a/include~@
2533 Description: Lightning Memory-Mapped Database library~@
2534 Libs: -L${libdir} -llmdb~@
2535 Cflags: -I${includedir}~%"
2536 out out out out ,version)))
2538 (home-page "https://symas.com/lmdb/")
2539 (synopsis "Lightning Memory-Mapped Database library")
2541 "The @dfn{Lightning Memory-Mapped Database} (LMDB) is a high-performance
2542 transactional database. Unlike more complex relational databases, LMDB handles
2543 only key-value pairs (stored as arbitrary byte arrays) and relies on the
2544 underlying operating system for caching and locking, keeping the code small and
2546 The use of ‘zero-copy’ memory-mapped files combines the persistence of classic
2547 disk-based databases with high read performance that scales linearly over
2548 multiple cores. The size of each database is limited only by the size of the
2549 virtual address space — not physical RAM.")
2550 (license license:openldap2.8)))
2552 (define-public lmdbxx
2555 (version "0.9.14.0")
2560 (url "https://github.com/drycpp/lmdbxx")
2562 (file-name (git-file-name name version))
2564 (base32 "1jmb9wg2iqag6ps3z71bh72ymbcjrb6clwlkgrqf1sy80qwvlsn6"))))
2567 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
2569 (modify-phases %standard-phases
2570 (delete 'configure))))
2571 (build-system gnu-build-system)
2572 (inputs `(("lmdb" ,lmdb)))
2573 (home-page "http://lmdbxx.sourceforge.net")
2574 (synopsis "C++11 wrapper for the LMDB embedded B+ tree database library")
2575 (description "@code{lmdbxx} is a comprehensive @code{C++} wrapper for the
2576 @code{LMDB} embedded database library, offering both an error-checked
2577 procedural interface and an object-oriented resource interface with RAII
2579 (license license:unlicense)))
2581 (define-public libpqxx
2588 "http://pqxx.org/download/software/libpqxx/"
2589 name "-" version ".tar.gz"))
2592 "0f6wxspp6rx12fkasanb0z2g2gc8dhcfwnxagx8wwqbpg6ifsz09"))))
2593 (build-system gnu-build-system)
2595 `(("python" ,python-2)))
2596 (inputs `(("postgresql" ,postgresql)))
2598 `(#:tests? #f ; # FAIL: 1
2600 (modify-phases %standard-phases
2601 (add-before 'configure 'fix-sed-command
2603 ;; Newer sed versions error out if double brackets are not used.
2604 (substitute* "configure"
2605 (("\\[:space:\\]") "[[:space:]]"))
2607 (synopsis "C++ connector for PostgreSQL")
2609 "Libpqxx is a C++ library to enable user programs to communicate with the
2610 PostgreSQL database back-end. The database back-end can be local or it may be
2611 on another machine, accessed via TCP/IP.")
2612 (home-page "http://pqxx.org/")
2613 (license license:bsd-3)))
2615 (define-public python-peewee
2617 (name "python-peewee")
2622 (uri (pypi-uri "peewee" version))
2624 (base32 "1yl49gxrg0c2x3n3r60z3lixw9am8b61s0477l9vjabhhx1yziar"))))
2625 (build-system python-build-system)
2627 `(#:tests? #f)) ; fails to import test data
2629 `(("sqlite" ,sqlite)))
2631 `(("python-cython" ,python-cython)))
2632 (home-page "https://github.com/coleifer/peewee/")
2633 (synopsis "Small object-relational mapping utility")
2635 "Peewee is a simple and small ORM (object-relation mapping) tool. Peewee
2636 handles converting between pythonic values and those used by databases, so you
2637 can use Python types in your code without having to worry. It has built-in
2638 support for sqlite, mysql and postgresql. If you already have a database, you
2639 can autogenerate peewee models using @code{pwiz}, a model generator.")
2640 (license license:expat)))
2642 (define-public python2-peewee
2643 (package-with-python2 python-peewee))
2645 (define-public python-tortoise-orm
2647 (name "python-tortoise-orm")
2652 (uri (pypi-uri "tortoise-orm" version))
2655 "1dallk0q8q4v37klm0v3rppf2w8sjkqmypc1w8r9rraqxg1ylacp"))))
2656 (build-system python-build-system)
2658 `(#:tests? #f ; Pypi does not have tests and Git snapshot depends on
2660 #:phases (modify-phases %standard-phases
2661 (add-after 'unpack 'relax-version-requirements
2663 (substitute* "setup.py"
2664 (("pypika>=0\\.44\\.0,<0\\.45\\.0") "pypika")
2665 (("aiosqlite>=0.16.0,<0.17.0") "aiosqlite"))
2668 `(("python-asynctest" ,python-asynctest)
2669 ("python-nose2" ,python-nose2)))
2671 `(("python-aiosqlite" ,python-aiosqlite)
2672 ("python-pypika" ,python-pypika)
2673 ("python-ciso8601" ,python-ciso8601)
2674 ("python-typing-extensions"
2675 ,python-typing-extensions)))
2677 "https://github.com/tortoise/tortoise-orm")
2679 "Easy async ORM for python, built with relations in mind")
2681 "Tortoise ORM is an easy-to-use asyncio ORM (Object Relational Mapper)
2682 inspired by Django. Tortoise ORM was build with relations in mind and
2683 admiration for the excellent and popular Django ORM. It’s engraved in its
2684 design that you are working not with just tables, you work with relational
2686 (license license:asl2.0)))
2688 (define-public sqlcipher
2695 (uri (string-append "https://github.com/sqlcipher/" name
2696 "/archive/v" version ".tar.gz"))
2698 (base32 "1nxarwbci8jx99f1d0y1ivxcv25s78l1p7q6qy28lkpkcx8pm2b9"))
2699 (file-name (string-append name "-" version ".tar.gz"))))
2700 (build-system gnu-build-system)
2702 `(("libcrypto" ,openssl)
2703 ("libtcl8.6" ,tcl))) ; required for running the tests
2708 '("--enable-tempstore=yes"
2709 "CFLAGS=-DSQLITE_HAS_CODEC -DSQLITE_ENABLE_FTS3"
2710 "LDFLAGS=-lcrypto -ltcl8.6"
2712 ;; tests cannot be run from the Makefile
2713 ;; see: <https://github.com/sqlcipher/sqlcipher/issues/172>
2714 #:test-target "testfixture"
2716 (modify-phases %standard-phases
2717 (add-before 'check 'build-test-runner
2718 (assoc-ref %standard-phases 'check))
2721 (invoke "./testfixture" "test/crypto.test"))))))
2722 (home-page "https://www.zetetic.net/sqlcipher/")
2724 "Library providing transparent encryption of SQLite database files")
2725 (description "SQLCipher is an implementation of SQLite, extended to
2726 provide transparent 256-bit AES encryption of database files. Pages are
2727 encrypted before being written to disk and are decrypted when read back. It’s
2728 well suited for protecting embedded application databases and for mobile
2731 ;; src/{crypto.c,crypto_impl.c,crypto.h,crypto_cc.c,crypto_libtomcrypt.c},
2732 ;; src/{crypto_openssl.c,sqlcipher.h}, tool/crypto-speedtest.tcl,
2733 ;; test/crypto.test are licensed under a 3-clause BSD license. All other
2734 ;; source files are in the public domain.
2735 (license (list license:public-domain license:bsd-3))))
2737 (define-public python-pyodbc-c
2739 (name "python-pyodbc-c")
2744 (uri (string-append "https://gitlab.com/daym/pyodbc-c/repository/"
2745 "archive.tar.gz?ref=v" version))
2748 "05aq2297k779xidmxcwkrrxjvj1bh2q7d9a1rcjv6zr15y764ga9"))
2749 (file-name (string-append name "-" version ".tar.gz"))))
2750 (build-system python-build-system)
2752 `(("unixodbc" ,unixodbc)))
2754 `(;; No unit tests exist.
2756 (home-page "https://github.com/mkleehammer/pyodbc")
2757 (synopsis "Python ODBC Library")
2758 (description "@code{python-pyodbc-c} provides a Python DB-API driver
2760 (license (license:x11-style "file://LICENSE.TXT"))))
2762 (define-public python2-pyodbc-c
2763 (package-with-python2 python-pyodbc-c))
2765 (define-public python-pyodbc
2767 (name "python-pyodbc")
2772 (uri (pypi-uri "pyodbc" version))
2774 (base32 "0skjpraar6hcwsy82612bpj8nw016ncyvvq88j5syrikxgp5saw5"))
2775 (file-name (string-append name "-" version ".tar.gz"))))
2776 (build-system python-build-system)
2778 `(("unixodbc" ,unixodbc)))
2780 `(#:tests? #f)) ; no unit tests exist
2781 (home-page "https://github.com/mkleehammer/pyodbc")
2782 (synopsis "Python ODBC Library")
2783 (description "@code{python-pyodbc} provides a Python DB-API driver
2785 (license (license:x11-style "file:///LICENSE.TXT"))))
2787 (define-public python2-pyodbc
2788 (package-with-python2 python-pyodbc))
2790 (define-public mdbtools
2798 (url "https://github.com/brianb/mdbtools")
2800 (file-name (git-file-name name version))
2803 "0gwcpp9y09xhs21g7my2fs8ncb8i6ahlyixcx8jd3q97jbzj441l"))))
2804 (build-system gnu-build-system)
2808 `(("autoconf" ,autoconf)
2809 ("automake" ,automake)
2810 ("libtool" ,libtool)
2811 ("pkg-config" ,pkg-config)
2812 ("txt2man" ,txt2man)
2814 (home-page "http://mdbtools.sourceforge.net/")
2815 (synopsis "Read Microsoft Access databases")
2816 (description "MDB Tools is a set of tools and applications to read the
2817 proprietary MDB file format used in Microsoft's Access database package. This
2818 includes programs to export schema and data from Microsoft's Access database
2819 file format to other databases such as MySQL, Oracle, Sybase, PostgreSQL,
2820 etc., and an SQL engine for performing simple SQL queries.")
2821 (license (list license:lgpl2.0
2824 (define-public python-lmdb
2826 (name "python-lmdb")
2830 (uri (pypi-uri "lmdb" version))
2833 "1di1gj2agbxwqqwrpk4w58dpfah0kl10ha20s63dlqdd1bgzydj1"))
2834 (modules '((guix build utils)))
2836 ;; Delete bundled lmdb source files.
2838 (for-each delete-file (list "lib/lmdb.h"
2843 (build-system python-build-system)
2848 (modify-phases %standard-phases
2849 (add-before 'build 'use-system-lmdb
2850 (lambda* (#:key inputs #:allow-other-keys)
2851 (let ((lmdb (assoc-ref inputs "lmdb")))
2852 (setenv "LMDB_PURE" "set") ; don't apply env-copy-txn.patch
2853 (setenv "LMDB_FORCE_SYSTEM" "set")
2854 (setenv "LMDB_INCLUDEDIR" (string-append lmdb "/include"))
2855 (setenv "LMDB_LIBDIR" (string-append lmdb "/lib"))
2857 ;; Tests fail with: ‘lmdb.tool: Please specify environment (--env)’.
2859 (home-page "https://github.com/dw/py-lmdb")
2860 (synopsis "Python binding for the ‘Lightning’ database (LMDB)")
2862 "python-lmdb or py-lmdb is a Python binding for the @dfn{Lightning
2863 Memory-Mapped Database} (LMDB), a high-performance key-value store.")
2865 (list license:openldap2.8
2866 ;; ‘lib/win32/inttypes.h’ and ‘lib/win32-stdint/stdint.h’ are BSD-3,
2867 ;; but not actually needed on platforms currently supported by Guix.
2870 (define-public python-orator
2872 (name "python-orator")
2876 (uri (pypi-uri "orator" version))
2879 "0mbgybz63ryhr9p1f4glnls5c57jp6il3dw0kf97f3pj80687rvg"))))
2880 (build-system python-build-system)
2881 ;; FIXME: Tests are not distributed with PyPI, and the repository
2882 ;; does not contain setup.py. How to test?
2883 (arguments '(#:tests? #f))
2885 `(("python-backpack" ,python-backpack)
2886 ("python-blinker" ,python-blinker)
2887 ("python-cleo" ,python-cleo)
2888 ("python-faker" ,python-faker)
2889 ("python-inflection" ,python-inflection)
2890 ("python-lazy-object-proxy" ,python-lazy-object-proxy)
2891 ("python-pendulum" ,python-pendulum)
2892 ("python-pyaml" ,python-pyaml)
2893 ("python-pygments" ,python-pygments)
2894 ("python-pyyaml" ,python-pyyaml)
2895 ("python-simplejson" ,python-simplejson)
2896 ("python-six" ,python-six)
2897 ("python-wrapt" ,python-wrapt)))
2898 (home-page "https://orator-orm.com/")
2899 (synopsis "ActiveRecord ORM for Python")
2901 "Orator provides a simple ActiveRecord-like Object Relational Mapping
2902 implementation for Python.")
2903 (license license:expat)
2904 (properties `((python2-variant . ,(delay python2-orator))))))
2906 (define-public python2-orator
2907 (package-with-python2 (strip-python2-variant python-orator)))
2909 (define-public virtuoso-ose
2911 (name "virtuoso-ose")
2917 "https://github.com/openlink/virtuoso-opensource/releases/"
2918 "download/v" version "/virtuoso-opensource-" version ".tar.gz"))
2920 (base32 "0r1xakclkfi69pzh8z2k16z3x0m49pxp764icj0ad4w4bb97fr42"))))
2921 (build-system gnu-build-system)
2923 `(#:tests? #f ; Tests require a network connection.
2924 ;; TODO: Removing the libsrc/zlib source directory breaks the build.
2925 ;; This indicates that the internal zlib code may still be used.
2926 #:configure-flags '("--without-internal-zlib"
2928 "--enable-static=no")
2930 (modify-phases %standard-phases
2931 ;; Even with "--enable-static=no", "libvirtuoso-t.a" is left in
2932 ;; the build output. The following phase removes it.
2933 (add-after 'install 'remove-static-libs
2934 (lambda* (#:key outputs #:allow-other-keys)
2935 (let ((lib (string-append (assoc-ref outputs "out") "/lib")))
2936 (for-each (lambda (file)
2937 (delete-file (string-append lib "/" file)))
2939 "libvirtuoso-t.la"))))))))
2941 `(("openssl" ,openssl-1.0)
2942 ("net-tools" ,net-tools)
2943 ("readline" ,readline)
2945 (home-page "http://vos.openlinksw.com/owiki/wiki/VOS/")
2946 (synopsis "Multi-model database system")
2947 (description "Virtuoso is a scalable cross-platform server that combines
2948 relational, graph, and document data management with web application server
2949 and web services platform functionality.")
2950 ;; configure: error: ... can only be build on 64bit platforms
2951 (supported-systems '("x86_64-linux" "mips64el-linux" "aarch64-linux"))
2952 (license license:gpl2)))
2954 (define-public python-ccm
2961 (uri (pypi-uri "ccm" version))
2964 "177dfxsmk3k4cih6fh6v8d91bh4nqx7ns6pc07w7m7i3cvdx3c8n"))))
2965 (build-system python-build-system)
2967 `(("python-pyyaml" ,python-pyyaml)
2968 ;; Not listed in setup.py, but used in ccmlib/node.py for full
2970 ("python-psutil" ,python-psutil)
2971 ("python-six" ,python-six)))
2972 (home-page "https://github.com/pcmanus/ccm")
2973 (synopsis "Cassandra Cluster Manager for Apache Cassandra clusters on
2975 (description "Cassandra Cluster Manager is a development tool for testing
2976 local Cassandra clusters. It creates, launches and removes Cassandra clusters
2978 (license license:asl2.0)))
2980 (define-public python2-ccm
2981 (package-with-python2 python-ccm))
2983 (define-public python2-pysqlite
2985 (name "python2-pysqlite")
2990 (uri (pypi-uri "pysqlite" version))
2993 "1424gwq9sil2ffmnizk60q36vydkv8rxs6m7xs987kz8cdc37lqp"))))
2994 (build-system python-build-system)
2996 `(("sqlite" ,sqlite)))
2998 `(#:python ,python-2 ; incompatible with Python 3
2999 #:tests? #f)) ; no test target
3000 (home-page "https://github.com/ghaering/pysqlite")
3001 (synopsis "SQLite bindings for Python")
3003 "Pysqlite provides SQLite bindings for Python that comply to the
3004 Database API 2.0T.")
3005 (license license:zlib)))
3007 (define-public python-sqlalchemy
3009 (name "python-sqlalchemy")
3014 (uri (pypi-uri "SQLAlchemy" version))
3016 (base32 "18b9am7bsqc4nj3d2h5r93i002apczxfvpfpcqbd6f0385zmrwnj"))))
3017 (build-system python-build-system)
3019 `(("python-cython" ,python-cython) ; for C extensions
3020 ("python-pytest" ,python-pytest)
3021 ("python-mock" ,python-mock))) ; for tests
3024 (modify-phases %standard-phases
3026 (lambda _ (invoke "py.test"))))))
3027 (home-page "https://www.sqlalchemy.org")
3028 (synopsis "Database abstraction library")
3030 "SQLAlchemy is the Python SQL toolkit and Object Relational Mapper that
3031 gives application developers the full power and flexibility of SQL. It
3032 provides a full suite of well known enterprise-level persistence patterns,
3033 designed for efficient and high-performing database access, adapted into a
3034 simple and Pythonic domain language.")
3035 (license license:x11)))
3037 (define-public python2-sqlalchemy
3038 (package-with-python2 python-sqlalchemy))
3040 (define-public python-sqlalchemy-utils
3042 (name "python-sqlalchemy-utils")
3047 (uri (pypi-uri "SQLAlchemy-Utils" version))
3050 "1myn71dn8j74xglyh46f12sh8ywb7j0j732rzwq70kvwwnq32m73"))))
3051 (build-system python-build-system)
3053 '(#:tests? #f)) ; FIXME: Many tests require a running database server.
3055 ;; (modify-phases %standard-phases
3058 ;; (zero? (system* "py.test" "sqlalchemy_utils" "tests")))))
3060 `(("python-six" ,python-six)
3061 ("python-sqlalchemy" ,python-sqlalchemy)))
3063 `(("python-dateutil" ,python-dateutil)
3064 ("python-flexmock" ,python-flexmock)
3065 ("python-psycopg2" ,python-psycopg2)
3066 ("python-pytest" ,python-pytest)
3067 ("python-pytz" ,python-pytz)))
3068 (home-page "https://github.com/kvesteri/sqlalchemy-utils")
3069 (synopsis "Various utility functions for SQLAlchemy")
3071 "SQLAlchemy-utils provides various utility functions and custom data types
3072 for SQLAlchemy. SQLAlchemy is an SQL database abstraction library for Python.
3074 You might also want to install the following optional dependencies:
3076 @item @code{python-passlib}
3077 @item @code{python-babel}
3078 @item @code{python-cryptography}
3079 @item @code{python-pytz}
3080 @item @code{python-psycopg2}
3081 @item @code{python-furl}
3082 @item @code{python-flask-babel}
3085 (license license:bsd-3)))
3087 (define-public python2-sqlalchemy-utils
3088 (package-with-python2 python-sqlalchemy-utils))
3090 (define-public python-alchemy-mock
3092 (name "python-alchemy-mock")
3094 (home-page "https://github.com/miki725/alchemy-mock")
3097 (uri (pypi-uri "alchemy-mock" version))
3100 "0ylxygl3bcdapzz529n8wgk7vx9gjwb3ism564ypkpd7dbsw653r"))))
3101 (build-system python-build-system)
3103 '(#:phases (modify-phases %standard-phases
3106 ;; Create pytest.ini that adds doctest options to
3107 ;; prevent test failure. Taken from tox.ini.
3108 (call-with-output-file "pytest.ini"
3110 (format port "[pytest]
3111 doctest_optionflags=IGNORE_EXCEPTION_DETAIL
3113 (invoke "pytest" "-vv" "--doctest-modules"
3114 "alchemy_mock/"))))))
3116 `(("python-mock" ,python-mock)
3117 ("python-pytest" ,python-pytest)))
3119 `(("python-six" ,python-six)
3120 ("python-sqlalchemy" ,python-sqlalchemy)))
3121 (synopsis "Mock helpers for SQLAlchemy")
3123 "This package provides mock helpers for SQLAlchemy that makes it easy
3124 to mock an SQLAlchemy session while preserving the ability to do asserts.
3126 Normally Normally SQLAlchemy's expressions cannot be easily compared as
3127 comparison on binary expression produces yet another binary expression, but
3128 this library provides functions to facilitate such comparisons.")
3129 (license license:expat)))
3131 (define-public python-alembic
3133 (name "python-alembic")
3138 (uri (pypi-uri "alembic" version))
3140 (base32 "0if2dgb088clk738p26bwk50735h6jpd2kacdgc5capv2hiz6d2k"))))
3141 (build-system python-build-system)
3143 '(#:phases (modify-phases %standard-phases
3146 (invoke "pytest" "-vv"))))))
3148 `(("python-mock" ,python-mock)
3149 ("python-pytest-cov" ,python-pytest-cov)))
3151 `(("python-dateutil" ,python-dateutil)
3152 ("python-sqlalchemy" ,python-sqlalchemy)
3153 ("python-mako" ,python-mako)
3154 ("python-editor" ,python-editor)))
3155 (home-page "https://bitbucket.org/zzzeek/alembic")
3156 (synopsis "Database migration tool for SQLAlchemy")
3158 "Alembic is a lightweight database migration tool for usage with the
3159 SQLAlchemy Database Toolkit for Python.")
3160 (license license:expat)))
3162 (define-public python2-alembic
3163 (package-with-python2 python-alembic))
3165 (define-public python-pickleshare
3167 (name "python-pickleshare")
3172 (uri (pypi-uri "pickleshare" version))
3174 (base32 "1jmghg3c53yp1i8cm6pcrm280ayi8621rwyav9fac7awjr3kss47"))))
3175 (build-system python-build-system)
3177 `(#:phases (modify-phases %standard-phases
3180 (invoke "pytest"))))))
3182 `(("python-pytest" ,python-pytest)))
3183 (home-page "https://github.com/vivainio/pickleshare")
3184 (synopsis "Tiny key value database with concurrency support")
3186 "PickleShare is a small ‘shelve’-like datastore with concurrency support.
3187 Like shelve, a PickleShareDB object acts like a normal dictionary. Unlike
3188 shelve, many processes can access the database simultaneously. Changing a
3189 value in database is immediately visible to other processes accessing the same
3190 database. Concurrency is possible because the values are stored in separate
3191 files. Hence the “database” is a directory where all files are governed by
3193 (properties `((python2-variant . ,(delay python2-pickleshare))))
3194 (license license:expat)))
3196 (define-public python2-pickleshare
3197 (let ((pickleshare (package-with-python2
3198 (strip-python2-variant python-pickleshare))))
3199 (package (inherit pickleshare)
3200 (propagated-inputs `(("python2-pathlib2" ,python2-pathlib2)
3201 ,@(package-propagated-inputs pickleshare))))))
3203 (define-public python-apsw
3205 (name "python-apsw")
3206 (version "3.31.1-r1")
3210 (uri (string-append "https://github.com/rogerbinns/apsw/releases"
3211 "/download/" version "/apsw-" version ".zip"))
3214 "1gap5lr6c7bp134nzvfwr693i6d0fqyaysg3ms2cayjldv616yfx"))))
3215 (build-system python-build-system)
3217 `(("unzip" ,unzip)))
3219 `(("sqlite" ,sqlite)))
3222 (modify-phases %standard-phases
3225 (invoke "python" "setup.py" "build" "--enable-all-extensions")
3227 (add-after 'build 'build-test-helper
3229 (invoke "gcc" "-fPIC" "-shared" "-o" "./testextension.sqlext"
3230 "-I." "-Isqlite3" "src/testextension.c")
3233 (lambda* (#:key inputs outputs #:allow-other-keys)
3234 (add-installed-pythonpath inputs outputs)
3235 (invoke "python" "setup.py" "test")
3237 (home-page "https://github.com/rogerbinns/apsw/")
3238 (synopsis "Another Python SQLite Wrapper")
3239 (description "APSW is a Python wrapper for the SQLite
3240 embedded relational database engine. In contrast to other wrappers such as
3241 pysqlite it focuses on being a minimal layer over SQLite attempting just to
3242 translate the complete SQLite API into Python.")
3243 (license license:zlib)))
3245 (define-public python2-apsw
3246 (package-with-python2 python-apsw))
3248 (define-public python-aiosqlite
3250 (name "python-aiosqlite")
3255 (uri (pypi-uri "aiosqlite" version))
3258 "0lgfpbkcd730hbgj3zlrbx2y8fzvdns2zj3s4r4l31n49g1arrph"))))
3259 (build-system python-build-system)
3261 '(#:phases (modify-phases %standard-phases
3263 (lambda* (#:key tests? #:allow-other-keys)
3265 (invoke "python" "-m" "unittest" "aiosqlite.tests")
3266 (format #t "test suite not run~%"))
3269 `(("python-typing-extensions" ,python-typing-extensions)))
3271 `(("python-aiounittest" ,python-aiounittest)))
3272 (home-page "https://github.com/jreese/aiosqlite")
3274 "Asyncio bridge for sqlite3")
3276 "The package aiosqlite replicates the standard sqlite3 module, but with
3277 async versions of all the standard connection and cursor methods, and context
3278 managers for automatically closing connections.")
3279 (license license:expat)))
3281 (define-public python2-neo4j-driver
3283 (name "python2-neo4j-driver")
3284 ;; NOTE: When upgrading to 1.5.0, please add a python3 variant.
3288 (uri (pypi-uri "neo4j-driver" version))
3291 "011r1vh182p8mm83d8dz9rfnc3l7rf7fd00cyrbyfzi71jmc4g98"))))
3292 (build-system python-build-system)
3294 `(#:python ,python-2))
3295 (home-page "https://neo4j.com/developer/python/")
3296 (synopsis "Neo4j driver code written in Python")
3297 (description "This package provides the Neo4j Python driver that connects
3298 to the database using Neo4j's binary protocol. It aims to be minimal, while
3299 being idiomatic to Python.")
3300 (license license:asl2.0)))
3302 (define-public python2-py2neo
3304 (name "python2-py2neo")
3308 (uri (pypi-uri "py2neo" version))
3311 "1f1q95vqcvlc3nsc33p841swnjdcjazddlq2dzi3qfnjqjrajxw1"))))
3312 (build-system python-build-system)
3314 `(#:python ,python-2))
3315 (home-page "https://py2neo.org")
3316 (synopsis "Library and toolkit for working with Neo4j in Python")
3317 (description "This package provides a client library and toolkit for
3318 working with Neo4j from within Python applications and from the command
3319 line. The core library has no external dependencies and has been carefully
3320 designed to be easy and intuitive to use.")
3321 (license license:asl2.0)))
3323 (define-public python-psycopg2
3325 (name "python-psycopg2")
3330 (uri (pypi-uri "psycopg2" version))
3332 (base32 "0hzmk6b1hb5riqkljr5xics6p4zbvmis6knbczb7zhq7273zc8zv"))))
3333 (build-system python-build-system)
3335 ;; Tests would require a postgresql database "psycopg2_test"
3336 ;; and a running postgresql database management service.
3337 `(#:tests? #f)) ; TODO re-enable after providing a test-db.
3339 `(("postgresql" ,postgresql))) ; libpq
3340 (home-page "http://initd.org/psycopg/")
3341 (synopsis "Python PostgreSQL adapter")
3343 "psycopg2 is a thread-safe PostgreSQL adapter that implements DB-API
3345 (license license:lgpl3+)))
3347 (define-public python2-psycopg2
3348 (package-with-python2 python-psycopg2))
3350 (define-public python-sadisplay
3352 (name "python-sadisplay")
3357 (uri (pypi-uri "sadisplay" version))
3360 "01d9lxhmgpb68gy8rd6zj6fcwp84n2qq210n1qsk3qbsir79bzh4"))))
3361 (build-system python-build-system)
3363 `(("python-sqlalchemy" ,python-sqlalchemy)))
3366 `(("python-nose" ,python-nose)))
3367 (home-page "https://bitbucket.org/estin/sadisplay")
3368 (synopsis "SQLAlchemy schema displayer")
3369 (description "This package provides a program to build Entity
3370 Relationship diagrams from a SQLAlchemy model (or directly from the
3372 (license license:bsd-3)))
3374 (define-public python2-sadisplay
3375 (package-with-python2 python-sadisplay))
3377 (define-public yoyo-migrations
3379 (name "yoyo-migrations")
3383 ;; We use the upstream repository, as the tests are not included in the
3387 (url "https://hg.sr.ht/~olly/yoyo")
3388 (changeset (string-append "v" version "-release"))))
3389 (file-name (string-append name "-" version "-checkout"))
3391 (base32 "0q2z9bgdj3wyix7yvqsayfs21grp5av8ilh411lgmjhigszkvhcq"))))
3392 (build-system python-build-system)
3394 ;; XXX: Tests require a connection to some pgsql database and psycopg
3395 ;; fails to connect to it.
3398 `(("python-sqlparse" ,python-sqlparse)
3399 ("python-tabulate" ,python-tabulate)))
3400 (home-page "https://ollycope.com/software/yoyo/latest/")
3401 (synopsis "Database migrations with SQL")
3403 "Yoyo is a database schema migration tool. Migrations are written as SQL
3404 files or Python scripts that define a list of migration steps.")
3405 (license license:asl2.0)))
3407 (define-public python-mysqlclient
3409 (name "python-mysqlclient")
3414 (uri (pypi-uri "mysqlclient" version))
3417 "1rf5l8hazs3v18hmcrm90z3hi9wxv553ipwd5l6kj8j7l6p7abzv"))))
3418 (build-system python-build-system)
3419 (arguments '(#:tests? #f)) ;XXX: requires a live database
3421 `(("mysql-dev" ,mariadb "dev")))
3422 (home-page "https://github.com/PyMySQL/mysqlclient-python")
3423 (synopsis "MySQLdb is an interface to the popular MySQL database server for Python")
3424 (description "MySQLdb is an interface to the popular MySQL database server
3425 for Python. The design goals are:
3427 @item Compliance with Python database API version 2.0 [PEP-0249],
3428 @item Thread-safety,
3429 @item Thread-friendliness (threads will not block each other).
3431 (license license:gpl2)))
3433 (define-public python-hiredis
3435 (name "python-hiredis")
3440 (uri (pypi-uri "hiredis" version))
3443 "1dfm2k9l9zar9nw9fwmm74zrgraxdxs04vx9li56fjcf289qx5fa"))))
3444 (build-system python-build-system)
3448 (home-page "https://github.com/redis/hiredis-py")
3449 (synopsis "Python extension that wraps protocol parsing code in hiredis")
3450 (description "Python-hiredis is a python extension that wraps protocol
3451 parsing code in hiredis. It primarily speeds up parsing of multi bulk replies.")
3452 (license license:bsd-3)))
3454 (define-public python2-hiredis
3455 (package-with-python2 python-hiredis))
3457 (define-public python-fakeredis
3459 (name "python-fakeredis")
3464 (uri (pypi-uri "fakeredis" version))
3467 "1s12mn4q4hz7402139khn9fx56kibj7nn0d6w81hn0zs07b90wpc"))))
3468 (build-system python-build-system)
3473 `(("python-sortedcontainers" ,python-sortedcontainers)))
3474 (home-page "https://github.com/jamesls/fakeredis")
3475 (synopsis "Fake implementation of redis API for testing purposes")
3477 "Fakeredis is a pure-Python implementation of the redis-py Python client
3478 that simulates talking to a redis server. It was created for a single purpose:
3479 to write unit tests.
3481 Setting up redis is not hard, but one often wants to write unit tests that don't
3482 talk to an external server such as redis. This module can be used as a
3483 reasonable substitute.")
3484 (license license:bsd-3)))
3486 (define-public python2-fakeredis
3487 (package-with-python2 python-fakeredis))
3489 (define-public python-redis
3491 (name "python-redis")
3496 (uri (pypi-uri "redis" version))
3498 (base32 "18h5b87g15x3j6pb1h2q27ri37p2qpvc9n2wgn5yl3b6m3y0qzhf"))))
3499 (build-system python-build-system)
3500 ;; Tests require a running Redis server.
3501 (arguments '(#:tests? #f))
3502 ;; As long as we are not running test, we do not need this input :-)
3504 ;; `(("python-pytest" ,python-pytest)))
3505 (home-page "https://github.com/andymccurdy/redis-py")
3506 (synopsis "Redis Python client")
3508 "This package provides a Python interface to the Redis key-value store.")
3509 (license license:expat)))
3511 (define-public python2-redis
3512 (package-with-python2 python-redis))
3514 (define-public python-rq
3522 (url "https://github.com/rq/rq")
3523 (commit (string-append "v" version))))
3524 (file-name (git-file-name name version))
3526 (base32 "0ikqmpq0g1qiqwd7ar1286l4hqjb6aj2wr844gihhb8ijzwhp8va"))))
3527 (build-system python-build-system)
3529 '(#:phases (modify-phases %standard-phases
3530 (add-before 'check 'start-redis
3532 (invoke "redis-server" "--daemonize" "yes")))
3534 (lambda* (#:key outputs #:allow-other-keys)
3535 (let ((out (assoc-ref outputs "out")))
3536 ;; Drop test that needs the SDK for Sentry.io.
3537 (delete-file "tests/test_sentry.py")
3538 ;; Ensure 'rq' and 'rqworker' ends up on PATH.
3539 (setenv "PATH" (string-append out "/bin:"
3541 (invoke "pytest" "-vv")))))))
3543 `(("python-mock" ,python-mock)
3544 ("python-pytest" ,python-pytest)
3547 `(("python-click" ,python-click)
3548 ("python-redis" ,python-redis)))
3549 (home-page "https://python-rq.org/")
3550 (synopsis "Simple job queues for Python")
3552 "RQ (Redis Queue) is a simple Python library for queueing jobs and
3553 processing them in the background with workers. It is backed by Redis and it
3554 is designed to have a low barrier to entry.")
3555 (license license:bsd-2)))
3557 (define-public python2-rq
3558 (package-with-python2 python-rq))
3560 (define-public python-rq-scheduler
3562 (name "python-rq-scheduler")
3564 (home-page "https://github.com/rq/rq-scheduler")
3569 (commit (string-append "v" version))))
3570 (file-name (git-file-name name version))
3573 "0xg6yazqs5kbr2ayvhvljs1h5vgx5k5dds613fmhswln7gglf9hk"))))
3574 (build-system python-build-system)
3576 '(#:phases (modify-phases %standard-phases
3577 (add-before 'check 'start-redis
3579 (invoke "redis-server" "--daemonize" "yes")))
3582 (substitute* "run_tests.py"
3585 (invoke "./run_tests.py"))))))
3590 `(("python-croniter" ,python-croniter)
3591 ("python-rq" ,python-rq)))
3592 (synopsis "Job scheduling capabilities for RQ (Redis Queue)")
3594 "This package provides job scheduling capabilities to @code{python-rq}
3596 (license license:expat)))
3598 (define-public python-trollius-redis
3600 (name "python-trollius-redis")
3605 (uri (pypi-uri "trollius_redis" version))
3608 "0k3vypszmgmaipgw9xscvgm79h2zd6p6ci8gdp5sxl6g5kbqr9fy"))))
3609 (build-system python-build-system)
3610 ;; TODO: Tests require packaging 'hiredis'.
3611 (arguments '(#:tests? #f))
3612 (home-page "https://github.com/benjolitz/trollius-redis")
3613 (synopsis "Port of asyncio-redis to trollius")
3614 (description "@code{trollius-redis} is a Redis client for Python
3615 trollius. It is an asynchronous IO (PEP 3156) implementation of the
3617 (license license:bsd-2)))
3619 (define-public python2-trollius-redis
3620 (package-with-python2 python-trollius-redis))
3622 (define-public python-sqlparse
3624 (name "python-sqlparse")
3628 (uri (pypi-uri "sqlparse" version))
3631 "0j652a6z7bdf6c77aczfn8m8b2nsr1bcqq48wzghf8vi6wvj0qp1"))))
3632 (build-system python-build-system)
3635 (modify-phases %standard-phases
3637 (lambda _ (invoke "py.test"))))))
3639 `(("python-pytest" ,python-pytest)))
3640 (home-page "https://github.com/andialbrecht/sqlparse")
3641 (synopsis "Non-validating SQL parser")
3642 (description "Sqlparse is a non-validating SQL parser for Python. It
3643 provides support for parsing, splitting and formatting SQL statements.")
3644 (license license:bsd-3)))
3646 (define-public python2-sqlparse
3647 (package-with-python2 python-sqlparse))
3649 (define-public python-sql
3656 (uri (pypi-uri "python-sql" version))
3658 (base32 "05ni936y0ia9xmryl7mlhbj9i80nnvq1bi4zxhb96rv7yvpb3fqb"))))
3659 (build-system python-build-system)
3660 (home-page "https://python-sql.tryton.org/")
3661 (synopsis "Library to write SQL queries in a pythonic way")
3662 (description "@code{python-sql} is a library to write SQL queries, that
3663 transforms idiomatic python function calls to well-formed SQL queries.")
3664 (license license:bsd-3)))
3666 (define-public python2-sql
3667 (package-with-python2 python-sql))
3669 (define-public python-pypika
3671 (name "python-pypika")
3674 (origin (method git-fetch)
3676 (url "https://github.com/kayak/pypika")
3677 (commit (string-append "v" version))))
3678 (file-name (git-file-name name version))
3681 "001pg36sw9a36zdd1kccbymcxndphjcjbbrsy6ri7ng8h4dgz549"))))
3682 (build-system python-build-system)
3684 `(("python-parameterized" ,python-parameterized)))
3685 (home-page "https://github.com/kayak/pypika")
3686 (synopsis "SQL query builder API for Python")
3688 "PyPika is a python SQL query builder that exposes the full richness of
3689 the SQL language using a syntax that reflects the resulting query.")
3690 (license license:asl2.0)))
3692 (define-public mongo-tools
3694 (name "mongo-tools")
3697 (origin (method git-fetch)
3699 (url "https://github.com/mongodb/mongo-tools")
3700 (commit (string-append "r" version))))
3701 (file-name (git-file-name name version))
3704 "1bcsz5cvj39a7nsxsfqmz9igrw33j6yli9kffigqyscs52amw7x1"))))
3705 (build-system go-build-system)
3707 `(#:import-path "github.com/mongodb/mongo-tools"
3708 #:modules ((srfi srfi-1)
3709 (guix build go-build-system)
3711 #:install-source? #f
3714 '("bsondump" "mongodump" "mongoexport" "mongofiles"
3715 "mongoimport" "mongooplog" "mongorestore"
3716 "mongostat" "mongotop")))
3717 (modify-phases %standard-phases
3718 (add-after 'unpack 'delete-bundled-source-code
3720 (delete-file-recursively
3721 "src/github.com/mongodb/mongo-tools/vendor")
3723 (add-after 'delete-bundled-source-code 'patch-source
3725 ;; Remove a redundant argument that causes compilation to fail.
3727 "src/github.com/mongodb/mongo-tools/mongorestore/filepath.go"
3728 (("skipping restore of system.profile collection\", db)")
3729 "skipping restore of system.profile collection\")"))
3733 (for-each (lambda (tool)
3736 ;; This is where the tests expect to find the
3738 "-o" ,(string-append
3739 "src/github.com/mongodb/mongo-tools/bin/"
3742 "-tags=\"ssl sasl\""
3744 "-extldflags=-Wl,-z,now,-z,relro"
3746 "src/github.com/mongodb/mongo-tools/"
3747 tool "/main/" tool ".go"))))
3748 (simple-format #t "build: running ~A\n"
3749 (string-join command))
3750 (apply invoke command)))
3755 (with-directory-excursion "src"
3756 (for-each (lambda (tool)
3759 (string-append "github.com/mongodb/mongo-tools/"
3764 (lambda* (#:key outputs #:allow-other-keys)
3765 (for-each (lambda (tool)
3767 (string-append "src/github.com/mongodb/mongo-tools/bin/"
3769 (string-append (assoc-ref outputs "out")
3774 `(("go-github.com-howeyc-gopass" ,go-github.com-howeyc-gopass)
3775 ("go-github.com-jessevdk-go-flags" ,go-github.com-jessevdk-go-flags)
3776 ("go-golang-org-x-crypto" ,go-golang-org-x-crypto)
3777 ("go-gopkg.in-mgo.v2" ,go-gopkg.in-mgo.v2)
3778 ("go-gopkg.in-tomb.v2" ,go-gopkg.in-tomb.v2)
3779 ("go-github.com-nsf-termbox-go" ,go-github.com-nsf-termbox-go)
3780 ("go-github.com-smartystreets-goconvey" ,go-github.com-smartystreets-goconvey)))
3781 (home-page "https://github.com/mongodb/mongo-tools")
3782 (synopsis "Various tools for interacting with MongoDB and BSON")
3784 "This package includes a collection of tools related to MongoDB.
3787 Display BSON files in a human-readable format
3789 Convert data from JSON, TSV or CSV and insert them into a collection
3791 Write an existing collection to CSV or JSON format
3792 @item mongodump/mongorestore
3793 Dump MongoDB backups to disk in the BSON format
3795 Read MongoDB backups in the BSON format, and restore them to a live database
3797 Monitor live MongoDB servers, replica sets, or sharded clusters
3799 Read, write, delete, or update files in GridFS
3801 Replay oplog entries between MongoDB servers
3803 Monitor read/write activity on a mongo server
3805 (license license:asl2.0)))
3807 ;; There are many wrappers for this in other languages. When touching, please
3808 ;; be sure to ensure all dependencies continue to build.
3809 (define-public apache-arrow
3811 (name "apache-arrow")
3817 (url "https://github.com/apache/arrow")
3818 (commit (string-append "apache-arrow-" version))))
3819 (file-name (git-file-name name version))
3822 "03ngddh3r1g6f9aja2jlfksgvgyzmxmfy4bxvzjrcv5fvl5x8ii0"))))
3823 (build-system cmake-build-system)
3827 (modify-phases %standard-phases
3828 (add-before 'configure 'enter-source-directory
3829 (lambda _ (chdir "cpp") #t))
3830 (add-after 'unpack 'set-env
3832 (setenv "BOOST_ROOT" (assoc-ref %build-inputs "boost"))
3833 (setenv "BROTLI_HOME" (assoc-ref %build-inputs "brotli"))
3834 (setenv "FLATBUFFERS_HOME" (assoc-ref %build-inputs "flatbuffers"))
3835 (setenv "RAPIDJSON_HOME" (assoc-ref %build-inputs "rapidjson"))
3837 #:build-type "Release"
3839 (list "-DARROW_PYTHON=ON"
3842 "-DARROW_PARQUET=ON"
3843 "-DPARQUET_BUILD_EXECUTABLES=ON"
3844 ;; The maintainers disallow using system versions of
3846 ;; https://issues.apache.org/jira/browse/ARROW-3507. This
3847 ;; is unfortunate because jemalloc increases performance:
3848 ;; https://arrow.apache.org/blog/2018/07/20/jemalloc/.
3849 "-DARROW_JEMALLOC=OFF"
3851 ;; The CMake option ARROW_DEPENDENCY_SOURCE is a global
3852 ;; option that instructs the build system how to resolve
3853 ;; each dependency. SYSTEM = Finding the dependency in
3854 ;; system paths using CMake's built-in find_package
3855 ;; function, or using pkg-config for packages that do not
3856 ;; have this feature
3857 "-DARROW_DEPENDENCY_SOURCE=SYSTEM"
3859 ;; Split output into its component packages.
3860 (string-append "-DCMAKE_INSTALL_PREFIX="
3861 (assoc-ref %outputs "lib"))
3862 (string-append "-DCMAKE_INSTALL_RPATH="
3863 (assoc-ref %outputs "lib")
3865 (string-append "-DCMAKE_INSTALL_BINDIR="
3866 (assoc-ref %outputs "out")
3868 (string-append "-DCMAKE_INSTALL_INCLUDEDIR="
3869 (assoc-ref %outputs "include")
3873 "-DARROW_WITH_SNAPPY=ON"
3874 "-DARROW_WITH_ZLIB=ON"
3875 "-DARROW_WITH_ZSTD=ON"
3876 "-DARROW_WITH_LZ4=ON"
3877 "-DARROW_COMPUTE=ON"
3879 "-DARROW_DATASET=ON"
3880 "-DARROW_FILESYSTEM=ON"
3883 ;; Arrow Python C++ integration library (required for
3884 ;; building pyarrow). This library must be built against
3885 ;; the same Python version for which you are building
3886 ;; pyarrow. NumPy must also be installed. Enabling this
3887 ;; option also enables ARROW_COMPUTE, ARROW_CSV,
3888 ;; ARROW_DATASET, ARROW_FILESYSTEM, ARROW_HDFS, and
3892 ;; Building the tests forces on all the
3893 ;; optional features and the use of static
3895 "-DARROW_BUILD_TESTS=OFF"
3896 "-DBENCHMARK_ENABLE_GTEST_TESTS=OFF"
3897 ;;"-DBENCHMARK_ENABLE_TESTING=OFF"
3898 "-DARROW_BUILD_STATIC=OFF")))
3900 `(("apache-thrift" ,apache-thrift "lib")
3902 ("brotli" ,google-brotli)
3904 ("double-conversion" ,double-conversion)
3909 ("protobuf" ,protobuf)
3910 ("python-3" ,python)
3911 ("python-numpy" ,python-numpy)
3912 ("rapidjson" ,rapidjson)
3915 ("utf8proc" ,utf8proc)
3917 ("zstd" ,zstd "lib")))
3919 `(("pkg-config" ,pkg-config)))
3920 (outputs '("out" "lib" "include"))
3921 (home-page "https://arrow.apache.org/")
3922 (synopsis "Columnar in-memory analytics")
3923 (description "Apache Arrow is a columnar in-memory analytics layer
3924 designed to accelerate big data. It houses a set of canonical in-memory
3925 representations of flat and hierarchical data along with multiple
3926 language-bindings for structure manipulation. It also provides IPC and common
3927 algorithm implementations.")
3928 (license license:asl2.0)))
3930 (define-public python-pyarrow
3932 (inherit apache-arrow)
3933 (name "python-pyarrow")
3934 (build-system python-build-system)
3936 '(#:tests? #f ; XXX There are no tests in the "python" directory
3938 (modify-phases %standard-phases
3939 (delete 'build) ; XXX the build is performed again during the install phase
3940 (add-after 'unpack 'enter-source-directory
3941 (lambda _ (chdir "python") #t))
3942 (add-after 'unpack 'make-git-checkout-writable
3944 (for-each make-file-writable (find-files "."))
3947 `(("apache-arrow" ,apache-arrow "lib")
3948 ("python-numpy" ,python-numpy)
3949 ("python-pandas" ,python-pandas)
3950 ("python-six" ,python-six)))
3952 `(("cmake" ,cmake-minimal)
3953 ("pkg-config" ,pkg-config)
3954 ("python-cython" ,python-cython)
3955 ("python-pytest" ,python-pytest)
3956 ("python-pytest-runner" ,python-pytest-runner)
3957 ("python-setuptools-scm" ,python-setuptools-scm)))
3959 (home-page "https://arrow.apache.org/docs/python/")
3960 (synopsis "Python bindings for Apache Arrow")
3962 "This library provides a Pythonic API wrapper for the reference Arrow C++
3963 implementation, along with tools for interoperability with pandas, NumPy, and
3964 other traditional Python scientific computing packages.")
3965 (license license:asl2.0)))
3967 (define-public python-crate
3969 (name "python-crate")
3973 (uri (pypi-uri "crate" version))
3976 "0ngmlvi320c5gsxab0s7qgq0ck4jdlcwvb6lbjhnfprafdp56vvx"))))
3977 (build-system python-build-system)
3979 `(("python-urllib3" ,python-urllib3)))
3980 (home-page "https://github.com/crate/crate-python")
3981 (synopsis "CrateDB Python client")
3983 "This package provides a Python client library for CrateDB.
3984 It implements the Python DB API 2.0 specification and includes support for
3986 (license license:asl2.0)))
3988 (define-public libdbi
3994 (uri (string-append "mirror://sourceforge/libdbi/libdbi/libdbi-"
3995 version "/libdbi-" version ".tar.gz"))
3998 "00s5ra7hdlq25iv23nwf4h1v3kmbiyzx0v9bhggjiii4lpf6ryys"))))
3999 (build-system gnu-build-system)
4000 (synopsis "Database independent abstraction layer in C")
4002 "This library implements a database independent abstraction layer in C,
4003 similar to the DBI/DBD layer in Perl. Writing one generic set of code,
4004 programmers can leverage the power of multiple databases and multiple
4005 simultaneous database connections by using this framework.")
4006 (home-page "http://libdbi.sourceforge.net/")
4007 (license license:lgpl2.1+)))
4009 (define-public libdbi-drivers
4011 (name "libdbi-drivers")
4015 (uri (string-append "mirror://sourceforge/libdbi-drivers/"
4016 "libdbi-drivers/libdbi-drivers-" version
4017 "/libdbi-drivers-" version ".tar.gz"))
4020 "0m680h8cc4428xin4p733azysamzgzcmv4psjvraykrsaz6ymlj3"))))
4021 (build-system gnu-build-system)
4024 ("inetutils" ,inetutils)
4025 ("glibc-locales" ,glibc-locales)
4026 ("mariadb" ,mariadb)))
4028 `(("libdbi" ,libdbi)
4029 ("mariadb:dev" ,mariadb "dev")
4030 ("mariadb:lib" ,mariadb "lib")
4031 ("postgresql" ,postgresql)
4032 ("sqlite" ,sqlite)))
4035 (let ((libdbi (assoc-ref %build-inputs "libdbi"))
4036 (mysql:inc (assoc-ref %build-inputs "mariadb:dev"))
4037 (mysql:lib (assoc-ref %build-inputs "mariadb:lib"))
4038 (postgresql (assoc-ref %build-inputs "postgresql"))
4039 (sqlite (assoc-ref %build-inputs "sqlite")))
4040 (list "--disable-docs"
4041 (string-append "--with-dbi-incdir=" libdbi "/include")
4042 (string-append "--with-dbi-libdir=" libdbi "/lib")
4044 (string-append "--with-mysql-incdir=" mysql:inc "/include/mysql")
4045 (string-append "--with-mysql-libdir=" mysql:lib "/lib")
4047 (string-append "--with-pgsql-incdir=" postgresql "/include")
4048 (string-append "--with-pgsql-libdir=" postgresql "/lib")
4050 (string-append "--with-sqlite-incdir=" sqlite "/include")
4051 (string-append "--with-sqlite-libdir=" sqlite "/lib")))
4052 #:tests? #f ; FIXME: Find why the tests get stuck forever.
4054 (modify-phases %standard-phases
4055 (add-after 'unpack 'fix-tests
4056 (lambda* (#:key inputs #:allow-other-keys)
4057 (substitute* "tests/test_mysql.sh"
4059 (string-append "MYMYSQLD="
4060 (assoc-ref inputs "mariadb")
4063 (add-after 'install 'remove-empty-directories
4064 (lambda* (#:key outputs #:allow-other-keys)
4065 (let ((var (string-append (assoc-ref outputs "out") "/var")))
4066 (delete-file-recursively var))
4068 (synopsis "Database drivers for the libdbi framework")
4070 "The @code{libdbi-drivers} library provides the database specific drivers
4071 for the @code{libdbi} framework.
4073 The drivers officially supported by @code{libdbi} are:
4079 (home-page "http://libdbi-drivers.sourceforge.net/")
4080 (license license:lgpl2.1+)))
4089 (url "https://github.com/SOCI/soci/")
4091 (file-name (git-file-name name version))
4094 "14x2gjblkgpflv75wl144cyjp1sis5rbxnr9r2gj3yw16v2av0bp"))))
4095 (build-system cmake-build-system)
4097 `(("firebird" ,firebird)
4098 ("postgresql" ,postgresql)
4102 ("mariadb:dev" ,mariadb "dev")))
4105 ;; C++11 (-DSOCI_CXX11) is OFF by default. hyperledger-iroha needs it.
4106 (list "-DCMAKE_CXX_STANDARD=17"
4107 "-DSOCI_LIBDIR=lib")
4108 #:tests? #f)) ; may require running database management systems
4109 (synopsis "C++ Database Access Library")
4111 "SOCI is an abstraction layer for several database backends, including
4112 PostreSQL, SQLite, ODBC and MySQL.")
4113 (home-page "http://soci.sourceforge.net/")
4114 (license license:boost1.0)))
4116 (define-public freetds
4123 (uri (string-append "https://www.freetds.org/files/stable/"
4124 "freetds-" version ".tar.gz"))
4126 (base32 "1hspvwxwdd1apadsy2b40dpjik8kfwcvdamvhpg3lnm15n02fb50"))))
4127 (build-system gnu-build-system)
4129 ;; NOTE: (Sharlatan-20210110213908+0000) some tests require DB connection,
4130 ;; disabled for now.
4132 (home-page "https://www.freetds.org/")
4133 (synopsis "Client libraries for MS SQL and Sybase servers")
4135 "FreeTDS is an implementation of the Tabular DataStream protocol, used for
4136 connecting to MS SQL and Sybase servers over TCP/IP.")
4137 (license license:lgpl2.0+)))