gnu: Add FIL plugins.
[jackhill/guix/guix.git] / gnu / packages / databases.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2012, 2013, 2014, 2015 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2012, 2014, 2015 Andreas Enge <andreas@enge.fr>
4 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
5 ;;; Copyright © 2014 David Thompson <davet@gnu.org>
6 ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
7 ;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org>
8 ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com>
9 ;;; Copyright © 2015 Leo Famulari <leo@famulari.name>
10 ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
11 ;;; Copyright © 2016 Nils Gillmann <niasterisk@grrlz.net>
12 ;;;
13 ;;; This file is part of GNU Guix.
14 ;;;
15 ;;; GNU Guix is free software; you can redistribute it and/or modify it
16 ;;; under the terms of the GNU General Public License as published by
17 ;;; the Free Software Foundation; either version 3 of the License, or (at
18 ;;; your option) any later version.
19 ;;;
20 ;;; GNU Guix is distributed in the hope that it will be useful, but
21 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
22 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 ;;; GNU General Public License for more details.
24 ;;;
25 ;;; You should have received a copy of the GNU General Public License
26 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
27
28 (define-module (gnu packages databases)
29 #:use-module (gnu packages)
30 #:use-module (gnu packages bash)
31 #:use-module (gnu packages perl)
32 #:use-module (gnu packages language)
33 #:use-module (gnu packages linux)
34 #:use-module (gnu packages tls)
35 #:use-module (gnu packages compression)
36 #:use-module (gnu packages ncurses)
37 #:use-module (gnu packages readline)
38 #:use-module (gnu packages emacs)
39 #:use-module (gnu packages check)
40 #:use-module (gnu packages algebra)
41 #:use-module (gnu packages curl)
42 #:use-module (gnu packages gnupg)
43 #:use-module (gnu packages python)
44 #:use-module (gnu packages pcre)
45 #:use-module (gnu packages xml)
46 #:use-module (gnu packages bison)
47 #:use-module (gnu packages jemalloc)
48 #:use-module ((guix licenses)
49 #:select (gpl2 gpl3+ lgpl2.1+ lgpl3+ x11-style non-copyleft
50 bsd-2 bsd-3 public-domain))
51 #:use-module (guix packages)
52 #:use-module (guix download)
53 #:use-module (guix build-system gnu)
54 #:use-module (guix build-system perl)
55 #:use-module (guix build-system cmake)
56 #:use-module (guix utils)
57 #:use-module (srfi srfi-26)
58 #:use-module (ice-9 match))
59
60 (define-public gdbm
61 (package
62 (name "gdbm")
63 (version "1.11")
64 (source (origin
65 (method url-fetch)
66 (uri (string-append "mirror://gnu/gdbm/gdbm-"
67 version ".tar.gz"))
68 (sha256
69 (base32
70 "1hz3jgh3pd4qzp6jy0l8pd8x01g9abw7csnrlnj1a2sxy122z4cd"))))
71 (arguments `(#:configure-flags '("--enable-libgdbm-compat")))
72 (build-system gnu-build-system)
73 (home-page "http://www.gnu.org/software/gdbm/")
74 (synopsis
75 "Hash library of database functions compatible with traditional dbm")
76 (description
77 "GDBM is a library for manipulating hashed databases. It is used to
78 store key/value pairs in a file in a manner similar to the Unix dbm library
79 and provides interfaces to the traditional file format.")
80 (license gpl3+)))
81
82 (define-public bdb
83 (package
84 (name "bdb")
85 (version "5.3.21")
86 (source (origin
87 (method url-fetch)
88 (uri (string-append "http://download.oracle.com/berkeley-db/db-" version
89 ".tar.gz"))
90 (sha256 (base32
91 "1f2g2612lf8djbwbwhxsvmffmf9d7693kh2l20195pqp0f9jmnfx"))))
92 (build-system gnu-build-system)
93 (outputs '("out" ; programs, libraries, headers
94 "doc")) ; 94 MiB of HTML docs
95 (arguments
96 '(#:tests? #f ; no check target available
97 #:phases
98 (alist-replace
99 'configure
100 (lambda* (#:key outputs #:allow-other-keys)
101 (let ((out (assoc-ref outputs "out"))
102 (doc (assoc-ref outputs "doc")))
103 ;; '--docdir' is not honored, so we need to patch.
104 (substitute* "dist/Makefile.in"
105 (("docdir[[:blank:]]*=.*")
106 (string-append "docdir = " doc "/share/doc/bdb")))
107
108 (zero?
109 (system* "./dist/configure"
110 (string-append "--prefix=" out)
111 (string-append "CONFIG_SHELL=" (which "bash"))
112 (string-append "SHELL=" (which "bash"))
113
114 ;; The compatibility mode is needed by some packages,
115 ;; notably iproute2.
116 "--enable-compat185"
117
118 ;; The following flag is needed so that the inclusion
119 ;; of db_cxx.h into C++ files works; it leads to
120 ;; HAVE_CXX_STDHEADERS being defined in db_cxx.h.
121 "--enable-cxx"))))
122 %standard-phases)))
123 (synopsis "Berkeley database")
124 (description
125 "Berkeley DB is an embeddable database allowing developers the choice of
126 SQL, Key/Value, XML/XQuery or Java Object storage for their data model.")
127 (license (non-copyleft "file://LICENSE"
128 "See LICENSE in the distribution."))
129 (home-page
130 "http://www.oracle.com/us/products/database/berkeley-db/overview/index.html")))
131
132 (define-public mysql
133 (package
134 (name "mysql")
135 (version "5.6.25")
136 (source (origin
137 (method url-fetch)
138 (uri (string-append
139 "http://dev.mysql.com/get/Downloads/MySQL-"
140 (version-major+minor version) "/"
141 name "-" version ".tar.gz"))
142 (sha256
143 (base32
144 "1gbz5i1z3nswpq3q8f477vrx7g15j8n41pyb94k0jfnkhc5rq1qm"))))
145 (build-system cmake-build-system)
146 (arguments
147 '(#:configure-flags
148 '("-DBUILD_CONFIG=mysql_release"
149 "-DWITH_SSL=system"
150 "-DWITH_ZLIB=system"
151 "-DDEFAULT_CHARSET=utf8"
152 "-DDEFAULT_COLLATION=utf8_general_ci"
153 "-DMYSQL_DATADIR=/var/lib/mysql"
154 "-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock"
155 "-DINSTALL_INFODIR=share/mysql/docs"
156 "-DINSTALL_MANDIR=share/man"
157 "-DINSTALL_PLUGINDIR=lib/mysql/plugin"
158 "-DINSTALL_SCRIPTDIR=bin"
159 "-DINSTALL_INCLUDEDIR=include/mysql"
160 "-DINSTALL_DOCREADMEDIR=share/mysql/docs"
161 "-DINSTALL_SUPPORTFILESDIR=share/mysql"
162 "-DINSTALL_MYSQLSHAREDIR=share/mysql"
163 "-DINSTALL_DOCDIR=share/mysql/docs"
164 "-DINSTALL_SHAREDIR=share/mysql"
165 ;; Get rid of test data.
166 "-DINSTALL_MYSQLTESTDIR="
167 "-DINSTALL_SQLBENCHDIR=")
168 #:phases (modify-phases %standard-phases
169 (add-after
170 'install 'strip-extra-references
171 (lambda* (#:key outputs #:allow-other-keys)
172 ;; Strip references to GCC and other build-time
173 ;; dependencies.
174 (let ((out (assoc-ref outputs "out")))
175 (for-each remove-store-references
176 (list (string-append out "/bin/mysqlbug")
177 (string-append
178 out "/share/mysql/docs/INFO_BIN")))
179 #t)))
180 (add-after
181 'install 'remove-extra-binaries
182 (lambda* (#:key outputs #:allow-other-keys)
183 (let ((out (assoc-ref outputs "out")))
184 ;; Remove the 3 *_embedded files, which weigh in at
185 ;; 14 MiB each.
186 (for-each delete-file
187 (find-files (string-append out "/bin")
188 "_embedded$"))
189 #t))))))
190 (native-inputs
191 `(("bison" ,bison)
192 ("perl" ,perl)))
193 (inputs
194 `(("libaio" ,libaio)
195 ("openssl" ,openssl)
196 ("zlib" ,zlib)
197 ("ncurses" ,ncurses)))
198 (home-page "http://www.mysql.com/")
199 (synopsis "Fast, easy to use, and popular database")
200 (description
201 "MySQL is a fast, reliable, and easy to use relational database
202 management system that supports the standardized Structured Query
203 Language.")
204 (license gpl2)))
205
206 (define-public mariadb
207 (package
208 (name "mariadb")
209 (version "10.1.12")
210 (source (origin
211 (method url-fetch)
212 (uri (string-append "https://downloads.mariadb.org/f/"
213 name "-" version "/source/"
214 name "-" version ".tar.gz"))
215 (sha256
216 (base32
217 "1rzlc2ns84x540asbkgdp9562haxhlszfpdqh64i9pz4q1m4cpvr"))))
218 (build-system cmake-build-system)
219 (arguments
220 '(#:configure-flags
221 '("-DBUILD_CONFIG=mysql_release"
222 "-DDEFAULT_CHARSET=utf8"
223 "-DDEFAULT_COLLATION=utf8_general_ci"
224 "-DMYSQL_DATADIR=/var/lib/mysql"
225 "-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock"
226 "-DINSTALL_INFODIR=share/mysql/docs"
227 "-DINSTALL_MANDIR=share/man"
228 "-DINSTALL_PLUGINDIR=lib/mysql/plugin"
229 "-DINSTALL_SCRIPTDIR=bin"
230 "-DINSTALL_INCLUDEDIR=include/mysql"
231 "-DINSTALL_DOCREADMEDIR=share/mysql/docs"
232 "-DINSTALL_SUPPORTFILESDIR=share/mysql/support-files"
233 "-DINSTALL_MYSQLSHAREDIR=share/mysql"
234 "-DINSTALL_DOCDIR=share/mysql/docs"
235 "-DINSTALL_SHAREDIR=share/mysql")
236 #:phases
237 (modify-phases %standard-phases
238 (add-before
239 'configure 'pre-configure
240 (lambda _
241 (setenv "CONFIG_SHELL" (which "sh"))
242 #t))
243 (add-after
244 'install 'post-install
245 (lambda* (#:key outputs #:allow-other-keys)
246 (let* ((out (assoc-ref outputs "out"))
247 (test (assoc-ref outputs "test")))
248 (substitute* (string-append out "/bin/mysql_install_db")
249 (("basedir=\"\"")
250 (string-append "basedir=\"" out "\"")))
251 ;; Remove unneeded files for testing.
252 (with-directory-excursion out
253 (for-each delete-file-recursively
254 '("data" "mysql-test" "sql-bench"
255 "share/man/man1/mysql-test-run.pl.1")))))))))
256 (native-inputs
257 `(("bison" ,bison)
258 ("perl" ,perl)))
259 (inputs
260 `(("jemalloc" ,jemalloc)
261 ("libaio" ,libaio)
262 ("libxml2" ,libxml2)
263 ("ncurses" ,ncurses)
264 ("openssl" ,openssl)
265 ("pcre" ,pcre)
266 ("zlib" ,zlib)))
267 (home-page "https://mariadb.org/")
268 (synopsis "SQL database server")
269 (description
270 "MariaDB is a multi-user and multi-threaded SQL database server, designed
271 as a drop-in replacement of MySQL.")
272 (license gpl2)))
273
274 (define-public postgresql
275 (package
276 (name "postgresql")
277 (version "9.3.11")
278 (source (origin
279 (method url-fetch)
280 (uri (string-append "http://ftp.postgresql.org/pub/source/v"
281 version "/postgresql-" version ".tar.bz2"))
282 (sha256
283 (base32
284 "08ba951nfiy516flaw352shj1zslxg4ryx3w5k0adls1r682l8ix"))))
285 (build-system gnu-build-system)
286 (inputs
287 `(("readline" ,readline)
288 ("zlib" ,zlib)))
289 (home-page "http://www.postgresql.org/")
290 (synopsis "Powerful object-relational database system")
291 (description
292 "PostgreSQL is a powerful object-relational database system. It is fully
293 ACID compliant, has full support for foreign keys, joins, views, triggers, and
294 stored procedures (in multiple languages). It includes most SQL:2008 data
295 types, including INTEGER, NUMERIC, BOOLEAN, CHAR, VARCHAR, DATE, INTERVAL, and
296 TIMESTAMP. It also supports storage of binary large objects, including
297 pictures, sounds, or video.")
298 (license (x11-style "file://COPYRIGHT"))))
299
300 (define-public recutils
301 (package
302 (name "recutils")
303 (version "1.7")
304 (source (origin
305 (method url-fetch)
306 (uri (string-append "mirror://gnu/recutils/recutils-"
307 version ".tar.gz"))
308 (sha256
309 (base32
310 "0cdwa4094x3yx7vn98xykvnlp9rngvd58d19vs3vh5hrvggccg93"))))
311 (build-system gnu-build-system)
312
313 ;; Running tests in parallel leads to test failures and crashes in
314 ;; torture/utils.
315 (arguments '(#:parallel-tests? #f
316 #:configure-flags
317 (list (string-append "--with-bash-headers="
318 (assoc-ref %build-inputs "bash:include")
319 "/include/bash"))))
320
321 (native-inputs `(("emacs" ,emacs-no-x)
322 ("bc" ,bc)
323 ("bash:include" ,bash "include")
324 ("libuuid" ,util-linux)))
325
326 ;; TODO: Add more optional inputs.
327 (inputs `(("curl" ,curl)
328 ("libgcrypt" ,libgcrypt)
329 ("check" ,check)))
330 (synopsis "Manipulate plain text files as databases")
331 (description
332 "GNU Recutils is a set of tools and libraries for creating and
333 manipulating text-based, human-editable databases. Despite being text-based,
334 databases created with Recutils carry all of the expected features such as
335 unique fields, primary keys, time stamps and more. Many different field
336 types are supported, as is encryption.")
337 (license gpl3+)
338 (home-page "http://www.gnu.org/software/recutils/")))
339
340 (define-public sqlite
341 (package
342 (name "sqlite")
343 (version "3.10.0")
344 (source (origin
345 (method url-fetch)
346 ;; TODO: Download from sqlite.org once this bug :
347 ;; http://lists.gnu.org/archive/html/bug-guile/2013-01/msg00027.html
348 ;; has been fixed.
349 (uri (let ((numeric-version
350 (match (string-split version #\.)
351 ((first-digit other-digits ...)
352 (string-append first-digit
353 (string-pad-right
354 (string-concatenate
355 (map (cut string-pad <> 2 #\0)
356 other-digits))
357 6 #\0))))))
358 (list
359 (string-append
360 "https://fossies.org/linux/misc/sqlite-autoconf-"
361 numeric-version ".tar.gz")
362 (string-append
363 "http://distfiles.gentoo.org/distfiles/"
364 "/sqlite-autoconf-" numeric-version ".tar.gz"))
365
366 ;; XXX: As of 2015-09-08, SourceForge is squatting the URL
367 ;; below, returning 200 and showing an advertising page.
368 ;; (string-append
369 ;; "mirror://sourceforge/sqlite.mirror/SQLite%20" version
370 ;; "/sqlite-autoconf-" numeric-version ".tar.gz")
371 ))
372 (sha256
373 (base32
374 "0hhhv6si0pyf5i8bv7a71953m0b4gk6s3j2h09caf7vif0njkk23"))))
375 (build-system gnu-build-system)
376 (inputs `(("readline" ,readline)))
377 (arguments
378 `(#:configure-flags
379 ;; Add -DSQLITE_SECURE_DELETE and -DSQLITE_ENABLE_UNLOCK_NOTIFY to
380 ;; CFLAGS. GNU Icecat will refuse to use the system SQLite unless these
381 ;; options are enabled.
382 '("CFLAGS=-O2 -DSQLITE_SECURE_DELETE -DSQLITE_ENABLE_UNLOCK_NOTIFY")))
383 (home-page "http://www.sqlite.org/")
384 (synopsis "The SQLite database management system")
385 (description
386 "SQLite is a software library that implements a self-contained, serverless,
387 zero-configuration, transactional SQL database engine. SQLite is the most
388 widely deployed SQL database engine in the world. The source code for SQLite
389 is in the public domain.")
390 (license public-domain)))
391
392 (define-public tdb
393 (package
394 (name "tdb")
395 (version "1.3.8")
396 (source (origin
397 (method url-fetch)
398 (uri (string-append "https://www.samba.org/ftp/tdb/tdb-"
399 version ".tar.gz"))
400 (sha256
401 (base32
402 "1cg6gmpgn36dd4bsp3j9k3hyrm87d8hdigqyyqxw5jga4w2aq186"))))
403 (build-system gnu-build-system)
404 (arguments
405 '(#:phases (alist-replace
406 'configure
407 (lambda* (#:key outputs #:allow-other-keys)
408 (let ((out (assoc-ref outputs "out")))
409 ;; The 'configure' script is a wrapper for Waf and
410 ;; doesn't recognize things like '--enable-fast-install'.
411 (zero? (system* "./configure"
412 (string-append "--prefix=" out)))))
413 %standard-phases)))
414 (native-inputs
415 `(;; TODO: Build the documentation.
416 ;; ("docbook-xsl" ,docbook-xsl)
417 ;; ("libxml2" ,libxml2)
418 ;; ("libxslt" ,libxslt)
419 ("python" ,python-2))) ;for the Waf build system
420 (home-page "http://tdb.samba.org/")
421 (synopsis "Trivial database")
422 (description
423 "TDB is a Trivial Database. In concept, it is very much like GDBM,
424 and BSD's DB except that it allows multiple simultaneous writers and uses
425 locking internally to keep writers from trampling on each other. TDB is also
426 extremely small.")
427 (license lgpl3+)))
428
429 (define-public perl-dbi
430 (package
431 (name "perl-dbi")
432 (version "1.631")
433 (source (origin
434 (method url-fetch)
435 (uri (string-append
436 "mirror://cpan/authors/id/T/TI/TIMB/DBI-"
437 version ".tar.gz"))
438 (sha256
439 (base32
440 "04fmrnchhwi7jx4niaiv93vmi343hdm3xj04w9zr2m9hhqh782np"))))
441 (build-system perl-build-system)
442 (synopsis "Database independent interface for Perl")
443 (description "This package provides an database interface for Perl.")
444 (home-page "http://search.cpan.org/~timb/DBI-1.631/DBI.pm")
445 (license (package-license perl))))
446
447 (define-public perl-dbix-class
448 (package
449 (name "perl-dbix-class")
450 (version "0.082810")
451 (source
452 (origin
453 (method url-fetch)
454 (uri (string-append "mirror://cpan/authors/id/R/RI/RIBASUSHI/"
455 "DBIx-Class-" version ".tar.gz"))
456 (sha256
457 (base32
458 "1zlsswk8j2k024gwhdhia8ksrmb8065n98dahkk8c0r69wv85n04"))))
459 (build-system perl-build-system)
460 (native-inputs
461 `(("perl-dbd-sqlite" ,perl-dbd-sqlite)
462 ("perl-file-temp" ,perl-file-temp)
463 ("perl-package-stash" ,perl-package-stash)
464 ("perl-test-deep" ,perl-test-deep)
465 ("perl-test-exception" ,perl-test-exception)
466 ("perl-test-warn" ,perl-test-warn)))
467 (propagated-inputs
468 `(("perl-class-accessor-grouped" ,perl-class-accessor-grouped)
469 ("perl-class-c3-componentised" ,perl-class-c3-componentised)
470 ("perl-class-inspector" ,perl-class-inspector)
471 ("perl-config-any" ,perl-config-any)
472 ("perl-context-preserve" ,perl-context-preserve)
473 ("perl-data-dumper-concise" ,perl-data-dumper-concise)
474 ("perl-data-page" ,perl-data-page)
475 ("perl-dbi" ,perl-dbi)
476 ("perl-devel-globaldestruction" ,perl-devel-globaldestruction)
477 ("perl-hash-merge" ,perl-hash-merge)
478 ("perl-module-find" ,perl-module-find)
479 ("perl-moo" ,perl-moo)
480 ("perl-mro-compat" ,perl-mro-compat)
481 ("perl-namespace-clean" ,perl-namespace-clean)
482 ("perl-path-class" ,perl-path-class)
483 ("perl-scalar-list-utils" ,perl-scalar-list-utils)
484 ("perl-scope-guard" ,perl-scope-guard)
485 ("perl-sql-abstract" ,perl-sql-abstract)
486 ("perl-sub-name" ,perl-sub-name)
487 ("perl-text-balanced" ,perl-text-balanced)
488 ("perl-try-tiny" ,perl-try-tiny)))
489 (home-page "http://search.cpan.org/dist/DBIx-Class")
490 (synopsis "Extensible and flexible object <-> relational mapper")
491 (description "An SQL to OO mapper with an object API inspired by
492 Class::DBI (with a compatibility layer as a springboard for porting) and a
493 resultset API that allows abstract encapsulation of database operations. It
494 aims to make representing queries in your code as perl-ish as possible while
495 still providing access to as many of the capabilities of the database as
496 possible, including retrieving related records from multiple tables in a
497 single query, \"JOIN\", \"LEFT JOIN\", \"COUNT\", \"DISTINCT\", \"GROUP BY\",
498 \"ORDER BY\" and \"HAVING\" support.")
499 (license (package-license perl))))
500
501 (define-public perl-dbix-class-cursor-cached
502 (package
503 (name "perl-dbix-class-cursor-cached")
504 (version "1.001002")
505 (source
506 (origin
507 (method url-fetch)
508 (uri (string-append "mirror://cpan/authors/id/A/AR/ARCANEZ/"
509 "DBIx-Class-Cursor-Cached-" version ".tar.gz"))
510 (sha256
511 (base32
512 "19r7jr6pknxiirrybq0cd0lnr76xiw05arnfqgk9nrhp6c7vvil0"))))
513 (build-system perl-build-system)
514 (native-inputs
515 `(("perl-cache-cache" ,perl-cache-cache)
516 ("perl-dbd-sqlite" ,perl-dbd-sqlite)))
517 (propagated-inputs
518 `(("perl-carp-clan" ,perl-carp-clan)
519 ("perl-dbix-class" ,perl-dbix-class)))
520 (home-page "http://search.cpan.org/dist/DBIx-Class-Cursor-Cached")
521 (synopsis "Cursor with built-in caching support")
522 (description "DBIx::Class::Cursor::Cached provides a cursor class with
523 built-in caching support.")
524 (license (package-license perl))))
525
526 (define-public perl-dbix-class-introspectablem2m
527 (package
528 (name "perl-dbix-class-introspectablem2m")
529 (version "0.001001")
530 (source
531 (origin
532 (method url-fetch)
533 (uri (string-append "mirror://cpan/authors/id/G/GR/GRODITI/"
534 "DBIx-Class-IntrospectableM2M-" version ".tar.gz"))
535 (sha256
536 (base32
537 "0p9zx1yc1f6jg583l206wilsni2v8mlngc2vf2q8yn10pmy4y6wm"))))
538 (build-system perl-build-system)
539 (propagated-inputs
540 `(("perl-dbix-class" ,perl-dbix-class)))
541 (home-page "http://search.cpan.org/dist/DBIx-Class-IntrospectableM2M")
542 (synopsis "Introspect many-to-many relationships")
543 (description "Because the many-to-many relationships are not real
544 relationships, they can not be introspected with DBIx::Class. Many-to-many
545 relationships are actually just a collection of convenience methods installed
546 to bridge two relationships. This DBIx::Class component can be used to store
547 all relevant information about these non-relationships so they can later be
548 introspected and examined.")
549 (license (package-license perl))))
550
551 (define-public perl-dbix-class-schema-loader
552 (package
553 (name "perl-dbix-class-schema-loader")
554 (version "0.07042")
555 (source
556 (origin
557 (method url-fetch)
558 (uri (string-append "mirror://cpan/authors/id/I/IL/ILMARI/"
559 "DBIx-Class-Schema-Loader-" version ".tar.gz"))
560 (sha256
561 (base32
562 "0sb48as7azmj6s4acxh98wcvcik7lxm7dcjz1c3wdrkrbmbbz0jf"))))
563 (build-system perl-build-system)
564 (native-inputs
565 `(("perl-config-any" ,perl-config-any)
566 ("perl-config-general" ,perl-config-general)
567 ("perl-dbd-sqlite" ,perl-dbd-sqlite)
568 ("perl-dbix-class-introspectablem2m" ,perl-dbix-class-introspectablem2m)
569 ("perl-moose" ,perl-moose)
570 ("perl-moosex-markasmethods" ,perl-moosex-markasmethods)
571 ("perl-moosex-nonmoose" ,perl-moosex-nonmoose)
572 ("perl-namespace-autoclean" ,perl-namespace-autoclean)
573 ("perl-test-deep" ,perl-test-deep)
574 ("perl-test-differences" ,perl-test-differences)
575 ("perl-test-exception" ,perl-test-exception)
576 ("perl-test-pod" ,perl-test-pod)
577 ("perl-test-warn" ,perl-test-warn)))
578 (propagated-inputs
579 `(("perl-class-unload" ,perl-class-unload)
580 ("perl-class-inspector" ,perl-class-inspector)
581 ("perl-class-accessor-grouped" ,perl-class-accessor-grouped)
582 ("perl-class-c3-componentised" ,perl-class-c3-componentised)
583 ("perl-carp-clan" ,perl-carp-clan)
584 ("perl-data-dump" ,perl-data-dump)
585 ("perl-dbix-class" ,perl-dbix-class)
586 ("perl-hash-merge" ,perl-hash-merge)
587 ("perl-list-moreutils" ,perl-list-moreutils)
588 ("perl-lingua-en-inflect-phrase" ,perl-lingua-en-inflect-phrase)
589 ("perl-lingua-en-inflect-number" ,perl-lingua-en-inflect-number)
590 ("perl-lingua-en-tagger" ,perl-lingua-en-tagger)
591 ("perl-namespace-clean" ,perl-namespace-clean)
592 ("perl-mro-compat" ,perl-mro-compat)
593 ("perl-scope-guard" ,perl-scope-guard)
594 ("perl-string-camelcase" ,perl-string-camelcase)
595 ("perl-string-toidentifier-en" ,perl-string-toidentifier-en)
596 ("perl-sub-name" ,perl-sub-name)
597 ("perl-try-tiny" ,perl-try-tiny)))
598 (arguments `(#:tests? #f)) ;TODO: t/20invocations.t fails
599 (home-page "http://search.cpan.org/dist/DBIx-Class-Schema-Loader")
600 (synopsis "Create a DBIx::Class::Schema based on a database")
601 (description "DBIx::Class::Schema::Loader automates the definition of a
602 DBIx::Class::Schema by scanning database table definitions and setting up the
603 columns, primary keys, unique constraints and relationships.")
604 (license (package-license perl))))
605
606 (define-public perl-dbd-pg
607 (package
608 (name "perl-dbd-pg")
609 (version "3.5.1")
610 (source
611 (origin
612 (method url-fetch)
613 (uri (string-append "mirror://cpan/authors/id/T/TU/TURNSTEP/"
614 "DBD-Pg-" version ".tar.gz"))
615 (sha256
616 (base32
617 "0z0kf1kjgbi5f6nr63i2fnrx7629d9lvxg1q8sficwb3zdf1ggzx"))))
618 (build-system perl-build-system)
619 (native-inputs
620 `(("perl-dbi" ,perl-dbi)))
621 (propagated-inputs
622 `(("perl-dbi" ,perl-dbi)
623 ("postgresql" ,postgresql)))
624 (home-page "http://search.cpan.org/dist/DBD-Pg")
625 (synopsis "DBI PostgreSQL interface")
626 (description "")
627 (license (package-license perl))))
628
629 (define-public perl-dbd-mysql
630 (package
631 (name "perl-dbd-mysql")
632 (version "4.033")
633 (source
634 (origin
635 (method url-fetch)
636 (uri (string-append "mirror://cpan/authors/id/C/CA/CAPTTOFU/"
637 "DBD-mysql-" version ".tar.gz"))
638 (sha256
639 (base32
640 "0769xakykps0cx368g4vaips4w3bjk383rianiavq7sq6g6bp66c"))))
641 (build-system perl-build-system)
642 ;; Tests require running MySQL server
643 (arguments `(#:tests? #f))
644 (propagated-inputs
645 `(("perl-dbi" ,perl-dbi)
646 ("mysql" ,mysql)))
647 (home-page "http://search.cpan.org/dist/DBD-mysql")
648 (synopsis "DBI MySQL interface")
649 (description "This package provides a MySQL driver for the Perl5
650 @dfn{Database Interface} (DBI).")
651 (license (package-license perl))))
652
653 (define-public perl-dbd-sqlite
654 (package
655 (name "perl-dbd-sqlite")
656 (version "1.42")
657 (source (origin
658 (method url-fetch)
659 (uri (string-append
660 "mirror://cpan/authors/id/I/IS/ISHIGAKI/DBD-SQLite-"
661 version ".tar.gz"))
662 (sha256
663 (base32
664 "14x9cjsc8dz8ad1nad0bqiq9cbk1rjfb8h5y0rpk3pdl38y6afxb"))))
665 (build-system perl-build-system)
666 (inputs `(("sqlite" ,sqlite)))
667 (propagated-inputs `(("perl-dbi" ,perl-dbi)))
668 (synopsis "SQlite interface for Perl")
669 (description "DBD::SQLite is a Perl DBI driver for SQLite, that includes
670 the entire thing in the distribution. So in order to get a fast transaction
671 capable RDBMS working for your Perl project you simply have to install this
672 module, and nothing else.")
673 (license (package-license perl))
674 (home-page "http://search.cpan.org/~ishigaki/DBD-SQLite/lib/DBD/SQLite.pm")))
675
676 (define-public perl-sql-abstract
677 (package
678 (name "perl-sql-abstract")
679 (version "1.81")
680 (source
681 (origin
682 (method url-fetch)
683 (uri (string-append "mirror://cpan/authors/id/R/RI/RIBASUSHI/"
684 "SQL-Abstract-" version ".tar.gz"))
685 (sha256
686 (base32
687 "17sgwq3mvqjhv3b77cnvrq60xgp8harjhlnvpwmxc914rqc5ckaz"))))
688 (build-system perl-build-system)
689 (native-inputs
690 `(("perl-test-deep" ,perl-test-deep)
691 ("perl-test-exception" ,perl-test-exception)
692 ("perl-test-warn" ,perl-test-warn)))
693 (propagated-inputs
694 `(("perl-hash-merge" ,perl-hash-merge)
695 ("perl-moo" ,perl-moo)
696 ("perl-mro-compat" ,perl-mro-compat)
697 ("perl-text-balanced" ,perl-text-balanced)))
698 (home-page "http://search.cpan.org/dist/SQL-Abstract")
699 (synopsis "Generate SQL from Perl data structures")
700 (description "This module was inspired by the excellent DBIx::Abstract.
701 While based on the concepts used by DBIx::Abstract, the concepts used have
702 been modified to make the SQL easier to generate from Perl data structures.
703 The underlying idea is for this module to do what you mean, based on the data
704 structures you provide it, so that you don't have to modify your code every
705 time your data changes.")
706 (license (package-license perl))))
707
708 (define-public perl-sql-splitstatement
709 (package
710 (name "perl-sql-splitstatement")
711 (version "1.00020")
712 (source
713 (origin
714 (method url-fetch)
715 (uri (string-append "mirror://cpan/authors/id/E/EM/EMAZEP/"
716 "SQL-SplitStatement-" version ".tar.gz"))
717 (sha256
718 (base32
719 "0bqg45k4c9qkb2ypynlwhpvzsl4ssfagmsalys18s5c79ps30z7p"))))
720 (build-system perl-build-system)
721 (native-inputs
722 `(("perl-test-exception" ,perl-test-exception)))
723 (propagated-inputs
724 `(("perl-class-accessor" ,perl-class-accessor)
725 ("perl-list-moreutils" ,perl-list-moreutils)
726 ("perl-regexp-common" ,perl-regexp-common)
727 ("perl-sql-tokenizer" ,perl-sql-tokenizer)))
728 (home-page "http://search.cpan.org/dist/SQL-SplitStatement")
729 (synopsis "Split SQL code into atomic statements")
730 (description "This module tries to split any SQL code, even including
731 non-standard extensions, into the atomic statements it is composed of.")
732 (license (package-license perl))))
733
734 (define-public perl-sql-tokenizer
735 (package
736 (name "perl-sql-tokenizer")
737 (version "0.24")
738 (source
739 (origin
740 (method url-fetch)
741 (uri (string-append "mirror://cpan/authors/id/I/IZ/IZUT/"
742 "SQL-Tokenizer-" version ".tar.gz"))
743 (sha256
744 (base32
745 "1qa2dfbzdlr5qqdam9yn78z5w3al5r8577x06qan8wv58ay6ka7s"))))
746 (build-system perl-build-system)
747 (home-page "http://search.cpan.org/dist/SQL-Tokenizer")
748 (synopsis "SQL tokenizer")
749 (description "SQL::Tokenizer is a tokenizer for SQL queries. It does not
750 claim to be a parser or query verifier. It just creates sane tokens from a
751 valid SQL query.")
752 (license (package-license perl))))
753
754 (define-public unixodbc
755 (package
756 (name "unixodbc")
757 (version "2.3.2")
758 (source (origin
759 (method url-fetch)
760 (uri
761 (string-append
762 "ftp://ftp.unixodbc.org/pub/unixODBC/unixODBC-" version ".tar.gz"))
763 (sha256
764 (base32 "16jw5fq7wgfky6ak1h2j2pqx99jivsdl4q8aq6immpr55xs5jd4w"))))
765 (build-system gnu-build-system)
766 (synopsis "Data source abstraction library")
767 (description "Unixodbc is a library providing an API with which to access
768 data sources. Data sources include SQL Servers and any software with an ODBC
769 Driver.")
770 (license lgpl2.1+)
771 ;; COPYING contains copy of lgpl2.1 - but copyright notices just say "LGPL"
772 (home-page "http://www.unixodbc.org")))
773
774 (define-public unqlite
775 (package
776 (name "unqlite")
777 (version "1.1.6")
778 (source (origin
779 (method url-fetch)
780 ;; Contains bug fixes against the official release, and has an
781 ;; autotooled build system.
782 (uri (string-append "https://github.com/aidin36/tocc/releases/"
783 "download/v1.0.0/"
784 "unqlite-unofficial-" version ".tar.gz"))
785 (sha256
786 (base32
787 "1sbpvhg15gadq0mpcy16q7k3rkg4b4dicpnn5xifpkpn02sqik3s"))))
788 (build-system gnu-build-system)
789 (arguments `(#:tests? #f)) ;No check target
790 (home-page "http://www.unqlite.org")
791 (synopsis "In-memory key/value and document store")
792 (description
793 "UnQLite is an in-process software library which implements a
794 self-contained, serverless, zero-configuration, transactional NoSQL
795 database engine. UnQLite is a document store database similar to
796 MongoDB, Redis, CouchDB, etc. as well as a standard Key/Value store
797 similar to BerkeleyDB, LevelDB, etc.")
798 (license bsd-2)))
799
800 (define-public redis
801 (package
802 (name "redis")
803 (version "3.0.4")
804 (source (origin
805 (method url-fetch)
806 (uri (string-append "http://download.redis.io/releases/redis-"
807 version".tar.gz"))
808 (sha256
809 (base32
810 "1kqjc4qrasadgnl3cg71x3g5qpw2rilyk4pwl151698rb2nr0pm3"))))
811 (build-system gnu-build-system)
812 (arguments
813 '(#:tests? #f ; tests related to master/slave and replication fail
814 #:phases (modify-phases %standard-phases
815 (delete 'configure))
816 #:make-flags `("CC=gcc"
817 "MALLOC=libc"
818 ,(string-append "PREFIX="
819 (assoc-ref %outputs "out")))))
820 (synopsis "Key-value cache and store")
821 (description "Redis is an advanced key-value cache and store. Redis
822 supports many data structures including strings, hashes, lists, sets, sorted
823 sets, bitmaps and hyperloglogs.")
824 (home-page "http://redis.io/")
825 (license bsd-3)))
826
827 (define-public kyotocabinet
828 (package
829 (name "kyotocabinet")
830 (version "1.2.76")
831 (source (origin
832 (method url-fetch)
833 (uri (string-append "http://fallabs.com/kyotocabinet/pkg/"
834 name "-" version ".tar.gz"))
835 (sha256
836 (base32
837 "0g6js20x7vnpq4p8ghbw3mh9wpqksya9vwhzdx6dnlf354zjsal1"))))
838 (build-system gnu-build-system)
839 (arguments
840 `(#:configure-flags
841 (list
842 (string-append "LDFLAGS=-Wl,-rpath="
843 (assoc-ref %outputs "out") "/lib"))))
844 (inputs `(("zlib" ,zlib)))
845 (home-page "http://fallabs.com/kyotocabinet/")
846 (synopsis
847 "Kyoto Cabinet is a modern implementation of the DBM database")
848 (description
849 "Kyoto Cabinet is a standalone file-based database that supports Hash
850 and B+ Tree data storage models. It is a fast key-value lightweight
851 database and supports many programming languages. It is a NoSQL database.")
852 (license gpl3+)))