Commit | Line | Data |
---|---|---|
5f96f303 | 1 | ;;; GNU Guix --- Functional package management for GNU |
ff1f39e3 | 2 | ;;; Copyright © 2012, 2013, 2014, 2015, 2016 Ludovic Courtès <ludo@gnu.org> |
b86c013c | 3 | ;;; Copyright © 2012, 2014, 2015 Andreas Enge <andreas@enge.fr> |
5f96f303 | 4 | ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com> |
218a2106 | 5 | ;;; Copyright © 2014, 2016 David Thompson <davet@gnu.org> |
8047d13d | 6 | ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org> |
e61fd0f0 | 7 | ;;; Copyright © 2015 Eric Bavier <bavier@member.fsf.org> |
77631745 | 8 | ;;; Copyright © 2015 Sou Bunnbu <iyzsong@gmail.com> |
b747a9db | 9 | ;;; Copyright © 2015 Leo Famulari <leo@famulari.name> |
9a9d6d78 | 10 | ;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il> |
bdc11dc4 | 11 | ;;; Copyright © 2016, 2017 ng0 <contact.ng0@cryptolab.net> |
4c6aa73b | 12 | ;;; Copyright © 2016 Roel Janssen <roel@gnu.org> |
0e1b262e | 13 | ;;; Copyright © 2016 David Craven <david@craven.ch> |
fe71eee0 | 14 | ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org> |
62ea44fc | 15 | ;;; Copyright © 2016 Andy Patterson <ajpatter@uwaterloo.ca> |
b9f771a7 | 16 | ;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com> |
259a94e9 | 17 | ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be> |
d39a84e8 | 18 | ;;; Copyright © 2017 Arun Isaac <arunisaac@systemreboot.net> |
fda852ff | 19 | ;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr> |
f30ff28b | 20 | ;;; Copyright © 2017 Alex Vong <alexvong1995@gmail.com> |
5f96f303 LC |
21 | ;;; |
22 | ;;; This file is part of GNU Guix. | |
23 | ;;; | |
24 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
25 | ;;; under the terms of the GNU General Public License as published by | |
26 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
27 | ;;; your option) any later version. | |
28 | ;;; | |
29 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
30 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
31 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
32 | ;;; GNU General Public License for more details. | |
33 | ;;; | |
34 | ;;; You should have received a copy of the GNU General Public License | |
35 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
36 | ||
37 | (define-module (gnu packages databases) | |
38 | #:use-module (gnu packages) | |
06a035db | 39 | #:use-module (gnu packages algebra) |
4c6aa73b RJ |
40 | #:use-module (gnu packages autotools) |
41 | #:use-module (gnu packages avahi) | |
77e52190 | 42 | #:use-module (gnu packages base) |
b747a9db | 43 | #:use-module (gnu packages bash) |
06a035db | 44 | #:use-module (gnu packages bison) |
23bbd7dd | 45 | #:use-module (gnu packages boost) |
06a035db MB |
46 | #:use-module (gnu packages check) |
47 | #:use-module (gnu packages compression) | |
62ea44fc | 48 | #:use-module (gnu packages crypto) |
06a035db MB |
49 | #:use-module (gnu packages curl) |
50 | #:use-module (gnu packages cyrus-sasl) | |
51 | #:use-module (gnu packages emacs) | |
4c6aa73b RJ |
52 | #:use-module (gnu packages gettext) |
53 | #:use-module (gnu packages glib) | |
06a035db MB |
54 | #:use-module (gnu packages gnupg) |
55 | #:use-module (gnu packages jemalloc) | |
708155df | 56 | #:use-module (gnu packages language) |
686144e9 | 57 | #:use-module (gnu packages libevent) |
5f96f303 | 58 | #:use-module (gnu packages linux) |
d39a84e8 | 59 | #:use-module (gnu packages man) |
5f96f303 | 60 | #:use-module (gnu packages ncurses) |
d3c6ad0a | 61 | #:use-module (gnu packages parallel) |
77631745 | 62 | #:use-module (gnu packages pcre) |
06a035db | 63 | #:use-module (gnu packages perl) |
4c6aa73b | 64 | #:use-module (gnu packages pkg-config) |
d3c6ad0a | 65 | #:use-module (gnu packages popt) |
06a035db | 66 | #:use-module (gnu packages python) |
4c6aa73b | 67 | #:use-module (gnu packages rdf) |
06a035db MB |
68 | #:use-module (gnu packages readline) |
69 | #:use-module (gnu packages tcl) | |
70 | #:use-module (gnu packages tls) | |
77631745 | 71 | #:use-module (gnu packages xml) |
0e1b262e | 72 | #:use-module ((guix licenses) #:prefix license:) |
5f96f303 LC |
73 | #:use-module (guix packages) |
74 | #:use-module (guix download) | |
75 | #:use-module (guix build-system gnu) | |
274da61d | 76 | #:use-module (guix build-system perl) |
4d98bfaf | 77 | #:use-module (guix build-system python) |
77631745 | 78 | #:use-module (guix build-system cmake) |
329d13b8 | 79 | #:use-module (guix utils) |
5f96f303 LC |
80 | #:use-module (srfi srfi-26) |
81 | #:use-module (ice-9 match)) | |
82 | ||
4c6aa73b RJ |
83 | (define-public 4store |
84 | (package | |
85 | (name "4store") | |
86 | (version "1.1.6") | |
87 | (source (origin | |
88 | (method url-fetch) | |
89 | (uri (string-append "https://github.com/garlik/4store/archive/v" | |
90 | version ".tar.gz")) | |
91 | (file-name (string-append name "-" version ".tar.gz")) | |
92 | (sha256 | |
93 | (base32 "004fmcf1w75zhc1x3zc6kc97j4jqn2v5nhk6yb3z3cpfrhzi9j50")) | |
94 | (patches (list (search-patch "4store-fix-buildsystem.patch"))))) | |
95 | (build-system gnu-build-system) | |
96 | (native-inputs | |
97 | `(("perl" ,perl) | |
98 | ("python" ,python-2) | |
99 | ("autoconf" ,autoconf) | |
100 | ("automake" ,automake) | |
b94a6ca0 | 101 | ("gettext" ,gettext-minimal) |
4c6aa73b | 102 | ("libtool" ,libtool) |
74c8b174 | 103 | ("pcre" ,pcre "bin") ;for 'pcre-config' |
4c6aa73b RJ |
104 | ("pkg-config" ,pkg-config))) |
105 | (inputs | |
106 | `(("glib" ,glib) | |
107 | ("rasqal" ,rasqal) | |
108 | ("libxml2" ,libxml2) | |
109 | ("raptor2" ,raptor2) | |
110 | ("readline" ,readline) | |
111 | ("avahi" ,avahi) | |
4c6aa73b RJ |
112 | ("cyrus-sasl" ,cyrus-sasl) |
113 | ("openssl" ,openssl) | |
114 | ("util-linux" ,util-linux))) | |
115 | (arguments | |
116 | `(#:phases | |
117 | (modify-phases %standard-phases | |
118 | (add-before 'configure 'generate-configure | |
119 | (lambda _ | |
120 | (zero? (system* "./autogen.sh"))))))) | |
121 | ;; http://www.4store.org has been down for a while now. | |
122 | (home-page "https://github.com/garlik/4store") | |
123 | (synopsis "Clustered RDF storage and query engine") | |
124 | (description "4store is a RDF/SPARQL store written in C, supporting | |
125 | either single machines or networked clusters.") | |
ba8b9f8d | 126 | (license license:gpl3+))) |
4c6aa73b | 127 | |
b416aadf LC |
128 | (define-public gdbm |
129 | (package | |
130 | (name "gdbm") | |
821072e2 | 131 | (version "1.13") |
b416aadf LC |
132 | (source (origin |
133 | (method url-fetch) | |
134 | (uri (string-append "mirror://gnu/gdbm/gdbm-" | |
135 | version ".tar.gz")) | |
136 | (sha256 | |
137 | (base32 | |
821072e2 | 138 | "0lx201q20dvc70f8a3c9s7s18z15inlxvbffph97ngvrgnyjq9cx")))) |
b416aadf LC |
139 | (arguments `(#:configure-flags '("--enable-libgdbm-compat"))) |
140 | (build-system gnu-build-system) | |
6fd52309 | 141 | (home-page "http://www.gnu.org.ua/software/gdbm") |
b416aadf LC |
142 | (synopsis |
143 | "Hash library of database functions compatible with traditional dbm") | |
144 | (description | |
145 | "GDBM is a library for manipulating hashed databases. It is used to | |
146 | store key/value pairs in a file in a manner similar to the Unix dbm library | |
147 | and provides interfaces to the traditional file format.") | |
ba8b9f8d | 148 | (license license:gpl3+))) |
b416aadf | 149 | |
5f96f303 LC |
150 | (define-public bdb |
151 | (package | |
152 | (name "bdb") | |
18e681bf | 153 | (version "6.2.23") |
5f96f303 LC |
154 | (source (origin |
155 | (method url-fetch) | |
18e681bf EF |
156 | (uri (string-append "http://download.oracle.com/berkeley-db/db-" |
157 | version ".tar.gz")) | |
158 | (sha256 | |
159 | (base32 | |
160 | "1isxx4jfmnh913jzhp8hhfngbk6dsg46f4kjpvvc56maj64jqqa7")))) | |
5f96f303 LC |
161 | (build-system gnu-build-system) |
162 | (outputs '("out" ; programs, libraries, headers | |
163 | "doc")) ; 94 MiB of HTML docs | |
164 | (arguments | |
165 | '(#:tests? #f ; no check target available | |
ff1f39e3 | 166 | #:disallowed-references ("doc") |
5bef7749 AE |
167 | #:phases |
168 | (alist-replace | |
169 | 'configure | |
170 | (lambda* (#:key outputs #:allow-other-keys) | |
171 | (let ((out (assoc-ref outputs "out")) | |
172 | (doc (assoc-ref outputs "doc"))) | |
173 | ;; '--docdir' is not honored, so we need to patch. | |
174 | (substitute* "dist/Makefile.in" | |
175 | (("docdir[[:blank:]]*=.*") | |
176 | (string-append "docdir = " doc "/share/doc/bdb"))) | |
5f96f303 | 177 | |
5bef7749 AE |
178 | (zero? |
179 | (system* "./dist/configure" | |
180 | (string-append "--prefix=" out) | |
181 | (string-append "CONFIG_SHELL=" (which "bash")) | |
182 | (string-append "SHELL=" (which "bash")) | |
5f96f303 | 183 | |
0e50d521 LC |
184 | ;; Remove 7 MiB of .a files. |
185 | "--disable-static" | |
186 | ||
5bef7749 AE |
187 | ;; The compatibility mode is needed by some packages, |
188 | ;; notably iproute2. | |
b86c013c AE |
189 | "--enable-compat185" |
190 | ||
191 | ;; The following flag is needed so that the inclusion | |
192 | ;; of db_cxx.h into C++ files works; it leads to | |
193 | ;; HAVE_CXX_STDHEADERS being defined in db_cxx.h. | |
194 | "--enable-cxx")))) | |
5f96f303 | 195 | %standard-phases))) |
35b9e423 | 196 | (synopsis "Berkeley database") |
5f96f303 LC |
197 | (description |
198 | "Berkeley DB is an embeddable database allowing developers the choice of | |
199 | SQL, Key/Value, XML/XQuery or Java Object storage for their data model.") | |
a24fda81 MB |
200 | ;; Starting with version 6, BDB is distributed under AGPL3. Many individual |
201 | ;; files are covered by the 3-clause BSD license. | |
ba8b9f8d | 202 | (license (list license:agpl3+ license:bsd-3)) |
5f96f303 LC |
203 | (home-page |
204 | "http://www.oracle.com/us/products/database/berkeley-db/overview/index.html"))) | |
205 | ||
557fa39c EF |
206 | (define-public bdb-5.3 |
207 | (package (inherit bdb) | |
208 | (name "bdb") | |
209 | (version "5.3.28") | |
ba8b9f8d MB |
210 | (license (license:non-copyleft "file://LICENSE" |
211 | "See LICENSE in the distribution.")) | |
557fa39c EF |
212 | (source (origin |
213 | (method url-fetch) | |
214 | (uri (string-append "http://download.oracle.com/berkeley-db/db-" | |
215 | version ".tar.gz")) | |
216 | (sha256 | |
217 | (base32 | |
9a9d6d78 EF |
218 | "0a1n5hbl7027fbz5lm0vp0zzfp1hmxnz14wx3zl9563h83br5ag0")))) |
219 | (arguments | |
220 | `(#:tests? #f ; no check target available | |
221 | #:disallowed-references ("doc") | |
222 | #:phases | |
223 | (alist-replace | |
224 | 'configure | |
225 | (lambda* (#:key outputs #:allow-other-keys) | |
226 | (let ((out (assoc-ref outputs "out")) | |
227 | (doc (assoc-ref outputs "doc"))) | |
228 | ;; '--docdir' is not honored, so we need to patch. | |
229 | (substitute* "dist/Makefile.in" | |
230 | (("docdir[[:blank:]]*=.*") | |
231 | (string-append "docdir = " doc "/share/doc/bdb"))) | |
232 | ||
233 | (zero? | |
234 | (system* "./dist/configure" | |
235 | (string-append "--prefix=" out) | |
236 | (string-append "CONFIG_SHELL=" (which "bash")) | |
237 | (string-append "SHELL=" (which "bash")) | |
238 | ||
239 | ;; Bdb doesn't recognize aarch64 as an architecture. | |
240 | ,@(if (string=? "aarch64-linux" (%current-system)) | |
241 | '("--build=aarch64-unknown-linux-gnu") | |
242 | '()) | |
243 | ||
244 | ;; Remove 7 MiB of .a files. | |
245 | "--disable-static" | |
246 | ||
247 | ;; The compatibility mode is needed by some packages, | |
248 | ;; notably iproute2. | |
249 | "--enable-compat185" | |
250 | ||
251 | ;; The following flag is needed so that the inclusion | |
252 | ;; of db_cxx.h into C++ files works; it leads to | |
253 | ;; HAVE_CXX_STDHEADERS being defined in db_cxx.h. | |
254 | "--enable-cxx")))) | |
255 | %standard-phases))))) | |
557fa39c | 256 | |
b9f771a7 MB |
257 | (define-public leveldb |
258 | (package | |
259 | (name "leveldb") | |
04c88363 | 260 | (version "1.20") |
b9f771a7 MB |
261 | (source (origin |
262 | (method url-fetch) | |
263 | (uri (string-append "https://github.com/google/leveldb" | |
264 | "/archive/v" version ".tar.gz")) | |
265 | (file-name (string-append name "-" version ".tar.gz")) | |
266 | (sha256 | |
267 | (base32 | |
04c88363 | 268 | "0r36bcrj6b2afsp4aw1gjai3jbs1c7734pxpc1jz7hh9nasyiazm")))) |
b9f771a7 MB |
269 | (build-system gnu-build-system) |
270 | (arguments | |
271 | '(#:make-flags (list "CC=gcc") | |
272 | #:phases | |
273 | (modify-phases %standard-phases | |
274 | (delete 'configure) | |
275 | (replace 'install | |
276 | ;; There is no install target, so we do it here. | |
277 | (lambda* (#:key outputs #:allow-other-keys) | |
278 | (let* ((out (assoc-ref outputs "out")) | |
279 | (lib (string-append out "/lib")) | |
280 | (include (string-append out "/include"))) | |
281 | (for-each (lambda (file) | |
282 | (install-file file lib)) | |
283 | (find-files "out-shared" "^libleveldb\\.so.*$")) | |
284 | (copy-recursively "include" include) | |
285 | #t)))))) | |
286 | (inputs | |
287 | `(("snappy" ,snappy))) | |
288 | (home-page "http://leveldb.org/") | |
289 | (synopsis "Fast key-value storage library") | |
290 | (description | |
291 | "LevelDB is a fast key-value storage library that provides an ordered | |
292 | mapping from string keys to string values.") | |
ba8b9f8d | 293 | (license license:bsd-3))) |
b9f771a7 | 294 | |
686144e9 CB |
295 | (define-public memcached |
296 | (package | |
297 | (name "memcached") | |
298 | (version "1.5.0") | |
299 | (source | |
300 | (origin | |
301 | (method url-fetch) | |
302 | (uri (string-append | |
303 | "https://memcached.org/files/memcached-" version ".tar.gz")) | |
304 | (sha256 | |
305 | (base32 "0chwc0g7wfvcad36z8pf2jbgygdnm9nm1l6pwjsn3d2b089gh0f0")))) | |
306 | (build-system gnu-build-system) | |
307 | (inputs | |
308 | `(("libevent" ,libevent) | |
309 | ("cyrus-sasl" ,cyrus-sasl))) | |
310 | (home-page "https://memcached.org/") | |
311 | (synopsis "In memory caching service") | |
312 | (description "Memcached is a in memory key value store. It has a small | |
313 | and generic API, and was originally intended for use with dynamic web | |
314 | applications.") | |
315 | (license license:bsd-3))) | |
316 | ||
5f96f303 LC |
317 | (define-public mysql |
318 | (package | |
319 | (name "mysql") | |
6f226c07 | 320 | (version "5.7.19") |
5f96f303 LC |
321 | (source (origin |
322 | (method url-fetch) | |
23bbd7dd EF |
323 | (uri (list (string-append |
324 | "http://dev.mysql.com/get/Downloads/MySQL-" | |
325 | (version-major+minor version) "/" | |
326 | name "-" version ".tar.gz") | |
327 | (string-append | |
328 | "http://downloads.mysql.com/archives/get/file/" | |
329 | name "-" version ".tar.gz"))) | |
5f96f303 LC |
330 | (sha256 |
331 | (base32 | |
6f226c07 | 332 | "1c8y54yk756179nx4dgg79dijmjdq5n8l057cnqsg70pjdpyfl9y")))) |
329d13b8 SB |
333 | (build-system cmake-build-system) |
334 | (arguments | |
69419655 | 335 | `(#:configure-flags |
329d13b8 SB |
336 | '("-DBUILD_CONFIG=mysql_release" |
337 | "-DWITH_SSL=system" | |
338 | "-DWITH_ZLIB=system" | |
339 | "-DDEFAULT_CHARSET=utf8" | |
340 | "-DDEFAULT_COLLATION=utf8_general_ci" | |
341 | "-DMYSQL_DATADIR=/var/lib/mysql" | |
342 | "-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock" | |
343 | "-DINSTALL_INFODIR=share/mysql/docs" | |
344 | "-DINSTALL_MANDIR=share/man" | |
345 | "-DINSTALL_PLUGINDIR=lib/mysql/plugin" | |
346 | "-DINSTALL_SCRIPTDIR=bin" | |
347 | "-DINSTALL_INCLUDEDIR=include/mysql" | |
348 | "-DINSTALL_DOCREADMEDIR=share/mysql/docs" | |
349 | "-DINSTALL_SUPPORTFILESDIR=share/mysql" | |
350 | "-DINSTALL_MYSQLSHAREDIR=share/mysql" | |
351 | "-DINSTALL_DOCDIR=share/mysql/docs" | |
352 | "-DINSTALL_SHAREDIR=share/mysql" | |
353 | ;; Get rid of test data. | |
354 | "-DINSTALL_MYSQLTESTDIR=" | |
3f289db6 LC |
355 | "-DINSTALL_SQLBENCHDIR=") |
356 | #:phases (modify-phases %standard-phases | |
357 | (add-after | |
23bbd7dd EF |
358 | 'unpack 'patch-boost-version |
359 | (lambda _ | |
360 | ;; Mysql wants boost-1.59.0 specifically | |
361 | (substitute* "cmake/boost.cmake" | |
69419655 EB |
362 | (("59") |
363 | ,(match (string-split (package-version boost) #\.) | |
364 | ((_ minor . _) minor)))))) | |
6a52df50 LC |
365 | (add-after |
366 | 'install 'remove-extra-binaries | |
367 | (lambda* (#:key outputs #:allow-other-keys) | |
368 | (let ((out (assoc-ref outputs "out"))) | |
369 | ;; Remove the 3 *_embedded files, which weigh in at | |
370 | ;; 14 MiB each. | |
371 | (for-each delete-file | |
372 | (find-files (string-append out "/bin") | |
373 | "_embedded$")) | |
b4f67b7e EF |
374 | #t)))) |
375 | ;; On aarch64 the test suite runs out of memory and fails. | |
376 | ,@(if (string-prefix? "aarch64-linux" | |
377 | (or (%current-target-system) (%current-system))) | |
378 | '(#:tests? #f) | |
379 | '()))) | |
329d13b8 SB |
380 | (native-inputs |
381 | `(("bison" ,bison) | |
382 | ("perl" ,perl))) | |
5f96f303 | 383 | (inputs |
23bbd7dd EF |
384 | `(("boost" ,boost) |
385 | ("libaio" ,libaio) | |
386 | ("ncurses" ,ncurses) | |
5f96f303 | 387 | ("openssl" ,openssl) |
23bbd7dd | 388 | ("zlib" ,zlib))) |
5f96f303 | 389 | (home-page "http://www.mysql.com/") |
9e771e3b | 390 | (synopsis "Fast, easy to use, and popular database") |
5f96f303 LC |
391 | (description |
392 | "MySQL is a fast, reliable, and easy to use relational database | |
393 | management system that supports the standardized Structured Query | |
394 | Language.") | |
ba8b9f8d | 395 | (license license:gpl2))) |
5f96f303 | 396 | |
77631745 SB |
397 | (define-public mariadb |
398 | (package | |
399 | (name "mariadb") | |
f30ff28b | 400 | (version "10.1.26") |
77631745 SB |
401 | (source (origin |
402 | (method url-fetch) | |
403 | (uri (string-append "https://downloads.mariadb.org/f/" | |
404 | name "-" version "/source/" | |
405 | name "-" version ".tar.gz")) | |
406 | (sha256 | |
407 | (base32 | |
f30ff28b | 408 | "0ggpdcal0if9y6h9hp1yv2q65cbkjfl4p8rqk68a5pk7k75v325s")))) |
77631745 SB |
409 | (build-system cmake-build-system) |
410 | (arguments | |
411 | '(#:configure-flags | |
412 | '("-DBUILD_CONFIG=mysql_release" | |
6cf8e576 LF |
413 | ;; Linking with libarchive fails, like this: |
414 | ||
415 | ;; ld: /gnu/store/...-libarchive-3.2.2/lib/libarchive.a(archive_entry.o): | |
416 | ;; relocation R_X86_64_32 against `.bss' can not be used when | |
417 | ;; making a shared object; recompile with -fPIC | |
418 | ||
419 | ;; For now, disable the features that that use libarchive (xtrabackup). | |
420 | "-DWITH_LIBARCHIVE=OFF" | |
421 | ||
77631745 SB |
422 | "-DDEFAULT_CHARSET=utf8" |
423 | "-DDEFAULT_COLLATION=utf8_general_ci" | |
424 | "-DMYSQL_DATADIR=/var/lib/mysql" | |
425 | "-DMYSQL_UNIX_ADDR=/run/mysqld/mysqld.sock" | |
426 | "-DINSTALL_INFODIR=share/mysql/docs" | |
427 | "-DINSTALL_MANDIR=share/man" | |
428 | "-DINSTALL_PLUGINDIR=lib/mysql/plugin" | |
429 | "-DINSTALL_SCRIPTDIR=bin" | |
430 | "-DINSTALL_INCLUDEDIR=include/mysql" | |
431 | "-DINSTALL_DOCREADMEDIR=share/mysql/docs" | |
432 | "-DINSTALL_SUPPORTFILESDIR=share/mysql/support-files" | |
433 | "-DINSTALL_MYSQLSHAREDIR=share/mysql" | |
434 | "-DINSTALL_DOCDIR=share/mysql/docs" | |
435 | "-DINSTALL_SHAREDIR=share/mysql") | |
436 | #:phases | |
437 | (modify-phases %standard-phases | |
438 | (add-before | |
439 | 'configure 'pre-configure | |
440 | (lambda _ | |
441 | (setenv "CONFIG_SHELL" (which "sh")) | |
77631745 SB |
442 | #t)) |
443 | (add-after | |
444 | 'install 'post-install | |
445 | (lambda* (#:key outputs #:allow-other-keys) | |
446 | (let* ((out (assoc-ref outputs "out")) | |
447 | (test (assoc-ref outputs "test"))) | |
448 | (substitute* (string-append out "/bin/mysql_install_db") | |
449 | (("basedir=\"\"") | |
450 | (string-append "basedir=\"" out "\""))) | |
451 | ;; Remove unneeded files for testing. | |
452 | (with-directory-excursion out | |
453 | (for-each delete-file-recursively | |
454 | '("data" "mysql-test" "sql-bench" | |
455 | "share/man/man1/mysql-test-run.pl.1"))))))))) | |
456 | (native-inputs | |
457 | `(("bison" ,bison) | |
458 | ("perl" ,perl))) | |
459 | (inputs | |
460 | `(("jemalloc" ,jemalloc) | |
461 | ("libaio" ,libaio) | |
462 | ("libxml2" ,libxml2) | |
463 | ("ncurses" ,ncurses) | |
464 | ("openssl" ,openssl) | |
465 | ("pcre" ,pcre) | |
466 | ("zlib" ,zlib))) | |
467 | (home-page "https://mariadb.org/") | |
468 | (synopsis "SQL database server") | |
469 | (description | |
470 | "MariaDB is a multi-user and multi-threaded SQL database server, designed | |
471 | as a drop-in replacement of MySQL.") | |
ba8b9f8d | 472 | (license license:gpl2))) |
77631745 | 473 | |
5f96f303 LC |
474 | (define-public postgresql |
475 | (package | |
476 | (name "postgresql") | |
1a1558e8 | 477 | (version "9.6.4") |
5f96f303 LC |
478 | (source (origin |
479 | (method url-fetch) | |
dbeaf8f2 | 480 | (uri (string-append "https://ftp.postgresql.org/pub/source/v" |
9020890b | 481 | version "/postgresql-" version ".tar.bz2")) |
5f96f303 LC |
482 | (sha256 |
483 | (base32 | |
1a1558e8 | 484 | "04yffrrmn85k25n3nq389aa9c1j8mkimrf889kayl772h9nv2fib")))) |
5f96f303 | 485 | (build-system gnu-build-system) |
dd213082 | 486 | (arguments |
b7aa3f5d DM |
487 | `(#:configure-flags '("--with-uuid=e2fs") |
488 | #:phases | |
dd213082 JD |
489 | (modify-phases %standard-phases |
490 | (add-before 'configure 'patch-/bin/sh | |
491 | (lambda _ | |
492 | ;; Refer to the actual shell. | |
493 | (substitute* '("src/bin/pg_ctl/pg_ctl.c" | |
494 | "src/bin/psql/command.c") | |
495 | (("/bin/sh") (which "sh"))) | |
b7aa3f5d DM |
496 | #t)) |
497 | (add-after 'build 'build-contrib | |
498 | (lambda _ | |
499 | (zero? (system* "make" "-C" "contrib")))) | |
500 | (add-after 'install 'install-contrib | |
501 | (lambda _ | |
502 | (zero? (system* "make" "-C" "contrib" "install"))))))) | |
5f96f303 LC |
503 | (inputs |
504 | `(("readline" ,readline) | |
b7aa3f5d | 505 | ("libuuid" ,util-linux) |
5f96f303 | 506 | ("zlib" ,zlib))) |
d887f420 | 507 | (home-page "https://www.postgresql.org/") |
5f96f303 LC |
508 | (synopsis "Powerful object-relational database system") |
509 | (description | |
510 | "PostgreSQL is a powerful object-relational database system. It is fully | |
511 | ACID compliant, has full support for foreign keys, joins, views, triggers, and | |
512 | stored procedures (in multiple languages). It includes most SQL:2008 data | |
513 | types, including INTEGER, NUMERIC, BOOLEAN, CHAR, VARCHAR, DATE, INTERVAL, and | |
514 | TIMESTAMP. It also supports storage of binary large objects, including | |
515 | pictures, sounds, or video.") | |
ba8b9f8d | 516 | (license (license:x11-style "file://COPYRIGHT")))) |
5f96f303 | 517 | |
259a94e9 TD |
518 | (define-public qdbm |
519 | (package | |
520 | (name "qdbm") | |
521 | (version "1.8.78") | |
522 | (source | |
523 | (origin | |
524 | (method url-fetch) | |
525 | (uri (string-append "http://fallabs.com/" name "/" | |
526 | name "-" version ".tar.gz")) | |
527 | (sha256 | |
528 | (base32 | |
529 | "0gmpvhn02pkq280ffmn4da1g4mdr1xxz7l80b7y4n7km1mrzwrml")))) | |
530 | (build-system gnu-build-system) | |
531 | (arguments | |
532 | `( #:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath=" | |
533 | (assoc-ref %outputs "out") | |
534 | "/lib")))) | |
535 | (home-page "http://fallabs.com/qdbm") | |
536 | (synopsis "Key-value database") | |
537 | (description "QDBM is a library of routines for managing a | |
538 | database. The database is a simple data file containing key-value | |
539 | pairs. Every key and value is serial bytes with variable length. | |
540 | Binary data as well as character strings can be used as a key or a | |
541 | value. There is no concept of data tables or data types. Records are | |
542 | organized in a hash table or B+ tree.") | |
543 | (license license:lgpl2.1+))) | |
544 | ||
5f96f303 LC |
545 | (define-public recutils |
546 | (package | |
547 | (name "recutils") | |
548 | (version "1.7") | |
549 | (source (origin | |
550 | (method url-fetch) | |
551 | (uri (string-append "mirror://gnu/recutils/recutils-" | |
552 | version ".tar.gz")) | |
553 | (sha256 | |
554 | (base32 | |
555 | "0cdwa4094x3yx7vn98xykvnlp9rngvd58d19vs3vh5hrvggccg93")))) | |
556 | (build-system gnu-build-system) | |
557 | ||
558 | ;; Running tests in parallel leads to test failures and crashes in | |
559 | ;; torture/utils. | |
b747a9db LF |
560 | (arguments '(#:parallel-tests? #f |
561 | #:configure-flags | |
562 | (list (string-append "--with-bash-headers=" | |
563 | (assoc-ref %build-inputs "bash:include") | |
c21af659 LC |
564 | "/include/bash")) |
565 | ||
566 | #:phases (modify-phases %standard-phases | |
567 | (add-before 'build 'set-bash4.4-header-location | |
568 | (lambda _ | |
569 | (substitute* "bash/Makefile.in" | |
570 | ;; Adjust the header search path for Bash | |
571 | ;; 4.4 in accordance with 'bash.pc'. | |
572 | (("AM_CPPFLAGS = (.*)$" _ rest) | |
573 | (string-append "AM_CPPFLAGS = " | |
574 | "-I$(BASH_HEADERS)/include " | |
575 | rest)) | |
576 | ||
577 | ;; Install to PREFIX/lib/bash to match Bash | |
578 | ;; 4.4's search path. | |
579 | (("^libdir = .*$") | |
580 | "libdir = @libdir@/bash\n")) | |
581 | #t))))) | |
5f96f303 | 582 | |
b8fc3622 | 583 | (native-inputs `(("emacs" ,emacs-minimal) |
7ae7ca0e | 584 | ("bc" ,bc) |
b747a9db | 585 | ("bash:include" ,bash "include") |
b3546174 | 586 | ("libuuid" ,util-linux))) |
5f96f303 LC |
587 | |
588 | ;; TODO: Add more optional inputs. | |
5f96f303 LC |
589 | (inputs `(("curl" ,curl) |
590 | ("libgcrypt" ,libgcrypt) | |
591 | ("check" ,check))) | |
592 | (synopsis "Manipulate plain text files as databases") | |
593 | (description | |
594 | "GNU Recutils is a set of tools and libraries for creating and | |
595 | manipulating text-based, human-editable databases. Despite being text-based, | |
596 | databases created with Recutils carry all of the expected features such as | |
c5779c93 LC |
597 | unique fields, primary keys, time stamps and more. Many different field |
598 | types are supported, as is encryption.") | |
ba8b9f8d | 599 | (license license:gpl3+) |
6fd52309 | 600 | (home-page "https://www.gnu.org/software/recutils/"))) |
5f96f303 | 601 | |
d3c6ad0a MB |
602 | (define-public rocksdb |
603 | (package | |
604 | (name "rocksdb") | |
2e93ee5f | 605 | (version "5.2.1") |
d3c6ad0a MB |
606 | (source (origin |
607 | (method url-fetch) | |
608 | (uri (string-append "https://github.com/facebook/rocksdb" | |
609 | "/archive/v" version ".tar.gz")) | |
610 | (file-name (string-append name "-" version ".tar.gz")) | |
611 | (sha256 | |
612 | (base32 | |
2e93ee5f | 613 | "1v2q05bl56sfp51m09z7g6489hkfq4vf6b4qgfg3d96ylgmay9yb")) |
d3c6ad0a MB |
614 | (modules '((guix build utils))) |
615 | (snippet | |
616 | '(begin | |
617 | ;; TODO: unbundle gtest. | |
618 | (delete-file "build_tools/gnu_parallel") | |
619 | #t)))) | |
620 | (build-system gnu-build-system) | |
621 | (arguments | |
d7b344c5 | 622 | `(#:make-flags (list "CC=gcc" |
d3c6ad0a MB |
623 | (string-append "INSTALL_PATH=" |
624 | (assoc-ref %outputs "out"))) | |
d7b344c5 MB |
625 | ;; Many tests fail on 32-bit platforms. There are multiple reports about |
626 | ;; this upstream, but it's not going to be supported any time soon. | |
627 | #:tests? (let ((system ,(or (%current-target-system) | |
628 | (%current-system)))) | |
629 | (or (string-prefix? "x86_64-linux" system) | |
630 | (string-prefix? "aarch64-linux" system))) | |
d3c6ad0a MB |
631 | #:phases |
632 | (modify-phases %standard-phases | |
633 | (add-after 'unpack 'patch-Makefile | |
634 | (lambda _ | |
635 | (substitute* "Makefile" | |
636 | (("build_tools/gnu_parallel") "parallel") | |
f91c677c MB |
637 | ;; Don't depend on the static library when installing. |
638 | (("install: install-static") | |
639 | "install: install-shared") | |
d3c6ad0a MB |
640 | (("#!/bin/sh") (string-append "#!" (which "sh")))) |
641 | #t)) | |
642 | (delete 'configure) | |
d7b344c5 MB |
643 | ;; The default target is only needed for tests and built on demand. |
644 | (delete 'build) | |
645 | (add-before 'check 'disable-optimizations | |
646 | (lambda _ | |
647 | ;; Prevent the build from passing '-march=native' to the compiler. | |
648 | (setenv "PORTABLE" "1") | |
649 | #t)) | |
d3c6ad0a MB |
650 | (add-before 'check 'disable-failing-tests |
651 | (lambda _ | |
652 | (substitute* "Makefile" | |
bf144793 MB |
653 | ;; This test fails with GCC-5 and is unmaintained. |
654 | ;; https://github.com/facebook/rocksdb/issues/2148 | |
655 | (("^[[:blank:]]+spatial_db_test[[:blank:]]+\\\\") "\\") | |
d3c6ad0a MB |
656 | ;; These tests reliably fail due to "Too many open files". |
657 | (("^[[:blank:]]+env_test[[:blank:]]+\\\\") "\\") | |
658 | (("^[[:blank:]]+persistent_cache_test[[:blank:]]+\\\\") "\\")) | |
659 | #t)) | |
f91c677c MB |
660 | (add-after 'check 'build-release-libraries |
661 | ;; The default build target is a debug build for tests. The | |
662 | ;; install target depends on "shared_lib" and "static_lib" | |
663 | ;; targets for release builds so we build them here for clarity. | |
664 | ;; TODO: Add debug output. | |
665 | (lambda* (#:key (make-flags '()) #:allow-other-keys) | |
f91c677c | 666 | (zero? (apply system* "make" "shared_lib" make-flags))))))) |
d3c6ad0a MB |
667 | (native-inputs |
668 | `(("parallel" ,parallel) | |
669 | ("perl" ,perl) | |
670 | ("procps" ,procps) | |
77e52190 MB |
671 | ("python" ,python-2) |
672 | ("which" ,which))) | |
d3c6ad0a MB |
673 | (inputs |
674 | `(("bzip2" ,bzip2) | |
675 | ("gflags" ,gflags) | |
676 | ("jemalloc" ,jemalloc) | |
677 | ("lz4" ,lz4) | |
678 | ("snappy" ,snappy) | |
679 | ("zlib" ,zlib))) | |
680 | (home-page "http://rocksdb.org/") | |
681 | (synopsis "Persistent key-value store for fast storage") | |
682 | (description | |
683 | "RocksDB is a library that forms the core building block for a fast | |
684 | key-value server, especially suited for storing data on flash drives. It | |
685 | has a @dfn{Log-Structured-Merge-Database} (LSM) design with flexible tradeoffs | |
686 | between @dfn{Write-Amplification-Factor} (WAF), @dfn{Read-Amplification-Factor} | |
687 | (RAF) and @dfn{Space-Amplification-Factor} (SAF). It has multi-threaded | |
688 | compactions, making it specially suitable for storing multiple terabytes of | |
689 | data in a single database. RocksDB is partially based on @code{LevelDB}.") | |
690 | ;; RocksDB is BSD-3 and the JNI adapter is Apache 2.0. | |
ba8b9f8d | 691 | (license (list license:bsd-3 license:asl2.0)))) |
d3c6ad0a | 692 | |
b92d02d9 RJ |
693 | (define-public sparql-query |
694 | (package | |
695 | (name "sparql-query") | |
696 | (version "1.1") | |
697 | (source (origin | |
698 | (method url-fetch) | |
699 | (uri (string-append "https://github.com/tialaramex/" | |
700 | name "/archive/" version ".tar.gz")) | |
701 | (sha256 | |
702 | (base32 "0yq3k20472rv8npcc420q9ab6idy584g5y0q501d360k5q0ggr8w")) | |
703 | (file-name (string-append name "-" version ".tar.gz")))) | |
704 | (build-system gnu-build-system) | |
705 | (inputs | |
706 | `(("readline" ,readline) | |
707 | ("ncurses" ,ncurses) | |
708 | ("glib" ,glib) | |
709 | ("libxml2" ,libxml2) | |
710 | ("curl" ,curl))) | |
711 | (native-inputs | |
712 | `(("pkg-config" ,pkg-config))) | |
713 | (arguments | |
714 | `(#:make-flags '("CC=gcc") | |
715 | #:phases | |
716 | (modify-phases %standard-phases | |
717 | (delete 'configure) | |
718 | ;; The Makefile uses git to obtain versioning information. This phase | |
719 | ;; substitutes the git invocation with the package version. | |
720 | (add-after 'unpack 'remove-git-dependency | |
721 | (lambda _ | |
722 | (substitute* "Makefile" | |
723 | (("^gitrev :=.*$") | |
724 | (string-append "gitrev = \"v" ,version "\""))))) | |
725 | ;; The install phase of the Makefile assumes $PREFIX/usr/local/bin. | |
726 | ;; This replacement does the same thing, except for using $PREFIX/bin | |
727 | ;; instead. | |
728 | (replace 'install | |
729 | (lambda* (#:key outputs #:allow-other-keys) | |
730 | (let* ((out (assoc-ref outputs "out")) | |
731 | (bin (string-append out "/bin"))) | |
732 | (install-file "sparql-query" bin) | |
733 | (system* "ln" "--symbolic" | |
734 | (string-append bin "/sparql-query") | |
735 | (string-append bin "/sparql-update"))))) | |
736 | (replace 'check | |
737 | (lambda* (#:key make-flags #:allow-other-keys) | |
738 | (and | |
739 | (zero? (apply system* "make" `(,@make-flags "scan-test"))) | |
740 | (zero? (system "./scan-test")))))))) | |
741 | (home-page "https://github.com/tialaramex/sparql-query/") | |
742 | (synopsis "Command-line tool for accessing SPARQL endpoints over HTTP") | |
743 | (description "Sparql-query is a command-line tool for accessing SPARQL | |
744 | endpoints over HTTP. It has been intentionally designed to 'feel' similar to | |
745 | tools for interrogating SQL databases. For example, you can enter a query over | |
746 | several lines, using a semi-colon at the end of a line to indicate the end of | |
747 | your query. It also supports readline so that you can more easily recall and | |
748 | edit previous queries, even across sessions. It can be used non-interactively, | |
749 | for example from a shell script.") | |
750 | ;; Some files (like scan-sparql.c) contain a GPLv3+ license header, while | |
751 | ;; others (like sparql-query.c) contain a GPLv2+ license header. | |
ba8b9f8d | 752 | (license (list license:gpl3+)))) |
b92d02d9 | 753 | |
5f96f303 LC |
754 | (define-public sqlite |
755 | (package | |
756 | (name "sqlite") | |
70eea6ea | 757 | (version "3.19.3") |
5f96f303 LC |
758 | (source (origin |
759 | (method url-fetch) | |
5f96f303 LC |
760 | (uri (let ((numeric-version |
761 | (match (string-split version #\.) | |
762 | ((first-digit other-digits ...) | |
763 | (string-append first-digit | |
764 | (string-pad-right | |
765 | (string-concatenate | |
766 | (map (cut string-pad <> 2 #\0) | |
767 | other-digits)) | |
768 | 6 #\0)))))) | |
e58db46b | 769 | (string-append "https://sqlite.org/2017/sqlite-autoconf-" |
3ad8cb41 | 770 | numeric-version ".tar.gz"))) |
5f96f303 LC |
771 | (sha256 |
772 | (base32 | |
70eea6ea | 773 | "00b3l2qglpl1inx21fckiwxnfq5xf6441flc79rqg7zdvh1rq4h6")))) |
5f96f303 | 774 | (build-system gnu-build-system) |
8f1d22b7 | 775 | (inputs `(("readline" ,readline))) |
49689377 MW |
776 | (arguments |
777 | `(#:configure-flags | |
73dc727e DC |
778 | ;; Add -DSQLITE_SECURE_DELETE, -DSQLITE_ENABLE_UNLOCK_NOTIFY and |
779 | ;; -DSQLITE_ENABLE_DBSTAT_VTAB to CFLAGS. GNU Icecat will refuse | |
780 | ;; to use the system SQLite unless these options are enabled. | |
781 | (list (string-append "CFLAGS=-O2 -DSQLITE_SECURE_DELETE " | |
782 | "-DSQLITE_ENABLE_UNLOCK_NOTIFY " | |
783 | "-DSQLITE_ENABLE_DBSTAT_VTAB")))) | |
3ad8cb41 | 784 | (home-page "https://www.sqlite.org/") |
5f96f303 LC |
785 | (synopsis "The SQLite database management system") |
786 | (description | |
787 | "SQLite is a software library that implements a self-contained, serverless, | |
35b9e423 EB |
788 | zero-configuration, transactional SQL database engine. SQLite is the most |
789 | widely deployed SQL database engine in the world. The source code for SQLite | |
790 | is in the public domain.") | |
ba8b9f8d | 791 | (license license:public-domain))) |
db60b1d9 LC |
792 | |
793 | (define-public tdb | |
794 | (package | |
795 | (name "tdb") | |
38bb9df1 | 796 | (version "1.3.14") |
db60b1d9 LC |
797 | (source (origin |
798 | (method url-fetch) | |
ca473fc2 | 799 | (uri (string-append "https://www.samba.org/ftp/tdb/tdb-" |
db60b1d9 LC |
800 | version ".tar.gz")) |
801 | (sha256 | |
802 | (base32 | |
38bb9df1 | 803 | "1sfbia8xyaywgx9zy7x618vrvyx9gc3cgqf763shsii9javlnz9s")))) |
db60b1d9 LC |
804 | (build-system gnu-build-system) |
805 | (arguments | |
6ccb7814 EF |
806 | '(#:phases |
807 | (modify-phases %standard-phases | |
808 | (replace 'configure | |
809 | (lambda* (#:key outputs #:allow-other-keys) | |
810 | (let ((out (assoc-ref outputs "out"))) | |
811 | ;; The 'configure' script is a wrapper for Waf and | |
812 | ;; doesn't recognize things like '--enable-fast-install'. | |
813 | (zero? (system* "./configure" | |
814 | (string-append "--prefix=" out))))))))) | |
db60b1d9 LC |
815 | (native-inputs |
816 | `(;; TODO: Build the documentation. | |
817 | ;; ("docbook-xsl" ,docbook-xsl) | |
818 | ;; ("libxml2" ,libxml2) | |
819 | ;; ("libxslt" ,libxslt) | |
820 | ("python" ,python-2))) ;for the Waf build system | |
1abd0904 | 821 | (home-page "https://tdb.samba.org/") |
35b9e423 | 822 | (synopsis "Trivial database") |
db60b1d9 LC |
823 | (description |
824 | "TDB is a Trivial Database. In concept, it is very much like GDBM, | |
825 | and BSD's DB except that it allows multiple simultaneous writers and uses | |
826 | locking internally to keep writers from trampling on each other. TDB is also | |
827 | extremely small.") | |
ba8b9f8d | 828 | (license license:lgpl3+))) |
274da61d LC |
829 | |
830 | (define-public perl-dbi | |
831 | (package | |
832 | (name "perl-dbi") | |
6138dede | 833 | (version "1.636") |
274da61d LC |
834 | (source (origin |
835 | (method url-fetch) | |
836 | (uri (string-append | |
837 | "mirror://cpan/authors/id/T/TI/TIMB/DBI-" | |
838 | version ".tar.gz")) | |
839 | (sha256 | |
840 | (base32 | |
6138dede | 841 | "0v37vnr5p0bx396cj0lb5kb69jbryq2mspp602hbgd04gklxqzcg")))) |
274da61d LC |
842 | (build-system perl-build-system) |
843 | (synopsis "Database independent interface for Perl") | |
844 | (description "This package provides an database interface for Perl.") | |
6138dede | 845 | (home-page "http://search.cpan.org/dist/DBI") |
2f3108ad | 846 | (license license:perl-license))) |
274da61d | 847 | |
feae3395 EB |
848 | (define-public perl-dbix-class |
849 | (package | |
850 | (name "perl-dbix-class") | |
5d78d746 | 851 | (version "0.082840") |
feae3395 EB |
852 | (source |
853 | (origin | |
854 | (method url-fetch) | |
855 | (uri (string-append "mirror://cpan/authors/id/R/RI/RIBASUSHI/" | |
856 | "DBIx-Class-" version ".tar.gz")) | |
857 | (sha256 | |
858 | (base32 | |
5d78d746 | 859 | "1vw1f756g8m5hq11nqf5dk2cw2y4mqq91ca5p75fn5g3fp8syja0")))) |
feae3395 EB |
860 | (build-system perl-build-system) |
861 | (native-inputs | |
862 | `(("perl-dbd-sqlite" ,perl-dbd-sqlite) | |
863 | ("perl-file-temp" ,perl-file-temp) | |
2f837cf7 | 864 | ("perl-module-install" ,perl-module-install) |
feae3395 EB |
865 | ("perl-package-stash" ,perl-package-stash) |
866 | ("perl-test-deep" ,perl-test-deep) | |
867 | ("perl-test-exception" ,perl-test-exception) | |
868 | ("perl-test-warn" ,perl-test-warn))) | |
869 | (propagated-inputs | |
870 | `(("perl-class-accessor-grouped" ,perl-class-accessor-grouped) | |
871 | ("perl-class-c3-componentised" ,perl-class-c3-componentised) | |
872 | ("perl-class-inspector" ,perl-class-inspector) | |
873 | ("perl-config-any" ,perl-config-any) | |
874 | ("perl-context-preserve" ,perl-context-preserve) | |
875 | ("perl-data-dumper-concise" ,perl-data-dumper-concise) | |
876 | ("perl-data-page" ,perl-data-page) | |
877 | ("perl-dbi" ,perl-dbi) | |
878 | ("perl-devel-globaldestruction" ,perl-devel-globaldestruction) | |
879 | ("perl-hash-merge" ,perl-hash-merge) | |
880 | ("perl-module-find" ,perl-module-find) | |
881 | ("perl-moo" ,perl-moo) | |
882 | ("perl-mro-compat" ,perl-mro-compat) | |
883 | ("perl-namespace-clean" ,perl-namespace-clean) | |
884 | ("perl-path-class" ,perl-path-class) | |
885 | ("perl-scalar-list-utils" ,perl-scalar-list-utils) | |
886 | ("perl-scope-guard" ,perl-scope-guard) | |
887 | ("perl-sql-abstract" ,perl-sql-abstract) | |
888 | ("perl-sub-name" ,perl-sub-name) | |
889 | ("perl-text-balanced" ,perl-text-balanced) | |
890 | ("perl-try-tiny" ,perl-try-tiny))) | |
891 | (home-page "http://search.cpan.org/dist/DBIx-Class") | |
892 | (synopsis "Extensible and flexible object <-> relational mapper") | |
893 | (description "An SQL to OO mapper with an object API inspired by | |
894 | Class::DBI (with a compatibility layer as a springboard for porting) and a | |
895 | resultset API that allows abstract encapsulation of database operations. It | |
896 | aims to make representing queries in your code as perl-ish as possible while | |
897 | still providing access to as many of the capabilities of the database as | |
898 | possible, including retrieving related records from multiple tables in a | |
899 | single query, \"JOIN\", \"LEFT JOIN\", \"COUNT\", \"DISTINCT\", \"GROUP BY\", | |
900 | \"ORDER BY\" and \"HAVING\" support.") | |
2f3108ad | 901 | (license license:perl-license))) |
e61fd0f0 | 902 | |
4e4039e5 EB |
903 | (define-public perl-dbix-class-cursor-cached |
904 | (package | |
905 | (name "perl-dbix-class-cursor-cached") | |
180cb81b | 906 | (version "1.001004") |
4e4039e5 EB |
907 | (source |
908 | (origin | |
909 | (method url-fetch) | |
910 | (uri (string-append "mirror://cpan/authors/id/A/AR/ARCANEZ/" | |
911 | "DBIx-Class-Cursor-Cached-" version ".tar.gz")) | |
912 | (sha256 | |
913 | (base32 | |
180cb81b | 914 | "09b2jahn2x12qm4f7qm1jzsxbz7qn1czp6a3fnl5l2i3l4r5421p")))) |
4e4039e5 EB |
915 | (build-system perl-build-system) |
916 | (native-inputs | |
917 | `(("perl-cache-cache" ,perl-cache-cache) | |
2f837cf7 MB |
918 | ("perl-dbd-sqlite" ,perl-dbd-sqlite) |
919 | ("perl-module-install" ,perl-module-install))) | |
4e4039e5 EB |
920 | (propagated-inputs |
921 | `(("perl-carp-clan" ,perl-carp-clan) | |
922 | ("perl-dbix-class" ,perl-dbix-class))) | |
923 | (home-page "http://search.cpan.org/dist/DBIx-Class-Cursor-Cached") | |
924 | (synopsis "Cursor with built-in caching support") | |
925 | (description "DBIx::Class::Cursor::Cached provides a cursor class with | |
926 | built-in caching support.") | |
2f3108ad | 927 | (license license:perl-license))) |
4e4039e5 | 928 | |
e61fd0f0 EB |
929 | (define-public perl-dbix-class-introspectablem2m |
930 | (package | |
931 | (name "perl-dbix-class-introspectablem2m") | |
7a462b80 | 932 | (version "0.001002") |
e61fd0f0 EB |
933 | (source |
934 | (origin | |
935 | (method url-fetch) | |
68a9d6df | 936 | (uri (string-append "mirror://cpan/authors/id/I/IL/ILMARI/" |
e61fd0f0 EB |
937 | "DBIx-Class-IntrospectableM2M-" version ".tar.gz")) |
938 | (sha256 | |
939 | (base32 | |
7a462b80 | 940 | "1w47rh2241iy5x3a9bqsyd5kdp9sk43dksr99frzv4qn4jsazfn6")))) |
e61fd0f0 | 941 | (build-system perl-build-system) |
2f837cf7 MB |
942 | (native-inputs |
943 | `(("perl-module-install" ,perl-module-install))) | |
e61fd0f0 EB |
944 | (propagated-inputs |
945 | `(("perl-dbix-class" ,perl-dbix-class))) | |
946 | (home-page "http://search.cpan.org/dist/DBIx-Class-IntrospectableM2M") | |
947 | (synopsis "Introspect many-to-many relationships") | |
948 | (description "Because the many-to-many relationships are not real | |
949 | relationships, they can not be introspected with DBIx::Class. Many-to-many | |
950 | relationships are actually just a collection of convenience methods installed | |
951 | to bridge two relationships. This DBIx::Class component can be used to store | |
952 | all relevant information about these non-relationships so they can later be | |
953 | introspected and examined.") | |
2f3108ad | 954 | (license license:perl-license))) |
708155df EB |
955 | |
956 | (define-public perl-dbix-class-schema-loader | |
957 | (package | |
958 | (name "perl-dbix-class-schema-loader") | |
ebd2dbbf | 959 | (version "0.07046") |
708155df EB |
960 | (source |
961 | (origin | |
962 | (method url-fetch) | |
963 | (uri (string-append "mirror://cpan/authors/id/I/IL/ILMARI/" | |
964 | "DBIx-Class-Schema-Loader-" version ".tar.gz")) | |
965 | (sha256 | |
966 | (base32 | |
ebd2dbbf | 967 | "08cgn0dx42y9xsxas9np7s55a7qmy4kf6sfmx0jmk4hryvbapml3")))) |
708155df EB |
968 | (build-system perl-build-system) |
969 | (native-inputs | |
970 | `(("perl-config-any" ,perl-config-any) | |
971 | ("perl-config-general" ,perl-config-general) | |
972 | ("perl-dbd-sqlite" ,perl-dbd-sqlite) | |
973 | ("perl-dbix-class-introspectablem2m" ,perl-dbix-class-introspectablem2m) | |
2f837cf7 | 974 | ("perl-module-install" ,perl-module-install) |
708155df EB |
975 | ("perl-moose" ,perl-moose) |
976 | ("perl-moosex-markasmethods" ,perl-moosex-markasmethods) | |
977 | ("perl-moosex-nonmoose" ,perl-moosex-nonmoose) | |
978 | ("perl-namespace-autoclean" ,perl-namespace-autoclean) | |
979 | ("perl-test-deep" ,perl-test-deep) | |
980 | ("perl-test-differences" ,perl-test-differences) | |
981 | ("perl-test-exception" ,perl-test-exception) | |
982 | ("perl-test-pod" ,perl-test-pod) | |
983 | ("perl-test-warn" ,perl-test-warn))) | |
984 | (propagated-inputs | |
985 | `(("perl-class-unload" ,perl-class-unload) | |
986 | ("perl-class-inspector" ,perl-class-inspector) | |
987 | ("perl-class-accessor-grouped" ,perl-class-accessor-grouped) | |
988 | ("perl-class-c3-componentised" ,perl-class-c3-componentised) | |
989 | ("perl-carp-clan" ,perl-carp-clan) | |
990 | ("perl-data-dump" ,perl-data-dump) | |
991 | ("perl-dbix-class" ,perl-dbix-class) | |
992 | ("perl-hash-merge" ,perl-hash-merge) | |
993 | ("perl-list-moreutils" ,perl-list-moreutils) | |
994 | ("perl-lingua-en-inflect-phrase" ,perl-lingua-en-inflect-phrase) | |
995 | ("perl-lingua-en-inflect-number" ,perl-lingua-en-inflect-number) | |
996 | ("perl-lingua-en-tagger" ,perl-lingua-en-tagger) | |
997 | ("perl-namespace-clean" ,perl-namespace-clean) | |
998 | ("perl-mro-compat" ,perl-mro-compat) | |
999 | ("perl-scope-guard" ,perl-scope-guard) | |
1000 | ("perl-string-camelcase" ,perl-string-camelcase) | |
1001 | ("perl-string-toidentifier-en" ,perl-string-toidentifier-en) | |
1002 | ("perl-sub-name" ,perl-sub-name) | |
1003 | ("perl-try-tiny" ,perl-try-tiny))) | |
1004 | (arguments `(#:tests? #f)) ;TODO: t/20invocations.t fails | |
1005 | (home-page "http://search.cpan.org/dist/DBIx-Class-Schema-Loader") | |
1006 | (synopsis "Create a DBIx::Class::Schema based on a database") | |
1007 | (description "DBIx::Class::Schema::Loader automates the definition of a | |
1008 | DBIx::Class::Schema by scanning database table definitions and setting up the | |
1009 | columns, primary keys, unique constraints and relationships.") | |
2f3108ad | 1010 | (license license:perl-license))) |
274da61d | 1011 | |
186eb132 EB |
1012 | (define-public perl-dbd-pg |
1013 | (package | |
1014 | (name "perl-dbd-pg") | |
4d40c6aa | 1015 | (version "3.5.3") |
186eb132 EB |
1016 | (source |
1017 | (origin | |
1018 | (method url-fetch) | |
1019 | (uri (string-append "mirror://cpan/authors/id/T/TU/TURNSTEP/" | |
1020 | "DBD-Pg-" version ".tar.gz")) | |
1021 | (sha256 | |
1022 | (base32 | |
4d40c6aa | 1023 | "03m9w1cd0yyrbqwkwcl92j1cpmasmm69f3hwvcrlfsi5fnwsk63y")))) |
186eb132 EB |
1024 | (build-system perl-build-system) |
1025 | (native-inputs | |
1026 | `(("perl-dbi" ,perl-dbi))) | |
1027 | (propagated-inputs | |
1028 | `(("perl-dbi" ,perl-dbi) | |
1029 | ("postgresql" ,postgresql))) | |
1030 | (home-page "http://search.cpan.org/dist/DBD-Pg") | |
1031 | (synopsis "DBI PostgreSQL interface") | |
f33e71fc LC |
1032 | (description "This package provides a PostgreSQL driver for the Perl5 |
1033 | @dfn{Database Interface} (DBI).") | |
2f3108ad | 1034 | (license license:perl-license))) |
186eb132 | 1035 | |
4b7857a4 RW |
1036 | (define-public perl-dbd-mysql |
1037 | (package | |
1038 | (name "perl-dbd-mysql") | |
0ca1e77c | 1039 | (version "4.043") |
4b7857a4 RW |
1040 | (source |
1041 | (origin | |
1042 | (method url-fetch) | |
7c635ed6 | 1043 | (uri (string-append "mirror://cpan/authors/id/M/MI/MICHIELB/" |
4b7857a4 RW |
1044 | "DBD-mysql-" version ".tar.gz")) |
1045 | (sha256 | |
1046 | (base32 | |
c7db7b86 KK |
1047 | "16bg7l28n65ngi1abjxvwk906a80i2vd5vzjn812dx8phdg8d7v2")) |
1048 | (patches (search-patches "perl-dbd-mysql-CVE-2017-10788.patch")))) | |
4b7857a4 RW |
1049 | (build-system perl-build-system) |
1050 | ;; Tests require running MySQL server | |
1051 | (arguments `(#:tests? #f)) | |
1052 | (propagated-inputs | |
1053 | `(("perl-dbi" ,perl-dbi) | |
1054 | ("mysql" ,mysql))) | |
1055 | (home-page "http://search.cpan.org/dist/DBD-mysql") | |
1056 | (synopsis "DBI MySQL interface") | |
1057 | (description "This package provides a MySQL driver for the Perl5 | |
1058 | @dfn{Database Interface} (DBI).") | |
2f3108ad | 1059 | (license license:perl-license))) |
4b7857a4 | 1060 | |
274da61d LC |
1061 | (define-public perl-dbd-sqlite |
1062 | (package | |
1063 | (name "perl-dbd-sqlite") | |
2273b751 | 1064 | (version "1.54") |
274da61d LC |
1065 | (source (origin |
1066 | (method url-fetch) | |
1067 | (uri (string-append | |
1068 | "mirror://cpan/authors/id/I/IS/ISHIGAKI/DBD-SQLite-" | |
1069 | version ".tar.gz")) | |
1070 | (sha256 | |
1071 | (base32 | |
2273b751 | 1072 | "0sbj9lx9syzpknvjv8cz9jndg32qz775vy2prgq305npv3dsca9r")))) |
274da61d LC |
1073 | (build-system perl-build-system) |
1074 | (inputs `(("sqlite" ,sqlite))) | |
1075 | (propagated-inputs `(("perl-dbi" ,perl-dbi))) | |
1076 | (synopsis "SQlite interface for Perl") | |
1077 | (description "DBD::SQLite is a Perl DBI driver for SQLite, that includes | |
1078 | the entire thing in the distribution. So in order to get a fast transaction | |
1079 | capable RDBMS working for your Perl project you simply have to install this | |
1080 | module, and nothing else.") | |
2f3108ad | 1081 | (license license:perl-license) |
274da61d | 1082 | (home-page "http://search.cpan.org/~ishigaki/DBD-SQLite/lib/DBD/SQLite.pm"))) |
14e84b2d | 1083 | |
dd90952e EB |
1084 | (define-public perl-sql-abstract |
1085 | (package | |
1086 | (name "perl-sql-abstract") | |
1087 | (version "1.81") | |
1088 | (source | |
1089 | (origin | |
1090 | (method url-fetch) | |
1091 | (uri (string-append "mirror://cpan/authors/id/R/RI/RIBASUSHI/" | |
1092 | "SQL-Abstract-" version ".tar.gz")) | |
1093 | (sha256 | |
1094 | (base32 | |
1095 | "17sgwq3mvqjhv3b77cnvrq60xgp8harjhlnvpwmxc914rqc5ckaz")))) | |
1096 | (build-system perl-build-system) | |
1097 | (native-inputs | |
9dab5017 MB |
1098 | `(("perl-module-install" ,perl-module-install) |
1099 | ("perl-test-deep" ,perl-test-deep) | |
dd90952e EB |
1100 | ("perl-test-exception" ,perl-test-exception) |
1101 | ("perl-test-warn" ,perl-test-warn))) | |
1102 | (propagated-inputs | |
1103 | `(("perl-hash-merge" ,perl-hash-merge) | |
1104 | ("perl-moo" ,perl-moo) | |
1105 | ("perl-mro-compat" ,perl-mro-compat) | |
1106 | ("perl-text-balanced" ,perl-text-balanced))) | |
1107 | (home-page "http://search.cpan.org/dist/SQL-Abstract") | |
1108 | (synopsis "Generate SQL from Perl data structures") | |
1109 | (description "This module was inspired by the excellent DBIx::Abstract. | |
1110 | While based on the concepts used by DBIx::Abstract, the concepts used have | |
1111 | been modified to make the SQL easier to generate from Perl data structures. | |
1112 | The underlying idea is for this module to do what you mean, based on the data | |
1113 | structures you provide it, so that you don't have to modify your code every | |
e881752c | 1114 | time your data changes.") |
2f3108ad | 1115 | (license license:perl-license))) |
14e84b2d | 1116 | |
b4dcb026 EB |
1117 | (define-public perl-sql-splitstatement |
1118 | (package | |
1119 | (name "perl-sql-splitstatement") | |
1120 | (version "1.00020") | |
1121 | (source | |
1122 | (origin | |
1123 | (method url-fetch) | |
1124 | (uri (string-append "mirror://cpan/authors/id/E/EM/EMAZEP/" | |
1125 | "SQL-SplitStatement-" version ".tar.gz")) | |
1126 | (sha256 | |
1127 | (base32 | |
1128 | "0bqg45k4c9qkb2ypynlwhpvzsl4ssfagmsalys18s5c79ps30z7p")))) | |
1129 | (build-system perl-build-system) | |
1130 | (native-inputs | |
1131 | `(("perl-test-exception" ,perl-test-exception))) | |
1132 | (propagated-inputs | |
1133 | `(("perl-class-accessor" ,perl-class-accessor) | |
1134 | ("perl-list-moreutils" ,perl-list-moreutils) | |
1135 | ("perl-regexp-common" ,perl-regexp-common) | |
1136 | ("perl-sql-tokenizer" ,perl-sql-tokenizer))) | |
1137 | (home-page "http://search.cpan.org/dist/SQL-SplitStatement") | |
1138 | (synopsis "Split SQL code into atomic statements") | |
1139 | (description "This module tries to split any SQL code, even including | |
1140 | non-standard extensions, into the atomic statements it is composed of.") | |
2f3108ad | 1141 | (license license:perl-license))) |
b4dcb026 | 1142 | |
718c89c1 EB |
1143 | (define-public perl-sql-tokenizer |
1144 | (package | |
1145 | (name "perl-sql-tokenizer") | |
1146 | (version "0.24") | |
1147 | (source | |
1148 | (origin | |
1149 | (method url-fetch) | |
1150 | (uri (string-append "mirror://cpan/authors/id/I/IZ/IZUT/" | |
1151 | "SQL-Tokenizer-" version ".tar.gz")) | |
1152 | (sha256 | |
1153 | (base32 | |
1154 | "1qa2dfbzdlr5qqdam9yn78z5w3al5r8577x06qan8wv58ay6ka7s")))) | |
1155 | (build-system perl-build-system) | |
1156 | (home-page "http://search.cpan.org/dist/SQL-Tokenizer") | |
1157 | (synopsis "SQL tokenizer") | |
1158 | (description "SQL::Tokenizer is a tokenizer for SQL queries. It does not | |
1159 | claim to be a parser or query verifier. It just creates sane tokens from a | |
1160 | valid SQL query.") | |
2f3108ad | 1161 | (license license:perl-license))) |
718c89c1 | 1162 | |
14e84b2d JD |
1163 | (define-public unixodbc |
1164 | (package | |
1165 | (name "unixodbc") | |
3fef0a2f | 1166 | (version "2.3.4") |
14e84b2d JD |
1167 | (source (origin |
1168 | (method url-fetch) | |
e881752c | 1169 | (uri |
14e84b2d | 1170 | (string-append |
3fef0a2f EF |
1171 | "ftp://ftp.unixodbc.org/pub/unixODBC/unixODBC-" |
1172 | version ".tar.gz")) | |
14e84b2d | 1173 | (sha256 |
3fef0a2f | 1174 | (base32 "0f8y88rcc2akjvjv5y66yx7k0ms9h1s0vbcfy25j93didflhj59f")))) |
14e84b2d JD |
1175 | (build-system gnu-build-system) |
1176 | (synopsis "Data source abstraction library") | |
1177 | (description "Unixodbc is a library providing an API with which to access | |
1178 | data sources. Data sources include SQL Servers and any software with an ODBC | |
1179 | Driver.") | |
ba8b9f8d | 1180 | (license license:lgpl2.1+) |
14e84b2d JD |
1181 | ;; COPYING contains copy of lgpl2.1 - but copyright notices just say "LGPL" |
1182 | (home-page "http://www.unixodbc.org"))) | |
b4a9c924 EB |
1183 | |
1184 | (define-public unqlite | |
1185 | (package | |
1186 | (name "unqlite") | |
1187 | (version "1.1.6") | |
1188 | (source (origin | |
1189 | (method url-fetch) | |
1190 | ;; Contains bug fixes against the official release, and has an | |
1191 | ;; autotooled build system. | |
1192 | (uri (string-append "https://github.com/aidin36/tocc/releases/" | |
1193 | "download/v1.0.0/" | |
1194 | "unqlite-unofficial-" version ".tar.gz")) | |
1195 | (sha256 | |
1196 | (base32 | |
1197 | "1sbpvhg15gadq0mpcy16q7k3rkg4b4dicpnn5xifpkpn02sqik3s")))) | |
1198 | (build-system gnu-build-system) | |
1199 | (arguments `(#:tests? #f)) ;No check target | |
1200 | (home-page "http://www.unqlite.org") | |
1201 | (synopsis "In-memory key/value and document store") | |
1202 | (description | |
1203 | "UnQLite is an in-process software library which implements a | |
1204 | self-contained, serverless, zero-configuration, transactional NoSQL | |
1205 | database engine. UnQLite is a document store database similar to | |
1206 | MongoDB, Redis, CouchDB, etc. as well as a standard Key/Value store | |
69b4ffcf | 1207 | similar to BerkeleyDB, LevelDB, etc.") |
ba8b9f8d | 1208 | (license license:bsd-2))) |
463f6766 DT |
1209 | |
1210 | (define-public redis | |
1211 | (package | |
1212 | (name "redis") | |
f112bd26 | 1213 | (version "4.0.1") |
463f6766 DT |
1214 | (source (origin |
1215 | (method url-fetch) | |
1216 | (uri (string-append "http://download.redis.io/releases/redis-" | |
1217 | version".tar.gz")) | |
1218 | (sha256 | |
1219 | (base32 | |
f112bd26 | 1220 | "14bm8lkhylc93r4dgl7kkzzpw2xq7gr6w6h80n3jazqnx5mcsj90")))) |
463f6766 DT |
1221 | (build-system gnu-build-system) |
1222 | (arguments | |
1223 | '(#:tests? #f ; tests related to master/slave and replication fail | |
1224 | #:phases (modify-phases %standard-phases | |
1225 | (delete 'configure)) | |
1226 | #:make-flags `("CC=gcc" | |
1227 | "MALLOC=libc" | |
b25f060f | 1228 | "LDFLAGS=-ldl" |
463f6766 DT |
1229 | ,(string-append "PREFIX=" |
1230 | (assoc-ref %outputs "out"))))) | |
1231 | (synopsis "Key-value cache and store") | |
1232 | (description "Redis is an advanced key-value cache and store. Redis | |
1233 | supports many data structures including strings, hashes, lists, sets, sorted | |
1234 | sets, bitmaps and hyperloglogs.") | |
1235 | (home-page "http://redis.io/") | |
ba8b9f8d | 1236 | (license license:bsd-3))) |
a65e2a02 | 1237 | |
1238 | (define-public kyotocabinet | |
1239 | (package | |
1240 | (name "kyotocabinet") | |
1241 | (version "1.2.76") | |
1242 | (source (origin | |
1243 | (method url-fetch) | |
1244 | (uri (string-append "http://fallabs.com/kyotocabinet/pkg/" | |
1245 | name "-" version ".tar.gz")) | |
1246 | (sha256 | |
1247 | (base32 | |
1248 | "0g6js20x7vnpq4p8ghbw3mh9wpqksya9vwhzdx6dnlf354zjsal1")))) | |
1249 | (build-system gnu-build-system) | |
1250 | (arguments | |
1251 | `(#:configure-flags | |
1252 | (list | |
9d59023e | 1253 | "--disable-opt" ;"-march=native". XXX this also turns off -O0. |
a65e2a02 | 1254 | (string-append "LDFLAGS=-Wl,-rpath=" |
1255 | (assoc-ref %outputs "out") "/lib")))) | |
1256 | (inputs `(("zlib" ,zlib))) | |
1257 | (home-page "http://fallabs.com/kyotocabinet/") | |
1258 | (synopsis | |
1259 | "Kyoto Cabinet is a modern implementation of the DBM database") | |
1260 | (description | |
1261 | "Kyoto Cabinet is a standalone file-based database that supports Hash | |
1262 | and B+ Tree data storage models. It is a fast key-value lightweight | |
1263 | database and supports many programming languages. It is a NoSQL database.") | |
ba8b9f8d | 1264 | (license license:gpl3+))) |
6242b314 | 1265 | |
bdc11dc4 | 1266 | (define-public tokyocabinet |
1267 | (package | |
1268 | (name "tokyocabinet") | |
1269 | (version "1.4.48") | |
1270 | (source | |
1271 | (origin | |
1272 | (method url-fetch) | |
1273 | (uri (string-append "http://fallabs.com/tokyocabinet/" | |
1274 | name "-" version ".tar.gz")) | |
1275 | (sha256 | |
1276 | (base32 | |
1277 | "140zvr0n8kvsl0fbn2qn3f2kh3yynfwnizn4dgbj47m975yg80x0")))) | |
1278 | (build-system gnu-build-system) | |
1279 | (arguments | |
1280 | `(#:configure-flags | |
1281 | (list "--enable-pthread" "--enable-off64" "--enable-fastest" | |
1282 | (string-append "LDFLAGS=-Wl,-rpath=" | |
1283 | (assoc-ref %outputs "out") "/lib")))) | |
1284 | (inputs | |
1285 | `(("zlib" ,zlib))) | |
1286 | (home-page "http://fallabs.com/tokyocabinet/") | |
1287 | (synopsis "Tokyo Cabinet is a modern implementation of the DBM database") | |
1288 | (description | |
1289 | "Tokyo Cabinet is a library of routines for managing a database. | |
1290 | The database is a simple data file containing records, each is a pair of a | |
1291 | key and a value. Every key and value is serial bytes with variable length. | |
1292 | Both binary data and character string can be used as a key and a value. | |
1293 | There is neither concept of data tables nor data types. Records are | |
1294 | organized in hash table, B+ tree, or fixed-length array.") | |
1295 | (license license:lgpl2.1+))) | |
1296 | ||
6242b314 SB |
1297 | (define-public wiredtiger |
1298 | (package | |
1299 | (name "wiredtiger") | |
81e95821 | 1300 | (version "2.9.1") |
6242b314 SB |
1301 | (source (origin |
1302 | (method url-fetch) | |
1303 | (uri (string-append | |
1304 | "http://source.wiredtiger.com/releases/wiredtiger-" | |
1305 | version ".tar.bz2")) | |
1306 | (sha256 | |
1307 | (base32 | |
81e95821 | 1308 | "0krwnb2zfbhvjaskwl875qzd3y626s84zcciq2mxr5c5riw3yh6s")))) |
6242b314 SB |
1309 | (build-system gnu-build-system) |
1310 | (arguments | |
1311 | '(#:configure-flags '("--enable-lz4" "--enable-zlib") | |
1312 | #:phases | |
1313 | (modify-phases %standard-phases | |
1314 | (add-before 'check 'disable-test/fops | |
1315 | (lambda _ | |
1316 | ;; XXX: timed out after 3600 seconds of silence | |
1317 | (substitute* "Makefile" | |
1318 | (("test/fops") "")) | |
1319 | #t))))) | |
1320 | (inputs | |
1321 | `(("lz4" ,lz4) | |
1322 | ("zlib" ,zlib))) | |
1323 | (home-page "http://source.wiredtiger.com/") | |
1324 | (synopsis "NoSQL data engine") | |
1325 | (description | |
1326 | "WiredTiger is an extensible platform for data management. It supports | |
1327 | row-oriented storage (where all columns of a row are stored together), | |
1328 | column-oriented storage (where columns are stored in groups, allowing for | |
1329 | more efficient access and storage of column subsets) and log-structured merge | |
1330 | trees (LSM), for sustained throughput under random insert workloads.") | |
ba8b9f8d | 1331 | (license license:gpl3) ; or GPL-2 |
6242b314 | 1332 | ;; configure.ac: WiredTiger requires a 64-bit build. |
092b7b3e | 1333 | (supported-systems '("x86_64-linux" "mips64el-linux" "aarch64-linux")))) |
90c2ee88 DM |
1334 | |
1335 | (define-public perl-db-file | |
1336 | (package | |
1337 | (name "perl-db-file") | |
dd0cfb37 | 1338 | (version "1.840") |
90c2ee88 DM |
1339 | (source |
1340 | (origin | |
1341 | (method url-fetch) | |
1342 | (uri (string-append | |
1343 | "mirror://cpan/authors/id/P/PM/PMQS/DB_File-" | |
1344 | version | |
1345 | ".tar.gz")) | |
1346 | (sha256 | |
1347 | (base32 | |
dd0cfb37 | 1348 | "1i5jz85z4hpx15lw6ix27pyvrf0ziyh4z33lii4d3wnhz83lg1mp")))) |
90c2ee88 DM |
1349 | (build-system perl-build-system) |
1350 | (inputs `(("bdb" ,bdb))) | |
1351 | (native-inputs `(("perl-test-pod" ,perl-test-pod))) | |
1352 | (arguments | |
1353 | `(#:phases (modify-phases %standard-phases | |
1354 | (add-before | |
1355 | 'configure 'modify-config.in | |
1356 | (lambda* (#:key inputs #:allow-other-keys) | |
1357 | (substitute* "config.in" | |
1358 | (("/usr/local/BerkeleyDB") (assoc-ref inputs "bdb"))) | |
1359 | #t))))) | |
1360 | (home-page "http://search.cpan.org/dist/DB_File") | |
1361 | (synopsis | |
1362 | "Perl5 access to Berkeley DB version 1.x") | |
1363 | (description | |
1364 | "The DB::File module provides Perl bindings to the Berkeley DB version 1.x.") | |
2f3108ad | 1365 | (license license:perl-license))) |
0e1b262e DC |
1366 | |
1367 | (define-public lmdb | |
1368 | (package | |
1369 | (name "lmdb") | |
603fd6b9 | 1370 | (version "0.9.21") |
0e1b262e DC |
1371 | (source (origin |
1372 | (method url-fetch) | |
1373 | (uri (string-append "https://github.com/LMDB/lmdb/archive/" | |
1374 | "LMDB_" version ".tar.gz")) | |
1375 | (sha256 | |
1376 | (base32 | |
603fd6b9 | 1377 | "0ndmj07hkm2ic60z1f4rdscxs7pq45hk9fibjyv5nhfclhsvd1qi")))) |
0e1b262e DC |
1378 | (build-system gnu-build-system) |
1379 | (arguments | |
1380 | `(#:test-target "test" | |
1381 | #:phases | |
1382 | (modify-phases %standard-phases | |
1383 | (replace 'configure | |
1384 | (lambda* (#:key outputs #:allow-other-keys) | |
1385 | (chdir (string-append | |
1386 | (getenv "PWD") "/lmdb-LMDB_" ,version "/libraries/liblmdb")) | |
1387 | (substitute* "Makefile" | |
1388 | (("/usr/local") (assoc-ref outputs "out"))) | |
1389 | #t))))) | |
1390 | (home-page "https://symas.com/products/lightning-memory-mapped-database") | |
fda852ff TGR |
1391 | (synopsis "Lightning Memory-Mapped Database library") |
1392 | (description | |
1393 | "The @dfn{Lightning Memory-Mapped Database} (LMDB) is a high-performance | |
1394 | transactional database. Unlike more complex relational databases, LMDB handles | |
1395 | only key-value pairs (stored as arbitrary byte arrays) and relies on the | |
1396 | underlying operating system for caching and locking, keeping the code small and | |
1397 | simple. | |
1398 | The use of ‘zero-copy’ memory-mapped files combines the persistence of classic | |
1399 | disk-based databases with high read performance that scales linearly over | |
1400 | multiple cores. The size of each database is limited only by the size of the | |
1401 | virtual address space — not physical RAM.") | |
0e1b262e | 1402 | (license license:openldap2.8))) |
fe71eee0 JN |
1403 | |
1404 | (define-public libpqxx | |
1405 | (package | |
1406 | (name "libpqxx") | |
1407 | (version "4.0.1") | |
1408 | (source (origin | |
1409 | (method url-fetch) | |
1410 | (uri (string-append | |
1411 | "http://pqxx.org/download/software/libpqxx/" | |
1412 | name "-" version ".tar.gz")) | |
1413 | (sha256 | |
1414 | (base32 | |
1415 | "0f6wxspp6rx12fkasanb0z2g2gc8dhcfwnxagx8wwqbpg6ifsz09")))) | |
1416 | (build-system gnu-build-system) | |
1417 | (native-inputs | |
1418 | `(("python" ,python-2))) | |
1419 | (inputs `(("postgresql" ,postgresql))) | |
1420 | (arguments | |
5ac097e2 MB |
1421 | `(#:tests? #f ; # FAIL: 1 |
1422 | #:phases | |
1423 | (modify-phases %standard-phases | |
1424 | (add-before 'configure 'fix-sed-command | |
1425 | (lambda _ | |
1426 | ;; Newer sed versions error out if double brackets are not used. | |
1427 | (substitute* "configure" | |
1428 | (("\\[:space:\\]") "[[:space:]]")) | |
1429 | #t))))) | |
fe71eee0 JN |
1430 | (synopsis "C++ connector for PostgreSQL") |
1431 | (description | |
1432 | "Libpqxx is a C++ library to enable user programs to communicate with the | |
1433 | PostgreSQL database back-end. The database back-end can be local or it may be | |
1434 | on another machine, accessed via TCP/IP.") | |
1435 | (home-page "http://pqxx.org/") | |
1436 | (license license:bsd-3))) | |
4d98bfaf EF |
1437 | |
1438 | (define-public python-peewee | |
1439 | (package | |
1440 | (name "python-peewee") | |
1441 | (version "2.8.3") | |
1442 | (source | |
1443 | (origin | |
1444 | (method url-fetch) | |
1445 | (uri (pypi-uri "peewee" version)) | |
1446 | (sha256 | |
1447 | (base32 | |
1448 | "1605bk11s7aap2q4qyba93rx7yfh8b11kk0cqi08z8klx2iar8yd")))) | |
1449 | (build-system python-build-system) | |
1450 | (arguments | |
1451 | `(#:tests? #f)) ; Fails to import test data | |
1452 | (native-inputs | |
1453 | `(("python-cython" ,python-cython))) | |
1454 | (home-page "https://github.com/coleifer/peewee/") | |
1455 | (synopsis "Small object-relational mapping utility") | |
1456 | (description | |
1457 | "Peewee is a simple and small ORM (object-relation mapping) tool. Peewee | |
1458 | handles converting between pythonic values and those used by databases, so you | |
1459 | can use Python types in your code without having to worry. It has built-in | |
1460 | support for sqlite, mysql and postgresql. If you already have a database, you | |
1461 | can autogenerate peewee models using @code{pwiz}, a model generator.") | |
1462 | (license license:expat))) | |
1463 | ||
1464 | (define-public python2-peewee | |
1465 | (package-with-python2 python-peewee)) | |
62ea44fc AP |
1466 | |
1467 | (define-public sqlcipher | |
1468 | (package | |
1469 | (name "sqlcipher") | |
1470 | (version "3.3.1") | |
1471 | (source | |
1472 | (origin | |
1473 | (method url-fetch) | |
1474 | (uri (string-append "https://github.com/sqlcipher/" name | |
1475 | "/archive/v" version ".tar.gz")) | |
1476 | (sha256 | |
1477 | (base32 "1gv58dlbpzrmznly52yqbxgvii0ib88zr3aszla1bsypwjr6flff")) | |
1478 | (file-name (string-append name "-" version ".tar.gz")))) | |
1479 | (build-system gnu-build-system) | |
1480 | (inputs | |
1481 | `(("libcrypto" ,openssl) | |
1482 | ("libtcl8.6" ,tcl))) ; required for running the tests | |
1483 | (native-inputs | |
1484 | `(("tcl" ,tcl))) | |
1485 | (arguments | |
1486 | '(#:configure-flags | |
1487 | '("--enable-tempstore=yes" | |
1488 | "CFLAGS=-DSQLITE_HAS_CODEC -DSQLITE_ENABLE_FTS3" | |
1489 | "LDFLAGS=-lcrypto -ltcl8.6" | |
1490 | "--disable-tcl") | |
1491 | ;; tests cannot be run from the Makefile | |
1492 | ;; see: <https://github.com/sqlcipher/sqlcipher/issues/172> | |
1493 | #:test-target "testfixture" | |
1494 | #:phases | |
1495 | (modify-phases %standard-phases | |
1496 | (add-before 'check 'build-test-runner | |
1497 | (assoc-ref %standard-phases 'check)) | |
1498 | (replace 'check | |
1499 | (lambda _ | |
1500 | (zero? | |
1501 | (system* "./testfixture" "test/crypto.test"))))))) | |
1502 | (home-page "https://www.zetetic.net/sqlcipher/") | |
1503 | (synopsis | |
1504 | "Library providing transparent encryption of SQLite database files") | |
1505 | (description "SQLCipher is an implementation of SQLite, extended to | |
1506 | provide transparent 256-bit AES encryption of database files. Pages are | |
1507 | encrypted before being written to disk and are decrypted when read back. It’s | |
1508 | well suited for protecting embedded application databases and for mobile | |
1509 | development.") | |
1510 | ;; The source files | |
1511 | ;; src/{crypto.c,crypto_impl.c,crypto.h,crypto_cc.c,crypto_libtomcrypt.c}, | |
1512 | ;; src/{crypto_openssl.c,sqlcipher.h}, tool/crypto-speedtest.tcl, | |
1513 | ;; test/crypto.test are licensed under a 3-clause BSD license. All other | |
1514 | ;; source files are in the public domain. | |
1515 | (license (list license:public-domain license:bsd-3)))) | |
98d403bb DM |
1516 | |
1517 | (define-public python-pyodbc-c | |
1518 | (package | |
1519 | (name "python-pyodbc-c") | |
c6b6a74e | 1520 | (version "3.1.4") |
98d403bb DM |
1521 | (source |
1522 | (origin | |
1523 | (method url-fetch) | |
1524 | (uri (string-append "https://gitlab.com/daym/pyodbc-c/repository/" | |
1525 | "archive.tar.gz?ref=v" version)) | |
1526 | (sha256 | |
1527 | (base32 | |
c6b6a74e | 1528 | "05aq2297k779xidmxcwkrrxjvj1bh2q7d9a1rcjv6zr15y764ga9")) |
98d403bb DM |
1529 | (file-name (string-append name "-" version ".tar.gz")))) |
1530 | (build-system python-build-system) | |
1531 | (inputs | |
1532 | `(("unixodbc" ,unixodbc))) | |
1533 | (arguments | |
1534 | `(;; No unit tests exist. | |
1535 | #:tests? #f)) | |
1536 | (home-page "https://github.com/mkleehammer/pyodbc") | |
1537 | (synopsis "Python ODBC Library") | |
1538 | (description "@code{python-pyodbc-c} provides a Python DB-API driver | |
1539 | for ODBC.") | |
1540 | (license (license:x11-style "file://LICENSE.TXT")))) | |
1541 | ||
1542 | (define-public python2-pyodbc-c | |
1543 | (package-with-python2 python-pyodbc-c)) | |
d39a84e8 AI |
1544 | |
1545 | (define-public mdbtools | |
1546 | (package | |
1547 | (name "mdbtools") | |
1548 | (version "0.7.1") | |
1549 | (source | |
1550 | (origin | |
1551 | (method url-fetch) | |
1552 | (uri (string-append "https://github.com/brianb/mdbtools/archive/" | |
1553 | version ".tar.gz")) | |
1554 | (sha256 | |
1555 | (base32 | |
1556 | "05hbmxcq173kzb899gdi3bz2qcc1vi3n1qbbkwpsvrq7ggf11wyw")) | |
1557 | (file-name (string-append name "-" version ".tar.gz")))) | |
1558 | (build-system gnu-build-system) | |
1559 | (inputs | |
1560 | `(("glib" ,glib))) | |
1561 | (native-inputs | |
1562 | `(("autoconf" ,autoconf) | |
1563 | ("automake" ,automake) | |
1564 | ("libtool" ,libtool) | |
1565 | ("pkg-config" ,pkg-config) | |
1566 | ("txt2man" ,txt2man) | |
1567 | ("which" ,which))) | |
1568 | (arguments | |
1569 | `(#:phases | |
1570 | (modify-phases %standard-phases | |
1571 | (add-before 'configure 'autoreconf | |
1572 | (lambda _ | |
1573 | (zero? (system* "autoreconf" "-vfi"))))))) | |
1574 | (home-page "http://mdbtools.sourceforge.net/") | |
1575 | (synopsis "Read Microsoft Access databases") | |
1576 | (description "MDB Tools is a set of tools and applications to read the | |
1577 | proprietary MDB file format used in Microsoft's Access database package. This | |
1578 | includes programs to export schema and data from Microsoft's Access database | |
1579 | file format to other databases such as MySQL, Oracle, Sybase, PostgreSQL, | |
1580 | etc., and an SQL engine for performing simple SQL queries.") | |
1581 | (license (list license:lgpl2.0 | |
1582 | license:gpl2+)))) | |
07041d95 TGR |
1583 | |
1584 | (define-public python-lmdb | |
1585 | (package | |
1586 | (name "python-lmdb") | |
1587 | (version "0.92") | |
1588 | (source (origin | |
1589 | (method url-fetch) | |
1590 | (uri (pypi-uri "lmdb" version)) | |
1591 | (sha256 | |
1592 | (base32 | |
1593 | "01nw6r08jkipx6v92kw49z34wmwikrpvc5j9xawdiyg1n2526wrx")) | |
1594 | (modules '((guix build utils))) | |
1595 | (snippet | |
1596 | ;; Delete bundled lmdb source files. | |
1597 | '(for-each delete-file (list "lib/lmdb.h" | |
1598 | "lib/mdb.c" | |
1599 | "lib/midl.c" | |
1600 | "lib/midl.h"))))) | |
1601 | (build-system python-build-system) | |
1602 | (inputs | |
1603 | `(("lmdb" ,lmdb))) | |
1604 | (arguments | |
1605 | `(#:phases | |
1606 | (modify-phases %standard-phases | |
1607 | (add-before 'build 'use-system-lmdb | |
1608 | (lambda* (#:key inputs #:allow-other-keys) | |
1609 | (let ((lmdb (assoc-ref inputs "lmdb"))) | |
1610 | (setenv "LMDB_FORCE_SYSTEM" "set") | |
1611 | (setenv "LMDB_INCLUDEDIR" (string-append lmdb "/include")) | |
1612 | (setenv "LMDB_LIBDIR" (string-append lmdb "/lib")) | |
1613 | #t)))) | |
1614 | ;; Tests fail with: ‘lmdb.tool: Please specify environment (--env)’. | |
1615 | #:tests? #f)) | |
1616 | (home-page "https://github.com/dw/py-lmdb") | |
1617 | (synopsis "Python binding for the ‘Lightning’ database (LMDB)") | |
1618 | (description | |
1619 | "python-lmdb or py-lmdb is a Python binding for the @dfn{Lightning | |
1620 | Memory-Mapped Database} (LMDB), a high-performance key-value store.") | |
1621 | (license | |
1622 | (list license:openldap2.8 | |
1623 | ;; ‘lib/win32/inttypes.h’ and ‘lib/win32-stdint/stdint.h’ are BSD-3, | |
1624 | ;; but not actually needed on platforms currently supported by Guix. | |
1625 | license:bsd-3)))) | |
1626 | ||
1627 | (define-public python2-lmdb | |
1628 | (package-with-python2 python-lmdb)) |