gnu: dune-configurator: Add synopsis and description.
[jackhill/guix/guix.git] / gnu / packages / ocaml.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
3 ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
4 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
5 ;;; Copyright © 2015 David Hashe <david.hashe@dhashe.com>
6 ;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
7 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
8 ;;; Copyright © 2016, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
9 ;;; Copyright © 2016-2020 Julien Lepiller <julien@lepiller.eu>
10 ;;; Copyright © 2017 Ben Woodcroft <donttrustben@gmail.com>
11 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
12 ;;; Copyright © 2018 Peter Kreye <kreyepr@gmail.com>
13 ;;; Copyright © 2018, 2019 Gabriel Hondet <gabrielhondet@gmail.com>
14 ;;; Copyright © 2018 Kei Kebreau <kkebreau@posteo.net>
15 ;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net>
16 ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org>
17 ;;; Copyright © 2020 Marius Bakke <marius@gnu.org>
18 ;;; Copyright © 2020 Simon Tournier <zimon.toutoune@gmail.com>
19 ;;;
20 ;;; This file is part of GNU Guix.
21 ;;;
22 ;;; GNU Guix is free software; you can redistribute it and/or modify it
23 ;;; under the terms of the GNU General Public License as published by
24 ;;; the Free Software Foundation; either version 3 of the License, or (at
25 ;;; your option) any later version.
26 ;;;
27 ;;; GNU Guix is distributed in the hope that it will be useful, but
28 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
29 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30 ;;; GNU General Public License for more details.
31 ;;;
32 ;;; You should have received a copy of the GNU General Public License
33 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
34
35 (define-module (gnu packages ocaml)
36 #:use-module (gnu packages)
37 #:use-module (gnu packages algebra)
38 #:use-module (gnu packages autotools)
39 #:use-module (gnu packages base)
40 #:use-module (gnu packages bison)
41 #:use-module (gnu packages boost)
42 #:use-module (gnu packages compression)
43 #:use-module (gnu packages curl)
44 #:use-module (gnu packages emacs)
45 #:use-module (gnu packages emacs-xyz)
46 #:use-module (gnu packages flex)
47 #:use-module (gnu packages gcc)
48 #:use-module (gnu packages ghostscript)
49 #:use-module (gnu packages glib)
50 #:use-module (gnu packages gnome)
51 #:use-module (gnu packages gtk)
52 #:use-module (gnu packages libevent)
53 #:use-module (gnu packages libffi)
54 #:use-module (gnu packages llvm)
55 #:use-module (gnu packages m4)
56 #:use-module (gnu packages maths)
57 #:use-module (gnu packages multiprecision)
58 #:use-module (gnu packages ncurses)
59 #:use-module (gnu packages pcre)
60 #:use-module (gnu packages perl)
61 #:use-module (gnu packages pkg-config)
62 #:use-module (gnu packages protobuf)
63 #:use-module (gnu packages python)
64 #:use-module (gnu packages python-xyz)
65 #:use-module (gnu packages rsync)
66 #:use-module (gnu packages sdl)
67 #:use-module (gnu packages sqlite)
68 #:use-module (gnu packages tex)
69 #:use-module (gnu packages texinfo)
70 #:use-module (gnu packages time)
71 #:use-module (gnu packages tls)
72 #:use-module (gnu packages virtualization)
73 #:use-module (gnu packages web-browsers)
74 #:use-module (gnu packages xml)
75 #:use-module (gnu packages xorg)
76 #:use-module (guix build-system dune)
77 #:use-module (guix build-system emacs)
78 #:use-module (guix build-system gnu)
79 #:use-module (guix build-system ocaml)
80 #:use-module (guix download)
81 #:use-module (guix git-download)
82 #:use-module ((guix licenses) #:prefix license:)
83 #:use-module (guix packages)
84 #:use-module (guix svn-download)
85 #:use-module (guix utils)
86 #:use-module ((srfi srfi-1) #:hide (zip)))
87
88 ;; A shortcut for files from ocaml forge. Downloaded files are computed from
89 ;; their number, not their name.
90 (define (ocaml-forge-uri name version file-number)
91 (string-append "https://forge.ocamlcore.org/frs/download.php/"
92 (number->string file-number) "/" name "-" version
93 ".tar.gz"))
94
95 ;; Janestreet packages are found in a similar way and all need the same patch.
96 (define (janestreet-origin name version hash)
97 (origin (method url-fetch)
98 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/"
99 (version-major+minor version) "/files/"
100 name "-" version ".tar.gz"))
101 (sha256 (base32 hash))
102 (modules '((guix build utils)))
103 (snippet
104 (let ((pattern (string-append "lib/" name)))
105 `(begin
106 ;; install.ml contains an invalid reference to the ppx file and
107 ;; propagates this error to the generated META file. It
108 ;; looks for it in the "lib" directory, but it is installed in
109 ;; "lib/ocaml/site-lib/package". This substitute does not change
110 ;; this file for non ppx packages.
111 (substitute* "install.ml"
112 ((,pattern) (string-append "lib/ocaml/site-lib/" ,name)))
113 ;; The standard Makefile would try to install janestreet modules
114 ;; in OCaml's directory in the store, which is read-only.
115 (substitute* "Makefile"
116 (("--prefix")
117 "--libdir $(LIBDIR) --prefix"))
118 #t)))))
119
120 ;; They also require almost the same set of arguments
121 (define janestreet-arguments
122 `(#:use-make? #t
123 #:make-flags
124 (list (string-append "CONFIGUREFLAGS=--prefix "
125 (assoc-ref %outputs "out")
126 " --enable-tests")
127 (string-append "LIBDIR="
128 (assoc-ref %outputs "out")
129 "/lib/ocaml/site-lib")
130 ;; for ocaml-bin-prot, otherwise ignored
131 (string-append "OCAML_TOPLEVEL_PATH="
132 (assoc-ref %build-inputs "findlib")
133 "/lib/ocaml/site-lib"))
134 #:phases (modify-phases %standard-phases (delete 'configure))))
135
136 (define-public ocaml-4.09
137 (package
138 (name "ocaml")
139 (version "4.09.0")
140 (source (origin
141 (method url-fetch)
142 (uri (string-append
143 "http://caml.inria.fr/pub/distrib/ocaml-"
144 (version-major+minor version)
145 "/ocaml-" version ".tar.xz"))
146 (sha256
147 (base32
148 "1v3z5ar326f3hzvpfljg4xj8b9lmbrl53fn57yih1bkbx3gr3yzj"))))
149 (build-system gnu-build-system)
150 (native-search-paths
151 (list (search-path-specification
152 (variable "OCAMLPATH")
153 (files (list "lib/ocaml" "lib/ocaml/site-lib")))
154 (search-path-specification
155 (variable "CAML_LD_LIBRARY_PATH")
156 (files (list "lib/ocaml/site-lib/stubslibs"
157 "lib/ocaml/site-lib/stublibs")))))
158 (native-inputs
159 `(("perl" ,perl)
160 ("pkg-config" ,pkg-config)))
161 (inputs
162 `(("libx11" ,libx11)
163 ;; For libiberty, needed for objdump support.
164 ("gcc:lib" ,(canonical-package gcc) "lib")
165 ("zlib" ,zlib))) ;also needed for objdump support
166 (arguments
167 `(#:phases
168 (modify-phases %standard-phases
169 (add-after 'unpack 'patch-/bin/sh-references
170 (lambda* (#:key inputs #:allow-other-keys)
171 (let* ((sh (string-append (assoc-ref inputs "bash")
172 "/bin/sh"))
173 (quoted-sh (string-append "\"" sh "\"")))
174 (with-fluids ((%default-port-encoding #f))
175 (for-each
176 (lambda (file)
177 (substitute* file
178 (("\"/bin/sh\"")
179 (begin
180 (format (current-error-port) "\
181 patch-/bin/sh-references: ~a: changing `\"/bin/sh\"' to `~a'~%"
182 file quoted-sh)
183 quoted-sh))))
184 (find-files "." "\\.ml$"))
185 #t))))
186 (replace 'build
187 (lambda _
188 (invoke "make" "-j" (number->string (parallel-job-count))
189 "world.opt")))
190 (replace 'check
191 (lambda _
192 (with-directory-excursion "testsuite"
193 (invoke "make" "all")))))))
194 (home-page "https://ocaml.org/")
195 (synopsis "The OCaml programming language")
196 (description
197 "OCaml is a general purpose industrial-strength programming language with
198 an emphasis on expressiveness and safety. Developed for more than 20 years at
199 Inria it benefits from one of the most advanced type systems and supports
200 functional, imperative and object-oriented styles of programming.")
201 ;; The compiler is distributed under qpl1.0 with a change to choice of
202 ;; law: the license is governed by the laws of France. The library is
203 ;; distributed under lgpl2.0.
204 (license (list license:qpl license:lgpl2.0))))
205
206 (define-public ocaml-4.07
207 (package
208 (inherit ocaml-4.09)
209 (version "4.07.1")
210 (source (origin
211 (method url-fetch)
212 (uri (string-append
213 "http://caml.inria.fr/pub/distrib/ocaml-"
214 (version-major+minor version)
215 "/ocaml-" version ".tar.xz"))
216 (sha256
217 (base32
218 "1f07hgj5k45cylj1q3k5mk8yi02cwzx849b1fwnwia8xlcfqpr6z"))))
219 (arguments
220 (substitute-keyword-arguments (package-arguments ocaml-4.09)
221 ((#:phases phases)
222 `(modify-phases ,phases
223 (replace 'configure
224 (lambda* (#:key outputs #:allow-other-keys)
225 (let* ((out (assoc-ref outputs "out"))
226 (mandir (string-append out "/share/man")))
227 ;; Custom configure script doesn't recognize
228 ;; --prefix=<PREFIX> syntax (with equals sign).
229 (invoke "./configure"
230 "--prefix" out
231 "--mandir" mandir))))))))))
232
233 (define-public ocaml ocaml-4.09)
234
235 (define-public ocamlbuild
236 (package
237 (name "ocamlbuild")
238 (version "0.14.0")
239 (source
240 (origin
241 (method git-fetch)
242 (uri (git-reference
243 (url "https://github.com/ocaml/ocamlbuild")
244 (commit version)))
245 (file-name (git-file-name name version))
246 (sha256
247 (base32 "1hb5mcdz4wv7sh1pj7dq9q4fgz5h3zg7frpiya6s8zd3ypwzq0kh"))))
248 (build-system ocaml-build-system)
249 (arguments
250 `(#:make-flags
251 (list (string-append "OCAMLBUILD_PREFIX=" (assoc-ref %outputs "out"))
252 (string-append "OCAMLBUILD_BINDIR=" (assoc-ref %outputs "out")
253 "/bin")
254 (string-append "OCAMLBUILD_LIBDIR=" (assoc-ref %outputs "out")
255 "/lib/ocaml/site-lib")
256 (string-append "OCAMLBUILD_MANDIR=" (assoc-ref %outputs "out")
257 "/share/man"))
258 #:phases
259 (modify-phases %standard-phases
260 (delete 'configure))
261 ; some failures because of changes in OCaml's error message formating
262 #:tests? #f))
263 (home-page "https://github.com/ocaml/ocamlbuild")
264 (synopsis "OCaml build tool")
265 (description "OCamlbuild is a generic build tool, that has built-in rules
266 for building OCaml library and programs.")
267 (license license:lgpl2.1+)))
268
269 (define-public ocaml-extlib
270 (package
271 (name "ocaml-extlib")
272 (version "1.7.7")
273 (source (origin
274 (method url-fetch)
275 (uri (string-append "https://ygrek.org/p/release/ocaml-extlib/"
276 "extlib-" version ".tar.gz"))
277 (sha256
278 (base32
279 "1sxmzc1mx3kg62j8kbk0dxkx8mkf1rn70h542cjzrziflznap0s1"))))
280 (build-system ocaml-build-system)
281 (arguments
282 `(#:phases
283 (modify-phases %standard-phases
284 (delete 'configure))))
285 (native-inputs
286 `(("ocaml-cppo" ,ocaml-cppo)))
287 (home-page "https://github.com/ygrek/ocaml-extlib")
288 (synopsis "Complete and small extension for OCaml standard library")
289 (description "This library adds new functions to OCaml standard library
290 modules, modifies some functions in order to get better performances or
291 safety (tail-recursive) and also provides new modules which should be useful
292 for day to day programming.")
293 ;; With static-linking exception
294 (license license:lgpl2.1+)))
295
296 (define-public ocaml-cudf
297 (package
298 (name "ocaml-cudf")
299 (version "0.9")
300 (source
301 (origin
302 (method url-fetch)
303 (uri "https://gforge.inria.fr/frs/download.php/36602/cudf-0.9.tar.gz")
304 (sha256
305 (base32
306 "0771lwljqwwn3cryl0plny5a5dyyrj4z6bw66ha5n8yfbpcy8clr"))))
307 (build-system ocaml-build-system)
308 (propagated-inputs `(("ocaml-extlib" ,ocaml-extlib)))
309 (native-inputs
310 `(("perl" ,perl)
311 ("ocamlbuild" ,ocamlbuild)
312 ("ocaml-ounit" ,ocaml-ounit)))
313 (arguments
314 `(#:make-flags
315 (list
316 "all" "opt"
317 (string-append "BINDIR=" (assoc-ref %outputs "out")
318 "/bin"))
319 #:phases
320 (modify-phases %standard-phases
321 (delete 'configure))))
322 (home-page "http://www.mancoosi.org/cudf/")
323 (synopsis "CUDF library (part of the Mancoosi tools)")
324 (description "CUDF (for Common Upgradeability Description Format) is a
325 format for describing upgrade scenarios in package-based Free and Open Source
326 Software distribution.")
327 ;; With static-linking exception
328 (license license:lgpl2.1+)))
329
330 (define-public ocaml-mccs
331 (package
332 (name "ocaml-mccs")
333 (version "1.1+11")
334 (source (origin
335 (method git-fetch)
336 (uri (git-reference
337 (url "https://github.com/AltGr/ocaml-mccs")
338 (commit version)))
339 (file-name (git-file-name name version))
340 (sha256
341 (base32
342 "1gsad5cj03256i36wdjqk5pg51pyd48rpjazf0gfaakrn8lk438g"))))
343 (build-system dune-build-system)
344 (propagated-inputs `(("ocaml-cudf" ,ocaml-cudf)))
345 (home-page "https://www.i3s.unice.fr/~cpjm/misc/")
346 (synopsis "Upgrade path problem solver")
347 (description "Mccs (Multi Criteria CUDF Solver) is a CUDF problem solver.
348 Mccs take as input a CUDF problem and computes the best solution according to
349 a set of criteria. It relies on a Integer Programming solver or a
350 Pseudo Boolean solver to achieve its task. Mccs can use a wide set of
351 underlying solvers like Cplex, Gurobi, Lpsolver, Glpk, CbC, SCIP or WBO.")
352 (license (list
353 license:bsd-3
354 license:gpl3+
355 ;; With static-linking exception
356 license:lgpl2.1+))))
357
358 (define-public ocaml-dose3
359 (package
360 (name "ocaml-dose3")
361 (version "5.0.1")
362 (source (origin
363 (method url-fetch)
364 (uri "https://gforge.inria.fr/frs/download.php/file/36063/dose3-5.0.1.tar.gz")
365 (sha256
366 (base32
367 "00yvyfm4j423zqndvgc1ycnmiffaa2l9ab40cyg23pf51qmzk2jm"))
368 (patches
369 (search-patches
370 "ocaml-dose3-add-unix-dependency.patch"
371 "ocaml-dose3-Fix-for-ocaml-4.06.patch"
372 "ocaml-dose3-dont-make-printconf.patch"
373 "ocaml-dose3-Install-mli-cmx-etc.patch"))))
374 (build-system ocaml-build-system)
375 (arguments
376 `(#:configure-flags
377 (list (string-append "SHELL="
378 (assoc-ref %build-inputs "bash")
379 "/bin/sh"))
380 #:make-flags
381 (list (string-append "LIBDIR="
382 (assoc-ref %outputs "out")
383 "/lib/ocaml/site-lib"))))
384 (propagated-inputs
385 `(("ocaml-graph" ,ocaml-graph)
386 ("ocaml-cudf" ,ocaml-cudf)
387 ("ocaml-extlib" ,ocaml-extlib)
388 ("ocaml-re" ,ocaml-re)))
389 (native-inputs
390 `(("perl" ,perl)
391 ("python" ,python-2) ; for a test script
392 ("python2-pyyaml" ,python2-pyyaml) ; for a test script
393 ("ocaml-extlib" ,ocaml-extlib)
394 ("ocamlbuild" ,ocamlbuild)
395 ("ocaml-cppo" ,ocaml-cppo)))
396 (home-page "http://www.mancoosi.org/software/")
397 (synopsis "Package distribution management framework")
398 (description "Dose3 is a framework made of several OCaml libraries for
399 managing distribution packages and their dependencies. Though not tied to
400 any particular distribution, dose3 constitutes a pool of libraries which
401 enable analyzing packages coming from various distributions. Besides basic
402 functionalities for querying and setting package properties, dose3 also
403 implements algorithms for solving more complex problems such as monitoring
404 package evolutions, correct and complete dependency resolution and
405 repository-wide uninstallability checks.")
406 ;; with static-linking exception
407 (license license:lgpl2.1+)))
408
409 (define-public ocaml-opam-file-format
410 (package
411 (name "ocaml-opam-file-format")
412 (version "2.0.0")
413 (source (origin
414 (method git-fetch)
415 (uri (git-reference
416 (url "https://github.com/ocaml/opam-file-format")
417 (commit version)))
418 (file-name (git-file-name name version))
419 (sha256
420 (base32
421 "0fqb99asnair0043hhc8r158d6krv5nzvymd0xwycr5y72yrp0hv"))))
422 (build-system ocaml-build-system)
423 (arguments
424 `(#:tests? #f; No tests
425 #:make-flags (list (string-append "LIBDIR=" (assoc-ref %outputs "out")
426 "/lib/ocaml/site-lib"))
427 #:phases
428 (modify-phases %standard-phases
429 (delete 'configure))))
430 (home-page "https://opam.ocaml.org")
431 (synopsis "Parser and printer for the opam file syntax")
432 (description "This package contains a parser and a pretty-printer for
433 the opam file format.")
434 ;; With static-linking exception
435 (license license:lgpl2.1+)))
436
437 (define-public opam
438 (package
439 (name "opam")
440 (version "2.0.7")
441 (source (origin
442 (method git-fetch)
443 (uri (git-reference
444 (url "https://github.com/ocaml/opam")
445 (commit version)))
446 (file-name (git-file-name name version))
447 (sha256
448 (base32
449 "1p719ccn9wnzk6impsnwr809yh507h8f37dx9nn64b1hsyb5z8ax"))))
450 (build-system ocaml-build-system)
451 (arguments
452 `(#:configure-flags
453 (list (string-append "SHELL="
454 (assoc-ref %build-inputs "bash")
455 "/bin/sh"))
456
457 ;; For some reason, 'ocp-build' needs $TERM to be set.
458 #:make-flags
459 (list "TERM=screen"
460 (string-append "SHELL="
461 (assoc-ref %build-inputs "bash")
462 "/bin/sh"))
463
464 #:test-target "tests"
465
466 #:phases (modify-phases %standard-phases
467 (add-before 'build 'pre-build
468 (lambda* (#:key inputs make-flags #:allow-other-keys)
469 (let ((bash (assoc-ref inputs "bash"))
470 (bwrap (string-append (assoc-ref inputs "bubblewrap")
471 "/bin/bwrap")))
472 (substitute* "src/core/opamSystem.ml"
473 (("\"/bin/sh\"")
474 (string-append "\"" bash "/bin/sh\""))
475 (("getconf")
476 (which "getconf")))
477 ;; Use bwrap from the store directly.
478 (substitute* "src/state/shellscripts/bwrap.sh"
479 (("-v bwrap") (string-append "-v " bwrap))
480 (("exec bwrap") (string-append "exec " bwrap))
481 ;; Mount /gnu and /run/current-system in the
482 ;; isolated environment when building with opam.
483 ;; This is necessary for packages to find external
484 ;; dependencies, such as a C compiler, make, etc...
485 (("^add_sys_mounts /usr")
486 "add_sys_mounts /gnu /run/current-system /usr"))
487 (substitute* "src/client/opamInitDefaults.ml"
488 (("\"bwrap\"") (string-append "\"" bwrap "\"")))
489 ;; Generating the documentation needs write access
490 (for-each
491 (lambda (f) (chmod f #o644))
492 (find-files "doc" "."))
493 #t)))
494 (add-before 'check 'pre-check
495 (lambda _
496 ;; The "repo" test attempts to open some of these files O_WRONLY
497 ;; and fails with a bogus "OpamSystem.File_not_found" otherwise.
498 (for-each
499 (lambda (f) (chmod f #o644))
500 (find-files "tests/packages" "\\.opam$"))
501
502 (substitute* "tests/Makefile"
503 (("/usr/bin/printf")
504 (which "printf"))
505 ;; By default tests run twice: once with a "local" repository
506 ;; and once with a git repository: disable the git tests to
507 ;; avoid the dependency.
508 (("all: local git")
509 "all: local"))
510 #t)))))
511 (native-inputs
512 `(("dune" ,dune)
513 ("ocaml-cppo" ,ocaml-cppo)
514
515 ;; For tests.
516 ("openssl" ,openssl)
517 ("python" ,python-wrapper)
518 ("rsync" ,rsync)
519 ("unzip" ,unzip)
520 ("which" ,which)))
521 (inputs
522 `(("ocaml" ,ocaml)
523 ("ncurses" ,ncurses)
524 ("curl" ,curl)
525 ("bubblewrap" ,bubblewrap)))
526 (propagated-inputs
527 `(("ocaml-cmdliner" ,ocaml-cmdliner)
528 ("ocaml-dose3" ,ocaml-dose3)
529 ("ocaml-mccs" ,ocaml-mccs)
530 ("ocaml-opam-file-format" ,ocaml-opam-file-format)
531 ("ocaml-re" ,ocaml-re)))
532 (home-page "http://opam.ocamlpro.com/")
533 (synopsis "Package manager for OCaml")
534 (description
535 "OPAM is a tool to manage OCaml packages. It supports multiple
536 simultaneous compiler installations, flexible package constraints, and a
537 Git-friendly development workflow.")
538
539 ;; The 'LICENSE' file waives some requirements compared to LGPLv3.
540 (license license:lgpl3)))
541
542 (define-public camlp5
543 (package
544 (name "camlp5")
545 (version "7.13")
546 (source
547 (origin
548 (method git-fetch)
549 (uri (git-reference
550 (url "https://github.com/camlp5/camlp5")
551 (commit (string-append "rel" (string-delete #\. version)))))
552 (file-name (git-file-name name version))
553 (sha256
554 (base32 "1d9spy3f5ahixm8nxxk086kpslzva669a5scn49am0s7vx4i71kp"))))
555 (build-system gnu-build-system)
556 (inputs
557 `(("ocaml" ,ocaml)))
558 (arguments
559 `(#:tests? #f ; XXX TODO figure out how to run the tests
560 #:phases
561 (modify-phases %standard-phases
562 (replace 'configure
563 (lambda* (#:key outputs #:allow-other-keys)
564 (let* ((out (assoc-ref outputs "out"))
565 (mandir (string-append out "/share/man")))
566 ;; Custom configure script doesn't recognize
567 ;; --prefix=<PREFIX> syntax (with equals sign).
568 (invoke "./configure"
569 "--prefix" out
570 "--mandir" mandir))))
571 (add-before 'build 'fix-/bin-references
572 (lambda _
573 (substitute* "config/Makefile"
574 (("/bin/rm") "rm"))
575 #t))
576 (replace 'build
577 (lambda _
578 (invoke "make" "-j" (number->string
579 (parallel-job-count))
580 "world.opt")))
581 ;; Required for findlib to find camlp5's libraries
582 (add-after 'install 'install-meta
583 (lambda* (#:key outputs #:allow-other-keys)
584 (install-file "etc/META" (string-append (assoc-ref outputs "out")
585 "/lib/ocaml/camlp5/"))
586 #t)))))
587 (home-page "https://camlp5.github.io/")
588 (synopsis "Pre-processor Pretty Printer for OCaml")
589 (description
590 "Camlp5 is a Pre-Processor-Pretty-Printer for Objective Caml. It offers
591 tools for syntax (Stream Parsers and Grammars) and the ability to modify the
592 concrete syntax of the language (Quotations, Syntax Extensions).")
593 ;; Most files are distributed under bsd-3, but ocaml_stuff/* is under qpl.
594 (license (list license:bsd-3 license:qpl))))
595
596 (define-public hevea
597 (package
598 (name "hevea")
599 (version "2.34")
600 (source (origin
601 (method url-fetch)
602 (uri (string-append "http://hevea.inria.fr/old/"
603 "hevea-" version ".tar.gz"))
604 (sha256
605 (base32
606 "1pzyszxw90klpcmhjqrjfc8cw6c0gm4w2blim8ydyxb6rq6qml1s"))))
607 (build-system gnu-build-system)
608 (inputs
609 `(("ocaml" ,ocaml)))
610 (native-inputs
611 `(("ocamlbuild" ,ocamlbuild)))
612 (arguments
613 `(#:tests? #f ; no test suite
614 #:make-flags (list (string-append "PREFIX=" %output))
615 #:phases (modify-phases %standard-phases
616 (delete 'configure)
617 (add-before 'build 'patch-/bin/sh
618 (lambda _
619 (substitute* "_tags"
620 (("/bin/sh") (which "sh")))
621 #t)))))
622 (home-page "http://hevea.inria.fr/")
623 (synopsis "LaTeX to HTML translator")
624 (description
625 "HeVeA is a LaTeX to HTML translator that generates modern HTML 5. It is
626 written in Objective Caml.")
627 (license license:qpl)))
628
629 (define-public ocaml-num
630 (package
631 (name "ocaml-num")
632 (version "1.1")
633 (source
634 (origin
635 (method git-fetch)
636 (uri (git-reference
637 (url "https://github.com/ocaml/num")
638 (commit (string-append "v" version))))
639 (file-name (git-file-name name version))
640 (sha256
641 (base32 "0a4mhxgs5hi81d227aygjx35696314swas0vzy3ig809jb7zq4h0"))))
642 (build-system ocaml-build-system)
643 (arguments
644 `(#:phases
645 (modify-phases %standard-phases
646 (delete 'configure)
647 (add-before 'build 'fix-makefile
648 (lambda* (#:key outputs #:allow-other-keys)
649 ;; This package supposes we install to the same directory as
650 ;; the ocaml package.
651 (substitute* "src/META"
652 (("\"\\^\"") (string-append "\"" (assoc-ref outputs "out")
653 "/lib/ocaml/site-lib\"")))
654 (substitute* "src/Makefile"
655 (("\\) \\$\\(STDLIBDIR\\)")
656 (string-append ") " (assoc-ref outputs "out")
657 "/lib/ocaml/site-lib")))
658 #t))
659 (add-after 'install 'fix-stubslib
660 (lambda* (#:key outputs #:allow-other-keys)
661 (format #t "~a~%" (find-files "." ".*.so"))
662 (let ((stubdir (string-append (assoc-ref outputs "out")
663 "/lib/ocaml/site-lib/stublibs")))
664 (delete-file stubdir)
665 (mkdir-p stubdir)
666 (install-file "src/dllnums.so" stubdir))
667 #t)))))
668 (home-page "https://github.com/ocaml/num")
669 (synopsis "Arbitrary-precision integer and rational arithmetic")
670 (description "OCaml-Num contains the legacy Num library for
671 arbitrary-precision integer and rational arithmetic that used to be part of
672 the OCaml core distribution.")
673 (license license:lgpl2.1+))); with linking exception
674
675 (define-public emacs-tuareg
676 ;; Last upstream release on Sept., 14th, 2018, since then "Package cl
677 ;; deprecated" or 'lexical-binding' and others had been fixed.
678 (let ((commit "ccde45bbc292123ec20617f1af7f7e19f7481545")
679 (revision "0"))
680 (package
681 (name "emacs-tuareg")
682 (version (git-version "2.2.0" revision commit))
683 (source
684 (origin
685 (method git-fetch)
686 (uri (git-reference
687 (url "https://github.com/ocaml/tuareg")
688 (commit commit)))
689 (file-name (git-file-name name version))
690 (sha256
691 (base32 "1yxv4bnqarilnpg5j7wywall8170hwvm0q4xx06yqjgcn8pq1lac"))))
692 (build-system gnu-build-system)
693 (native-inputs
694 `(("emacs" ,emacs-minimal)
695 ("opam" ,opam)))
696 (arguments
697 `(#:phases
698 (modify-phases %standard-phases
699 (add-after 'unpack 'make-git-checkout-writable
700 (lambda _
701 (for-each make-file-writable (find-files "."))
702 #t))
703 (delete 'configure)
704 (add-before 'install 'fix-install-path
705 (lambda* (#:key outputs #:allow-other-keys)
706 (substitute* "Makefile"
707 (("/emacs/site-lisp")
708 (string-append (assoc-ref %outputs "out")
709 "/share/emacs/site-lisp/")))
710 #t))
711 (add-after 'install 'post-install
712 (lambda* (#:key outputs #:allow-other-keys)
713 (symlink "tuareg.el"
714 (string-append (assoc-ref outputs "out")
715 "/share/emacs/site-lisp/"
716 "tuareg-autoloads.el"))
717 #t)))))
718 (home-page "https://github.com/ocaml/tuareg")
719 (synopsis "OCaml programming mode, REPL, debugger for Emacs")
720 (description "Tuareg helps editing OCaml code, to highlight important
721 parts of the code, to run an OCaml REPL, and to run the OCaml debugger within
722 Emacs.")
723 (license license:gpl2+))))
724
725 (define-public ocaml-menhir
726 (package
727 (name "ocaml-menhir")
728 ;; More recent versions can be built after we have dune >= 2.0
729 (version "20190626")
730 (source
731 (origin
732 (method git-fetch)
733 (uri (git-reference
734 (url "https://gitlab.inria.fr/fpottier/menhir.git")
735 (commit version)))
736 (file-name (git-file-name name version))
737 (sha256
738 (base32 "0v8av4pw6rykzb7wx54xhbsx0jhh8xyb4x0k4yrxi0w5ylkck6mb"))))
739 (build-system ocaml-build-system)
740 (inputs
741 `(("ocaml" ,ocaml)))
742 (native-inputs
743 `(("ocamlbuild" ,ocamlbuild)))
744 (arguments
745 `(#:make-flags `("USE_OCAMLFIND=true"
746 ,(string-append "PREFIX=" (assoc-ref %outputs "out")))
747 #:tests? #f ; No check target
748 #:phases
749 (modify-phases %standard-phases
750 (delete 'configure))))
751 (home-page "http://gallium.inria.fr/~fpottier/menhir/")
752 (synopsis "Parser generator")
753 (description "Menhir is a parser generator. It turns high-level grammar
754 specifications, decorated with semantic actions expressed in the OCaml
755 programming language into parsers, again expressed in OCaml. It is based on
756 Knuth’s LR(1) parser construction technique.")
757 ;; The file src/standard.mly and all files listed in src/mnehirLib.mlpack
758 ;; that have an *.ml or *.mli extension are GPL licensed. All other files
759 ;; are QPL licensed.
760 (license (list license:gpl2+ license:qpl))))
761
762 (define-public ocaml-bigarray-compat
763 (package
764 (name "ocaml-bigarray-compat")
765 (version "1.0.0")
766 (source (origin
767 (method git-fetch)
768 (uri (git-reference
769 (url "https://github.com/mirage/bigarray-compat")
770 (commit (string-append "v" version))))
771 (file-name (git-file-name name version))
772 (sha256
773 (base32
774 "06j1dwlpisxshdd0nab4n4x266gg1s1n8na16lpgw3fvcznwnimz"))))
775 (build-system dune-build-system)
776 (arguments
777 `(#:tests? #f)); no tests
778 (home-page "https://github.com/mirage/bigarray-compat")
779 (synopsis "OCaml compatibility library")
780 (description "This package contains a compatibility library for
781 @code{Stdlib.Bigarray} in OCaml.")
782 (license license:isc)))
783
784 (define-public lablgtk
785 (package
786 (name "lablgtk")
787 (version "2.18.10")
788 (source (origin
789 (method git-fetch)
790 (uri (git-reference
791 (url "https://github.com/garrigue/lablgtk")
792 (commit version)))
793 (file-name (git-file-name name version))
794 (sha256
795 (base32
796 "0w8cdfcv2wc19sd3qzj3qq77qc6rbnbynsz02gzbl15kgrvgrfxi"))))
797 (build-system gnu-build-system)
798 (native-inputs
799 `(("ocaml" ,ocaml)
800 ("findlib" ,ocaml-findlib)
801 ("pkg-config" ,pkg-config)))
802 ;; FIXME: Add inputs gtkgl-2.0, libpanelapplet-2.0, gtkspell-2.0,
803 ;; and gtk+-quartz-2.0 once available.
804 (inputs
805 `(("gtk+" ,gtk+-2)
806 ("gtksourceview" ,gtksourceview-2)
807 ("libgnomecanvas" ,libgnomecanvas)
808 ("libgnomeui" ,libgnomeui)
809 ("libglade" ,libglade)
810 ("librsvg" ,librsvg)))
811 (arguments
812 `(#:tests? #f ; no check target
813
814 ;; opt: also install cmxa files
815 #:make-flags (list "all" "opt"
816 (string-append "FINDLIBDIR="
817 (assoc-ref %outputs "out")
818 "/lib/ocaml"))
819 ;; Occasionally we would get "Error: Unbound module GtkThread" when
820 ;; compiling 'gtkThInit.ml', with 'make -j'. So build sequentially.
821 #:parallel-build? #f
822
823 #:phases
824 (modify-phases %standard-phases
825 (add-before 'install 'prepare-install
826 (lambda* (#:key inputs outputs #:allow-other-keys)
827 (let ((out (assoc-ref outputs "out"))
828 (ocaml (assoc-ref inputs "ocaml")))
829 ;; Install into the output and not the ocaml directory.
830 (mkdir-p (string-append out "/lib/ocaml"))
831 (substitute* "config.make"
832 ((ocaml) out))
833 #t))))))
834 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-lablgtk))))
835 (home-page "http://lablgtk.forge.ocamlcore.org/")
836 (synopsis "GTK+ bindings for OCaml")
837 (description
838 "LablGtk is an OCaml interface to GTK+ 1.2 and 2.x. It provides
839 a strongly-typed object-oriented interface that is compatible with the
840 dynamic typing of GTK+. Most widgets and methods are available. LablGtk
841 also provides bindings to
842 gdk-pixbuf, the GLArea widget (in combination with LablGL), gnomecanvas,
843 gnomeui, gtksourceview, gtkspell,
844 libglade (and it an generate OCaml code from .glade files),
845 libpanel, librsvg and quartz.")
846 (license license:lgpl2.1)))
847
848 (define-public ocaml4.07-lablgtk
849 (package
850 (inherit lablgtk)
851 (name "ocaml4.07-lablgtk")
852 (native-inputs
853 `(("ocaml" ,ocaml-4.07)
854 ("findlib" ,ocaml4.07-findlib)
855 ("pkg-config" ,pkg-config)))
856 (properties '())))
857
858 (define-public unison
859 (package
860 (name "unison")
861 (version "2.51.2")
862 (source (origin
863 (method git-fetch)
864 (uri (git-reference
865 (url "https://github.com/bcpierce00/unison")
866 (commit (string-append "v" version))))
867 (file-name (git-file-name name version))
868 (sha256
869 (base32
870 "1bykiyc0dc5pkw8x370qkg2kygq9pq7yqzsgczd3y13b6ivm4sdq"))
871 (patches (search-patches "unison-fix-ocaml-4.08.patch"))))
872 (build-system gnu-build-system)
873 (outputs '("out"
874 "doc")) ; 1.9 MiB of documentation
875 (native-inputs
876 `(("ocaml" ,ocaml-4.09)
877 ;; For documentation
878 ("ghostscript" ,ghostscript)
879 ("texlive" ,texlive-tiny)
880 ("hevea" ,hevea)
881 ("lynx" ,lynx)
882 ("which" ,which)))
883 (arguments
884 `(#:parallel-build? #f
885 #:parallel-tests? #f
886 #:test-target "selftest"
887 #:tests? #f ; Tests require writing to $HOME.
888 ; If some $HOME is provided, they fail with the message
889 ; "Fatal error: Skipping some tests -- remove me!"
890 #:phases
891 (modify-phases %standard-phases
892 (delete 'configure)
893 (add-before 'install 'prepare-install
894 (lambda* (#:key outputs #:allow-other-keys)
895 (let* ((out (assoc-ref outputs "out"))
896 (bin (string-append out "/bin")))
897 (mkdir-p bin)
898 (setenv "HOME" out) ; forces correct INSTALLDIR in Makefile
899 #t)))
900 (add-after 'install 'install-fsmonitor
901 (lambda* (#:key outputs #:allow-other-keys)
902 (let* ((out (assoc-ref outputs "out"))
903 (bin (string-append out "/bin")))
904 ;; 'unison-fsmonitor' is used in "unison -repeat watch" mode.
905 (install-file "src/unison-fsmonitor" bin)
906 #t)))
907 (add-after 'install 'install-doc
908 (lambda* (#:key outputs #:allow-other-keys)
909 (let ((doc (string-append (assoc-ref outputs "doc")
910 "/share/doc/unison")))
911 (mkdir-p doc)
912 ;; Remove an '\n' that prevents the doc to be generated
913 ;; correctly with newer hevea.
914 (substitute* "doc/local.tex"
915 (("----SNIP----.*") "----SNIP----"))
916 ;; This file needs write-permissions, because it's
917 ;; overwritten by 'docs' during documentation generation.
918 (chmod "src/strings.ml" #o600)
919 (invoke "make" "docs"
920 "TEXDIRECTIVES=\\\\draftfalse")
921 (for-each (lambda (f)
922 (install-file f doc))
923 (map (lambda (ext)
924 (string-append "doc/unison-manual." ext))
925 ;; Install only html documentation,
926 ;; since the build is currently
927 ;; non-reproducible with the ps, pdf,
928 ;; and dvi docs.
929 '(;; "ps" "pdf" "dvi"
930 "html")))
931 #t))))))
932 (home-page "https://www.cis.upenn.edu/~bcpierce/unison/")
933 (synopsis "File synchronizer")
934 (description
935 "Unison is a file-synchronization tool. It allows two replicas of
936 a collection of files and directories to be stored on different hosts
937 (or different disks on the same host), modified separately, and then
938 brought up to date by propagating the changes in each replica
939 to the other.")
940 (license license:gpl3+)))
941
942 (define-public ocaml-findlib
943 (package
944 (name "ocaml-findlib")
945 (version "1.8.1")
946 (source (origin
947 (method url-fetch)
948 (uri (string-append "http://download.camlcity.org/download/"
949 "findlib" "-" version ".tar.gz"))
950 (sha256
951 (base32
952 "00s3sfb02pnjmkax25pcnljcnhcggiliccfz69a72ic7gsjwz1cf"))))
953 (build-system gnu-build-system)
954 (native-inputs
955 `(("m4" ,m4)
956 ("ocaml" ,ocaml)))
957 (arguments
958 `(#:tests? #f ; no test suite
959 #:parallel-build? #f
960 #:make-flags (list "all" "opt")
961 #:phases (modify-phases %standard-phases
962 (replace
963 'configure
964 (lambda* (#:key inputs outputs #:allow-other-keys)
965 (let ((out (assoc-ref outputs "out")))
966 (invoke
967 "./configure"
968 "-bindir" (string-append out "/bin")
969 "-config" (string-append out "/etc/ocamfind.conf")
970 "-mandir" (string-append out "/share/man")
971 "-sitelib" (string-append out "/lib/ocaml/site-lib")
972 "-with-toolbox"))))
973 (replace 'install
974 (lambda* (#:key outputs #:allow-other-keys)
975 (let ((out (assoc-ref outputs "out")))
976 (invoke "make" "install"
977 (string-append "OCAML_CORE_STDLIB="
978 out "/lib/ocaml/site-lib"))))))))
979 (home-page "http://projects.camlcity.org/projects/findlib.html")
980 (synopsis "Management tool for OCaml libraries")
981 (description
982 "The \"findlib\" library provides a scheme to manage reusable software
983 components (packages), and includes tools that support this scheme. Packages
984 are collections of OCaml modules for which metainformation can be stored. The
985 packages are kept in the file system hierarchy, but with strict directory
986 structure. The library contains functions to look the directory up that
987 stores a package, to query metainformation about a package, and to retrieve
988 dependency information about multiple packages. There is also a tool that
989 allows the user to enter queries on the command-line. In order to simplify
990 compilation and linkage, there are new frontends of the various OCaml
991 compilers that can directly deal with packages.")
992 (license license:x11)))
993
994 (define-public ocaml4.07-findlib
995 (package
996 (inherit ocaml-findlib)
997 (name "ocaml4.07-findlib")
998 (native-inputs
999 `(("m4" ,m4)
1000 ("ocaml" ,ocaml-4.07)))))
1001
1002 ;; note that some tests may hang for no obvious reason.
1003 (define-public ocaml-ounit
1004 (package
1005 (name "ocaml-ounit")
1006 (version "2.0.8")
1007 (source (origin
1008 (method url-fetch)
1009 (uri (ocaml-forge-uri "ounit" version 1749))
1010 (sha256
1011 (base32
1012 "03ifp9hjcxg4m5j190iy373jcn4039d3vy10kmd8p4lfciwzwc1f"))))
1013 (build-system ocaml-build-system)
1014 (native-inputs
1015 `(("libxml2" ,libxml2) ; for xmllint
1016 ("ocamlbuild" ,ocamlbuild)))
1017 (arguments
1018 `(#:phases
1019 (modify-phases %standard-phases
1020 (delete 'check)))) ; tests are run during build
1021 (home-page "http://ounit.forge.ocamlcore.org")
1022 (synopsis "Unit testing framework for OCaml")
1023 (description "Unit testing framework for OCaml. It is similar to JUnit and
1024 other XUnit testing frameworks.")
1025 (license license:expat)))
1026
1027 (define-public camlzip
1028 (package
1029 (name "camlzip")
1030 (version "1.0.6")
1031 (source (origin
1032 (method url-fetch)
1033 (uri (ocaml-forge-uri name version 1616))
1034 (sha256
1035 (base32
1036 "0m6gyjw46w3qnhxfsyqyag42znl5lwargks7w7rfchr9jzwpff68"))))
1037 (build-system ocaml-build-system)
1038 (inputs
1039 `(("zlib" ,zlib)))
1040 (arguments
1041 `(#:phases
1042 (modify-phases %standard-phases
1043 (delete 'configure)
1044 (add-after 'install 'install-camlzip
1045 (lambda* (#:key outputs #:allow-other-keys)
1046 (let* ((out (assoc-ref outputs "out"))
1047 (dir (string-append out "/lib/ocaml/site-lib/camlzip")))
1048 (mkdir-p dir)
1049 (call-with-output-file (string-append dir "/META")
1050 (lambda (port)
1051 (format port "version=\"1.06\"\n")
1052 (format port "requires=\"unix\"\n")
1053 (format port "archive(byte)=\"zip.cma\"\n")
1054 (format port "archive(native)=\"zip.cmxa\"\n")
1055 (format port "archive(native,plugin)=\"zip.cmxs\"\n")
1056 (format port "directory=\"../zip\"\n")))))))
1057 #:install-target "install-findlib"
1058 #:make-flags
1059 (list "all" "allopt"
1060 (string-append "INSTALLDIR=" (assoc-ref %outputs "out")
1061 "/lib/ocaml"))))
1062 (home-page "https://github.com/xavierleroy/camlzip")
1063 (synopsis "Provides easy access to compressed files")
1064 (description "Provides easy access to compressed files in ZIP, GZIP and
1065 JAR format. It provides functions for reading from and writing to compressed
1066 files in these formats.")
1067 (license license:lgpl2.1+)))
1068
1069 (define-public ocamlmod
1070 (package
1071 (name "ocamlmod")
1072 (version "0.0.9")
1073 (source (origin
1074 (method url-fetch)
1075 (uri (ocaml-forge-uri name version 1702))
1076 (sha256
1077 (base32
1078 "0cgp9qqrq7ayyhddrmqmq1affvfqcn722qiakjq4dkywvp67h4aa"))))
1079 (build-system ocaml-build-system)
1080 (native-inputs
1081 `(("ounit" ,ocaml-ounit)
1082 ("ocamlbuild" ,ocamlbuild)))
1083 (arguments
1084 `(#:phases
1085 (modify-phases %standard-phases
1086 ;; Tests are done during build.
1087 (delete 'check))))
1088 (home-page "https://forge.ocamlcore.org/projects/ocamlmod")
1089 (synopsis "Generate modules from OCaml source files")
1090 (description "Generate modules from OCaml source files.")
1091 (license license:lgpl2.1+))) ; with an exception
1092
1093 (define-public ocaml-zarith
1094 (package
1095 (name "ocaml-zarith")
1096 (version "1.9.1")
1097 (source (origin
1098 (method git-fetch)
1099 (uri (git-reference
1100 (url "https://github.com/ocaml/Zarith")
1101 (commit (string-append "release-" version))))
1102 (file-name (git-file-name name version))
1103 (sha256
1104 (base32
1105 "0hv5ywz1q2cgn8apfz490clwk5hcynr937g2v8i13x2ax4bnv0lz"))))
1106 (build-system ocaml-build-system)
1107 (native-inputs
1108 `(("perl" ,perl)))
1109 (inputs
1110 `(("gmp" ,gmp)))
1111 (arguments
1112 `(#:tests? #f ; no test target
1113 #:phases
1114 (modify-phases %standard-phases
1115 (replace 'configure
1116 (lambda _ (invoke "./configure"))))))
1117 (home-page "https://forge.ocamlcore.org/projects/zarith/")
1118 (synopsis "Implements arbitrary-precision integers")
1119 (description "Implements arithmetic and logical operations over
1120 arbitrary-precision integers. It uses GMP to efficiently implement arithmetic
1121 over big integers. Small integers are represented as Caml unboxed integers,
1122 for speed and space economy.")
1123 (license license:lgpl2.1+))) ; with an exception
1124
1125 (define-public ocaml-frontc
1126 (package
1127 (name "ocaml-frontc")
1128 (version "3.4.2")
1129 (source (origin
1130 (method git-fetch)
1131 (uri (git-reference
1132 (url "https://github.com/BinaryAnalysisPlatform/FrontC")
1133 (commit (string-append
1134 "V_" (string-join (string-split version #\.) "_")))))
1135 (file-name (git-file-name name version))
1136 (sha256
1137 (base32
1138 "0k7jk9hkglnkk27s62xl493jyqc017gyvwqb1lyc0ywbb001s102"))))
1139 (build-system ocaml-build-system)
1140 (arguments
1141 `(#:phases
1142 (modify-phases %standard-phases
1143 (delete 'configure)
1144 (add-after 'install 'install-meta
1145 (lambda* (#:key outputs #:allow-other-keys)
1146 (let ((out (assoc-ref outputs "out")))
1147 (with-output-to-file
1148 (string-append out "/lib/ocaml/frontc/META")
1149 (lambda _
1150 (display
1151 (string-append
1152 "description = \"Parser for the C language\"
1153 version = \"" ,version "\"
1154 requires = \"unix\"
1155 archive(byte) = \"frontc.cma\"
1156 archive(native) = \"frontc.cmxa\""))))
1157 (symlink (string-append out "/lib/ocaml/frontc")
1158 (string-append out "/lib/ocaml/FrontC"))))))
1159 #:make-flags (list (string-append "PREFIX="
1160 (assoc-ref %outputs "out"))
1161 "OCAML_SITE=$(LIB_DIR)/ocaml/")))
1162 (properties `((upstream-name . "FrontC")))
1163 (home-page "https://www.irit.fr/FrontC")
1164 (synopsis "C parser and lexer library")
1165 (description "FrontC is an OCAML library providing a C parser and lexer.
1166 The result is a syntactic tree easy to process with usual OCAML tree management.
1167 It provides support for ANSI C syntax, old-C K&R style syntax and the standard
1168 GNU CC attributes. It provides also a C pretty printer as an example of use.")
1169 (license license:lgpl2.1)))
1170
1171 (define-public ocaml-qcheck
1172 (package
1173 (name "ocaml-qcheck")
1174 (version "0.12")
1175 (source
1176 (origin
1177 (method git-fetch)
1178 (uri (git-reference
1179 (url "https://github.com/c-cube/qcheck")
1180 (commit version)))
1181 (file-name (git-file-name name version))
1182 (sha256
1183 (base32 "1llnfynhlndwyjig7wrayjnds2b3mggp5lw20dwxhn2i2lkkb22m"))))
1184 (build-system dune-build-system)
1185 (arguments
1186 `(#:test-target "."
1187 #:phases
1188 (modify-phases %standard-phases
1189 (add-before 'build 'fix-deprecated
1190 (lambda _
1191 (substitute* "src/core/QCheck.ml"
1192 (("Pervasives.compare") "compare"))
1193 #t)))))
1194 (propagated-inputs
1195 `(("ocaml-alcotest" ,ocaml-alcotest)
1196 ("ocaml-ounit" ,ocaml-ounit)))
1197 (native-inputs
1198 `(("ocamlbuild" ,ocamlbuild)))
1199 (home-page "https://github.com/c-cube/qcheck")
1200 (synopsis "QuickCheck inspired property-based testing for OCaml")
1201 (description "QuickCheck inspired property-based testing for OCaml. This
1202 module checks invariants (properties of some types) over randomly
1203 generated instances of the type. It provides combinators for generating
1204 instances and printing them.")
1205 (license license:lgpl3+)))
1206
1207 (define-public ocaml-qtest
1208 (package
1209 (name "ocaml-qtest")
1210 (version "2.10.1")
1211 (source (origin
1212 (method git-fetch)
1213 (uri (git-reference
1214 (url "https://github.com/vincent-hugot/qtest/")
1215 (commit (string-append "v" version))))
1216 (file-name (git-file-name name version))
1217 (sha256
1218 (base32
1219 "0gddzan4vzs0vklsxhirdjrvx3rp7hhh2yr20vi13nq8rwkn9w29"))))
1220 (build-system dune-build-system)
1221 (arguments
1222 `(#:test-target "tests"))
1223 (propagated-inputs
1224 `(("ounit" ,ocaml-ounit)
1225 ("qcheck" ,ocaml-qcheck)))
1226 (home-page "https://github.com/vincent-hugot/qtest")
1227 (synopsis "Inline (Unit) Tests for OCaml")
1228 (description "Qtest extracts inline unit tests written using a special
1229 syntax in comments. Those tests are then run using the oUnit framework and the
1230 qcheck library. The possibilities range from trivial tests -- extremely simple
1231 to use -- to sophisticated random generation of test cases.")
1232 (license license:lgpl3+)))
1233
1234 (define-public ocaml-stringext
1235 (package
1236 (name "ocaml-stringext")
1237 (version "1.6.0")
1238 (source (origin
1239 (method git-fetch)
1240 (uri (git-reference
1241 (url "https://github.com/rgrinberg/stringext")
1242 (commit version)))
1243 (file-name (git-file-name name version))
1244 (sha256
1245 (base32
1246 "1m09cmn3vrk3gdm60fb730qsygcfyxsyv7gl9xfzck08q1x2x9qx"))))
1247 (build-system dune-build-system)
1248 (arguments
1249 `(#:test-target "."))
1250 (native-inputs
1251 `(("ocamlbuild" ,ocamlbuild)
1252 ("qtest" ,ocaml-qtest)))
1253 (home-page "https://github.com/rgrinberg/stringext")
1254 (synopsis "Extra string functions for OCaml")
1255 (description "Provides a single module named Stringext that provides a grab
1256 bag of often used but missing string functions from the stdlib. E.g, split,
1257 full_split, cut, rcut, etc..")
1258 ;; the only mention of a license in this project is in its `opam' file
1259 ;; where it says `mit'.
1260 (license license:expat)))
1261
1262 (define dune-bootstrap
1263 (package
1264 (name "dune")
1265 (version "2.7.1")
1266 (source (origin
1267 (method git-fetch)
1268 (uri (git-reference
1269 (url "https://github.com/ocaml/dune")
1270 (commit version)))
1271 (file-name (git-file-name name version))
1272 (sha256
1273 (base32
1274 "10qgx83fq8b522y9mpllrp0l5cgmr2bs5s7aix5img21hlbm34in"))))
1275 (build-system ocaml-build-system)
1276 (arguments
1277 `(#:tests? #f; require odoc
1278 #:make-flags (list "release"
1279 (string-append "PREFIX=" (assoc-ref %outputs "out"))
1280 (string-append "LIBDIR=" (assoc-ref %outputs "out")
1281 "/lib/ocaml/site-lib"))
1282 #:phases
1283 (modify-phases %standard-phases
1284 (replace 'configure
1285 (lambda* (#:key outputs #:allow-other-keys)
1286 (mkdir-p "src/dune")
1287 (invoke "./configure")
1288 #t)))))
1289 (home-page "https://github.com/ocaml/dune")
1290 (synopsis "OCaml build system")
1291 (description "Dune is a build system that was designed to simplify the
1292 release of Jane Street packages. It reads metadata from @file{dune} files
1293 following a very simple s-expression syntax.")
1294 (license license:expat)))
1295
1296 (define-public dune-configurator
1297 (package
1298 (inherit dune-bootstrap)
1299 (name "dune-configurator")
1300 (build-system dune-build-system)
1301 (arguments
1302 `(#:package "dune-configurator"
1303 #:dune ,dune-bootstrap
1304 ; require ppx_expect
1305 #:tests? #f))
1306 (propagated-inputs
1307 `(("ocaml-csexp" ,ocaml-csexp)))
1308 (synopsis "Dune helper library for gathering system configuration")
1309 (description "Dune-configurator is a small library that helps writing
1310 OCaml scripts that test features available on the system, in order to generate
1311 config.h files for instance. Among other things, dune-configurator allows one to:
1312
1313 @itemize
1314 @item test if a C program compiles
1315 @item query pkg-config
1316 @item import #define from OCaml header files
1317 @item generate config.h file
1318 @end itemize")))
1319
1320 (define-public dune
1321 (package
1322 (inherit dune-bootstrap)
1323 (propagated-inputs
1324 `(("dune-configurator" ,dune-configurator)))
1325 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-dune))))))
1326
1327 (define-public ocaml4.07-dune
1328 (package
1329 (inherit (package-with-ocaml4.07 dune-bootstrap))
1330 (version "1.11.3")
1331 (source (origin
1332 (method git-fetch)
1333 (uri (git-reference
1334 (url "https://github.com/ocaml/dune")
1335 (commit version)))
1336 (file-name (git-file-name "dune" version))
1337 (sha256
1338 (base32
1339 "0l4x0x2fz135pljv88zj8y6w1ninsqw0gn1mdxzprd6wbxbyn8wr"))))))
1340
1341 (define-public ocaml-csexp
1342 (package
1343 (name "ocaml-csexp")
1344 (version "1.3.2")
1345 (source (origin
1346 (method git-fetch)
1347 (uri (git-reference
1348 (url "https://github.com/ocaml-dune/csexp")
1349 (commit version)))
1350 (file-name (git-file-name name version))
1351 (sha256
1352 (base32
1353 "190zppgvdjgghmrnx67ayzzk86qdjy3yn5fcrcw08wsh93384pl0"))))
1354 (build-system dune-build-system)
1355 (arguments
1356 `(#:tests? #f; FIXME: needs ppx_expect, but which version?
1357 #:dune ,dune-bootstrap
1358 #:phases
1359 (modify-phases %standard-phases
1360 (add-before 'build 'chmod
1361 (lambda _
1362 (for-each (lambda (file) (chmod file #o644)) (find-files "." ".*"))
1363 #t)))))
1364 (propagated-inputs
1365 `(("ocaml-result" ,ocaml-result)))
1366 (home-page "https://github.com/ocaml-dune/csexp")
1367 (synopsis "Parsing and printing of S-expressions in Canonical form")
1368 (description "This library provides minimal support for Canonical
1369 S-expressions. Canonical S-expressions are a binary encoding of
1370 S-expressions that is super simple and well suited for communication
1371 between programs.
1372
1373 This library only provides a few helpers for simple applications. If
1374 you need more advanced support, such as parsing from more fancy input
1375 sources, you should consider copying the code of this library given
1376 how simple parsing S-expressions in canonical form is.
1377
1378 To avoid a dependency on a particular S-expression library, the only
1379 module of this library is parameterised by the type of S-expressions.")
1380 (license license:expat)))
1381
1382 (define-public ocaml-migrate-parsetree
1383 (package
1384 (name "ocaml-migrate-parsetree")
1385 (version "1.7.3")
1386 (home-page "https://github.com/ocaml-ppx/ocaml-migrate-parsetree")
1387 (source
1388 (origin
1389 (method git-fetch)
1390 (uri (git-reference
1391 (url (string-append home-page ".git"))
1392 (commit (string-append "v" version))))
1393 (file-name (git-file-name name version))
1394 (sha256
1395 (base32
1396 "0336vz0galjnsazbmkxjwdv1qvdqsx2rgrvp778xgq2fzasz45cx"))))
1397 (build-system dune-build-system)
1398 (arguments
1399 `(#:tests? #f))
1400 (propagated-inputs
1401 `(("ocaml-ppx-derivers" ,ocaml-ppx-derivers)
1402 ("ocamlbuild" ,ocamlbuild)
1403 ("ocaml-result" ,ocaml-result)))
1404 (properties `((upstream-name . "ocaml-migrate-parsetree")))
1405 (synopsis "OCaml parsetree converter")
1406 (description "This library converts between parsetrees of different OCaml
1407 versions. For each version, there is a snapshot of the parsetree and conversion
1408 functions to the next and/or previous version.")
1409 (license license:lgpl2.1+)))
1410
1411 (define-public ocaml-ppx-tools-versioned
1412 (package
1413 (name "ocaml-ppx-tools-versioned")
1414 (version "5.4.0")
1415 (source (origin
1416 (method git-fetch)
1417 (uri (git-reference
1418 (url "https://github.com/ocaml-ppx/ppx_tools_versioned")
1419 (commit version)))
1420 (file-name (git-file-name name version))
1421 (sha256
1422 (base32
1423 "07lnj4yzwvwyh5fhpp1dxrys4ddih15jhgqjn59pmgxinbnddi66"))))
1424 (build-system dune-build-system)
1425 (arguments
1426 `(#:test-target "."))
1427 (propagated-inputs
1428 `(("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)))
1429 (properties `((upstream-name . "ppx_tools_versioned")))
1430 (home-page "https://github.com/let-def/ppx_tools_versioned")
1431 (synopsis "Variant of ppx_tools")
1432 (description "This package is a variant of ppx_tools based on
1433 ocaml-migrate-parsetree")
1434 (license license:expat)))
1435
1436 (define-public ocaml-bitstring
1437 (package
1438 (name "ocaml-bitstring")
1439 (version "3.1.0")
1440 (source (origin
1441 (method url-fetch)
1442 (uri (string-append "https://bitbucket.org/thanatonauts/bitstring/"
1443 "get/v" version ".tar.gz"))
1444 (file-name (string-append name "-" version ".tar.gz"))
1445 (sha256
1446 (base32
1447 "15jjk2pq1vx311gl49s5ag6x5y0654x35w75z07g7kr2q334hqps"))))
1448 (build-system dune-build-system)
1449 (native-inputs
1450 `(("time" ,time)
1451 ("autoconf" ,autoconf)
1452 ("automake" ,automake)))
1453 (propagated-inputs
1454 `(("ocaml-ppx-tools-versioned" ,ocaml-ppx-tools-versioned)))
1455 (arguments
1456 `(#:package "bitstring"
1457 #:tests? #f; Tests fail to build
1458 #:phases
1459 (modify-phases %standard-phases
1460 (add-before 'build 'upgrade
1461 (lambda _
1462 (invoke "dune" "upgrade")
1463 #t)))))
1464 (home-page "https://github.com/xguerin/bitstring")
1465 (synopsis "Bitstrings and bitstring matching for OCaml")
1466 (description "Adds Erlang-style bitstrings and matching over bitstrings as
1467 a syntax extension and library for OCaml. You can use this module to both parse
1468 and generate binary formats, files and protocols. Bitstring handling is added
1469 as primitives to the language, making it exceptionally simple to use and very
1470 powerful.")
1471 (license license:isc)))
1472
1473 (define-public ocaml-result
1474 (package
1475 (name "ocaml-result")
1476 (version "1.5")
1477 (source (origin
1478 (method git-fetch)
1479 (uri (git-reference
1480 (url "https://github.com/janestreet/result")
1481 (commit version)))
1482 (file-name (git-file-name name version))
1483 (sha256
1484 (base32
1485 "166laj8qk7466sdl037c6cjs4ac571hglw4l5qpyll6df07h6a7q"))))
1486 (build-system dune-build-system)
1487 (arguments
1488 `(#:test-target "."
1489 #:dune ,dune-bootstrap))
1490 (home-page "https://github.com/janestreet/result")
1491 (synopsis "Compatibility Result module")
1492 (description "Uses the new result type defined in OCaml >= 4.03 while
1493 staying compatible with older version of OCaml should use the Result module
1494 defined in this library.")
1495 (license license:bsd-3)))
1496
1497 (define-public ocaml-topkg
1498 (package
1499 (name "ocaml-topkg")
1500 (version "1.0.0")
1501 (source (origin
1502 (method url-fetch)
1503 (uri (string-append "http://erratique.ch/software/topkg/releases/"
1504 "topkg-" version ".tbz"))
1505 (sha256
1506 (base32
1507 "1df61vw6v5bg2mys045682ggv058yqkqb67w7r2gz85crs04d5fw"))))
1508 (build-system ocaml-build-system)
1509 (native-inputs
1510 `(("opam" ,opam)
1511 ("ocamlbuild" ,ocamlbuild)))
1512 (propagated-inputs
1513 `(("result" ,ocaml-result)))
1514 (arguments
1515 `(#:tests? #f
1516 #:build-flags '("build")
1517 #:phases
1518 (modify-phases %standard-phases
1519 (delete 'configure))))
1520 (home-page "http://erratique.ch/software/topkg")
1521 (synopsis "Transitory OCaml software packager")
1522 (description "Topkg is a packager for distributing OCaml software. It
1523 provides an API to describe the files a package installs in a given build
1524 configuration and to specify information about the package's distribution,
1525 creation and publication procedures.")
1526 (license license:isc)))
1527
1528 (define-public ocaml-rresult
1529 (package
1530 (name "ocaml-rresult")
1531 (version "0.5.0")
1532 (source (origin
1533 (method url-fetch)
1534 (uri (string-append "http://erratique.ch/software/rresult/releases/"
1535 "rresult-" version ".tbz"))
1536 (sha256
1537 (base32
1538 "1xxycxhdhaq8p9vhwi93s2mlxjwgm44fcxybx5vghzgbankz9yhm"))))
1539 (build-system ocaml-build-system)
1540 (native-inputs
1541 `(("opam" ,opam)
1542 ("ocamlbuild" ,ocamlbuild)))
1543 (propagated-inputs
1544 `(("topkg" ,ocaml-topkg)))
1545 (arguments
1546 `(#:tests? #f
1547 #:build-flags '("build")
1548 #:phases
1549 (modify-phases %standard-phases
1550 (delete 'configure))))
1551 (home-page "http://erratique.ch/software/rresult")
1552 (synopsis "Result value combinators for OCaml")
1553 (description "Handle computation results and errors in an explicit and
1554 declarative manner, without resorting to exceptions. It defines combinators
1555 to operate on the result type available from OCaml 4.03 in the standard
1556 library.")
1557 (license license:isc)))
1558
1559 (define-public ocaml4.07-sqlite3
1560 (package
1561 (name "ocaml4.07-sqlite3")
1562 (version "4.4.1")
1563 (source
1564 (origin
1565 (method git-fetch)
1566 (uri (git-reference
1567 (url "https://github.com/mmottl/sqlite3-ocaml")
1568 (commit version)))
1569 (file-name (git-file-name name version))
1570 (sha256
1571 (base32
1572 "1536agm5fgcqysszhpd3kmw7lkc5n5ni7gmlyglrbvmnmrwf3av2"))))
1573 (build-system dune-build-system)
1574 (arguments
1575 `(#:ocaml ,ocaml-4.07
1576 #:findlib ,ocaml4.07-findlib
1577 #:dune ,ocaml4.07-dune))
1578 (native-inputs
1579 `(("ocaml-base" ,ocaml4.07-base)
1580 ("ocaml-stdio" ,ocaml4.07-stdio)
1581 ("pkg-config" ,pkg-config)))
1582 (inputs
1583 `(("sqlite" ,sqlite)))
1584 (home-page "https://mmottl.github.io/sqlite3-ocaml")
1585 (synopsis "SQLite3 Bindings for OCaml")
1586 (description
1587 "SQLite3-OCaml is an OCaml library with bindings to the SQLite3 client
1588 API. Sqlite3 is a self-contained, serverless, zero-configuration,
1589 transactional SQL database engine with outstanding performance for many use
1590 cases. These bindings are written in a way that enables a friendly
1591 coexistence with the old (version 2) SQLite and its OCaml wrapper
1592 @code{ocaml-sqlite}.")
1593 (license license:expat)))
1594
1595 (define-public ocaml-csv
1596 (package
1597 (name "ocaml-csv")
1598 (version "2.3")
1599 (source
1600 (origin
1601 (method git-fetch)
1602 (uri (git-reference
1603 (url "https://github.com/Chris00/ocaml-csv")
1604 (commit version)))
1605 (file-name (git-file-name name version))
1606 (sha256
1607 (base32
1608 "19k48517s8y1zb91a1312a0n94cbh5i5dixndcrqjmf87kkz61zx"))))
1609 (build-system dune-build-system)
1610 (arguments
1611 `(#:package "csv"
1612 #:test-target "."))
1613 (home-page "https://github.com/Chris00/ocaml-csv")
1614 (synopsis "Pure OCaml functions to read and write CSV")
1615 (description
1616 "@dfn{Comma separated values} (CSV) is a simple tabular format supported
1617 by all major spreadsheets. This library implements pure OCaml functions to
1618 read and write files in this format as well as some convenience functions to
1619 manipulate such data.")
1620 ;; This is LGPLv2.1 with an exception that allows packages statically-linked
1621 ;; against the library to be released under any terms.
1622 (license license:lgpl2.1)))
1623
1624 (define-public ocaml-mtime
1625 (package
1626 (name "ocaml-mtime")
1627 (version "1.1.0")
1628 (source (origin
1629 (method url-fetch)
1630 (uri (string-append "http://erratique.ch/software/mtime/releases/"
1631 "mtime-" version ".tbz"))
1632 (sha256
1633 (base32
1634 "1qb4ljwirrc3g8brh97s76rjky2cpmy7zm87y7iqd6pxix52ydk3"))))
1635 (build-system ocaml-build-system)
1636 (native-inputs
1637 `(("ocamlbuild" ,ocamlbuild)
1638 ("opam" ,opam)))
1639 (propagated-inputs
1640 `(("topkg" ,ocaml-topkg)))
1641 (arguments
1642 `(#:tests? #f
1643 #:build-flags (list "build" "--with-js_of_ocaml" "false")
1644 #:phases
1645 (modify-phases %standard-phases
1646 (delete 'configure))))
1647 (home-page "http://erratique.ch/software/mtime")
1648 (synopsis "Monotonic wall-clock time for OCaml")
1649 (description "Access monotonic wall-clock time. It measures time
1650 spans without being subject to operating system calendar time adjustments.")
1651 (license license:isc)))
1652
1653 (define-public ocaml-cmdliner
1654 (package
1655 (name "ocaml-cmdliner")
1656 (version "1.0.3")
1657 (source (origin
1658 (method url-fetch)
1659 (uri (string-append "http://erratique.ch/software/cmdliner/releases/"
1660 "cmdliner-" version ".tbz"))
1661 (sha256
1662 (base32
1663 "0g3w4hvc1cx9x2yp5aqn6m2rl8lf9x1dn754hfq8m1sc1102lxna"))))
1664 (build-system ocaml-build-system)
1665 (inputs
1666 `(("ocaml-result" ,ocaml-result)))
1667 (native-inputs
1668 `(("ocamlbuild" ,ocamlbuild)))
1669 (arguments
1670 `(#:tests? #f
1671 #:make-flags (list (string-append "LIBDIR=" (assoc-ref %outputs "out")
1672 "/lib/ocaml/site-lib/cmdliner"))
1673 #:phases
1674 (modify-phases %standard-phases
1675 (delete 'configure)
1676 (add-before 'build 'fix-source-file-order
1677 (lambda _
1678 (substitute* "build.ml"
1679 (("Sys.readdir dir")
1680 "let a = Sys.readdir dir in Array.sort String.compare a; a"))
1681 #t)))))
1682 (home-page "http://erratique.ch/software/cmdliner")
1683 (synopsis "Declarative definition of command line interfaces for OCaml")
1684 (description "Cmdliner is a module for the declarative definition of command
1685 line interfaces. It provides a simple and compositional mechanism to convert
1686 command line arguments to OCaml values and pass them to your functions. The
1687 module automatically handles syntax errors, help messages and UNIX man page
1688 generation. It supports programs with single or multiple commands and respects
1689 most of the POSIX and GNU conventions.")
1690 (license license:bsd-3)))
1691
1692 (define-public ocaml-fmt
1693 (package
1694 (name "ocaml-fmt")
1695 (version "0.8.9")
1696 (source
1697 (origin
1698 (method url-fetch)
1699 (uri (string-append "http://erratique.ch/software/fmt/releases/fmt-"
1700 version ".tbz"))
1701 (sha256 (base32
1702 "0gkkkj4x678vxdda4xaw2dd44qjacavsvn5nx8gydfwah6pjbkxk"))))
1703 (build-system ocaml-build-system)
1704 (native-inputs
1705 `(("ocamlbuild" ,ocamlbuild)
1706 ("opam" ,opam)
1707 ("topkg" ,ocaml-topkg)))
1708 (propagated-inputs
1709 `(("cmdliner" ,ocaml-cmdliner)
1710 ("ocaml-stdlib-shims" ,ocaml-stdlib-shims)
1711 ("ocaml-uchar" ,ocaml-uchar)))
1712 (arguments `(#:tests? #f
1713 #:build-flags (list "build" "--with-base-unix" "true"
1714 "--with-cmdliner" "true")
1715 #:phases
1716 (modify-phases %standard-phases
1717 (delete 'configure))))
1718 (home-page "http://erratique.ch/software/fmt")
1719 (synopsis "OCaml Format pretty-printer combinators")
1720 (description "Fmt exposes combinators to devise Format pretty-printing
1721 functions.")
1722 (license license:isc)))
1723
1724 (define-public ocaml-astring
1725 (package
1726 (name "ocaml-astring")
1727 (version "0.8.3")
1728 (source
1729 (origin
1730 (method url-fetch)
1731 (uri (string-append "http://erratique.ch/software/astring/releases/astring-"
1732 version ".tbz"))
1733 (sha256 (base32
1734 "0ixjwc3plrljvj24za3l9gy0w30lsbggp8yh02lwrzw61ls4cri0"))))
1735 (build-system ocaml-build-system)
1736 (native-inputs
1737 `(("ocamlbuild" ,ocamlbuild)
1738 ("opam" ,opam)
1739 ("topkg" ,ocaml-topkg)))
1740 (arguments
1741 `(#:tests? #f
1742 #:build-flags (list "build")
1743 #:phases
1744 (modify-phases %standard-phases
1745 (delete 'configure))))
1746 (home-page "http://erratique.ch/software/astring")
1747 (synopsis "Alternative String module for OCaml")
1748 (description "Astring exposes an alternative String module for OCaml. This
1749 module balances minimality and expressiveness for basic, index-free, string
1750 processing and provides types and functions for substrings, string sets and
1751 string maps. The String module exposed by Astring has exception safe functions,
1752 removes deprecated and rarely used functions, alters some signatures and names,
1753 adds a few missing functions and fully exploits OCaml's newfound string
1754 immutability.")
1755 (license license:isc)))
1756
1757 (define-public ocaml-alcotest
1758 (package
1759 (name "ocaml-alcotest")
1760 (version "1.0.0")
1761 (source (origin
1762 (method url-fetch)
1763 (uri (string-append "https://github.com/mirage/alcotest/releases/"
1764 "download/" version "/alcotest-" version ".tbz"))
1765 (sha256
1766 (base32
1767 "1a43ilhwnj58pq3bi78ni46l9wh6klmmgfc93i94mvyx48bzzayx"))))
1768 (build-system dune-build-system)
1769 (arguments
1770 `(#:package "alcotest"
1771 #:test-target "."))
1772 (native-inputs
1773 `(("ocamlbuild" ,ocamlbuild)))
1774 (propagated-inputs
1775 `(("ocaml-astring" ,ocaml-astring)
1776 ("ocaml-cmdliner" ,ocaml-cmdliner)
1777 ("ocaml-fmt" ,ocaml-fmt)
1778 ("ocaml-re" ,ocaml-re)
1779 ("ocaml-stdlib-shims" ,ocaml-stdlib-shims)
1780 ("ocaml-uuidm" ,ocaml-uuidm)
1781 ("ocaml-uutf" ,ocaml-uutf)))
1782 (home-page "https://github.com/mirage/alcotest")
1783 (synopsis "Lightweight OCaml test framework")
1784 (description "Alcotest exposes simple interface to perform unit tests. It
1785 exposes a simple TESTABLE module type, a check function to assert test
1786 predicates and a run function to perform a list of unit -> unit test callbacks.
1787 Alcotest provides a quiet and colorful output where only faulty runs are fully
1788 displayed at the end of the run (with the full logs ready to inspect), with a
1789 simple (yet expressive) query language to select the tests to run.")
1790 (license license:isc)))
1791
1792 (define-public ocaml4.07-ppx-tools
1793 (package
1794 (name "ocaml4.07-ppx-tools")
1795 (version "5.1+4.06.0")
1796 (source
1797 (origin
1798 (method git-fetch)
1799 (uri (git-reference
1800 (url "https://github.com/alainfrisch/ppx_tools")
1801 (commit version)))
1802 (file-name (git-file-name name version))
1803 (sha256 (base32
1804 "1ww4cspdpgjjsgiv71s0im5yjkr3544x96wsq1vpdacq7dr7zwiw"))))
1805 (build-system ocaml-build-system)
1806 (arguments
1807 `(#:phases (modify-phases %standard-phases (delete 'configure))
1808 #:tests? #f
1809 #:ocaml ,ocaml-4.07
1810 #:findlib ,ocaml4.07-findlib))
1811 (properties `((upstream-name . "ppx_tools")))
1812 (home-page "https://github.com/alainfrisch/ppx_tools")
1813 (synopsis "Tools for authors of ppx rewriters and other syntactic tools")
1814 (description "Tools for authors of ppx rewriters and other syntactic tools.")
1815 (license license:expat)))
1816
1817 (define-public ocaml-react
1818 (package
1819 (name "ocaml-react")
1820 (version "1.2.1")
1821 (source
1822 (origin
1823 (method url-fetch)
1824 (uri (string-append "http://erratique.ch/software/react/releases/react-"
1825 version ".tbz"))
1826 (sha256 (base32
1827 "1aj8w79gdd9xnrbz7s5p8glcb4pmimi8jp9f439dqnf6ih3mqb3v"))))
1828 (build-system ocaml-build-system)
1829 (native-inputs
1830 `(("ocamlbuild" ,ocamlbuild)
1831 ("opam" ,opam)
1832 ("ocaml-topkg" ,ocaml-topkg)))
1833 (arguments
1834 `(#:tests? #f
1835 #:build-flags (list "build")
1836 #:phases
1837 (modify-phases %standard-phases
1838 (delete 'configure))))
1839 (home-page "http://erratique.ch/software/react")
1840 (synopsis "Declarative events and signals for OCaml")
1841 (description "React is an OCaml module for functional reactive programming
1842 (FRP). It provides support to program with time varying values: declarative
1843 events and signals. React doesn't define any primitive event or signal, it
1844 lets the client choose the concrete timeline.")
1845 (license license:bsd-3)))
1846
1847 (define-public ocaml-ssl
1848 (package
1849 (name "ocaml-ssl")
1850 (version "0.5.9")
1851 (source
1852 (origin
1853 (method git-fetch)
1854 (uri (git-reference
1855 (url "https://github.com/savonet/ocaml-ssl")
1856 (commit version)))
1857 (file-name (git-file-name name version))
1858 (sha256 (base32
1859 "04h02rvzrwp886n5hsx84rnc9b150iggy38g5v1x1rwz3pkdnmf0"))))
1860 (build-system dune-build-system)
1861 (arguments
1862 `(#:test-target "."))
1863 (native-inputs
1864 `(("autoconf" ,autoconf)
1865 ("automake" ,automake)
1866 ("which" ,which)))
1867 (propagated-inputs `(("openssl" ,openssl)))
1868 (home-page "https://github.com/savonet/ocaml-ssl/")
1869 (synopsis "OCaml bindings for OpenSSL")
1870 (description
1871 "OCaml-SSL is a set of bindings for OpenSSL, a library for communicating
1872 through Transport Layer Security (@dfn{TLS}) encrypted connections.")
1873 (license license:lgpl2.1)))
1874
1875 (define-public ocaml-mmap
1876 (package
1877 (name "ocaml-mmap")
1878 (version "1.1.0")
1879 (source (origin
1880 (method git-fetch)
1881 (uri (git-reference
1882 (url "https://github.com/mirage/mmap")
1883 (commit (string-append "v" version))))
1884 (file-name (git-file-name name version))
1885 (sha256
1886 (base32
1887 "1jaismy5d1bhbbanysmr2k79px0yv6ya265dri3949nha1l23i60"))))
1888 (build-system dune-build-system)
1889 (home-page "https://github.com/mirage/mmap")
1890 (synopsis "File mapping for OCaml")
1891 (description "This project provides a @command{Mmap.map_file} function
1892 for mapping files in memory. This function is the same as the
1893 @command{Unix.map_file} function added in OCaml >= 4.06.")
1894 (license (list license:qpl license:lgpl2.0))))
1895
1896 (define-public ocaml-lwt
1897 (package
1898 (name "ocaml-lwt")
1899 (version "5.1.1")
1900 (source
1901 (origin
1902 (method git-fetch)
1903 (uri (git-reference
1904 (url "https://github.com/ocsigen/lwt")
1905 (commit version)))
1906 (file-name (git-file-name name version))
1907 (sha256 (base32
1908 "1nl7rdnwfdhwcsm5zpay1nr9y5cbapd9x1qzily7zk9ab4v52m8g"))))
1909 (build-system dune-build-system)
1910 (arguments
1911 `(#:package "lwt"))
1912 (native-inputs
1913 `(("ocaml-bisect-ppx" ,ocaml-bisect-ppx)
1914 ("ocaml-cppo" ,ocaml-cppo)
1915 ("pkg-config" ,pkg-config)))
1916 (inputs
1917 `(("libev" ,libev)
1918 ("glib" ,glib)))
1919 (propagated-inputs
1920 `(("ocaml-mmap" ,ocaml-mmap)
1921 ("ocaml-ocplib-endian" ,ocaml-ocplib-endian)
1922 ("ocaml-result" ,ocaml-result)
1923 ("ocaml-seq" ,ocaml-seq)))
1924 (home-page "https://github.com/ocsigen/lwt")
1925 (synopsis "Cooperative threads and I/O in monadic style")
1926 (description "Lwt provides typed, composable cooperative threads. These
1927 make it easy to run normally-blocking I/O operations concurrently in a single
1928 process. Also, in many cases, Lwt threads can interact without the need for
1929 locks or other synchronization primitives.")
1930 (license license:lgpl2.1)))
1931
1932 (define-public ocaml-lwt-react
1933 (package
1934 (inherit ocaml-lwt)
1935 (name "ocaml-lwt-react")
1936 (version "1.1.3")
1937 (source (origin
1938 (method git-fetch)
1939 (uri (git-reference
1940 (url "https://github.com/ocsigen/lwt")
1941 ;; Version from opam
1942 (commit "4.3.0")))
1943 (file-name (git-file-name name version))
1944 (sha256
1945 (base32
1946 "0f7036srqz7zmnz0n164734smgkrqz78r1i35cg30x31kkr3pnn4"))))
1947 (arguments
1948 `(#:package "lwt_react"))
1949 (properties `((upstream-name . "lwt_react")))
1950 (propagated-inputs
1951 `(("ocaml-lwt" ,ocaml-lwt)
1952 ("ocaml-react" ,ocaml-react)))))
1953
1954 (define-public ocaml-lwt-log
1955 (package
1956 (name "ocaml-lwt-log")
1957 (version "1.1.1")
1958 (source (origin
1959 (method git-fetch)
1960 (uri (git-reference
1961 (url "https://github.com/aantron/lwt_log")
1962 (commit version)))
1963 (file-name (git-file-name name version))
1964 (sha256
1965 (base32
1966 "1n12i1rmn9cjn6p8yr6qn5dwbrwvym7ckr7bla04a1xnq8qlcyj7"))))
1967 (build-system dune-build-system)
1968 (arguments
1969 `(#:tests? #f)); require lwt_ppx
1970 (propagated-inputs
1971 `(("lwt" ,ocaml-lwt)))
1972 (properties `((upstream-name . "lwt_log")))
1973 (home-page "https://github.com/aantron/lwt_log")
1974 (synopsis "Logging library")
1975 (description "This package provides a deprecated logging component for
1976 ocaml lwt.")
1977 (license license:lgpl2.1)))
1978
1979 (define-public ocaml-logs
1980 (package
1981 (name "ocaml-logs")
1982 (version "0.7.0")
1983 (source (origin
1984 (method url-fetch)
1985 (uri (string-append "http://erratique.ch/software/logs/releases/"
1986 "logs-" version ".tbz"))
1987 (sha256
1988 (base32
1989 "1jnmd675wmsmdwyb5mx5b0ac66g4c6gpv5s4mrx2j6pb0wla1x46"))))
1990 (build-system ocaml-build-system)
1991 (arguments
1992 `(#:tests? #f
1993 #:build-flags (list "build" "--with-js_of_ocaml" "false")
1994 #:phases
1995 (modify-phases %standard-phases
1996 (delete 'configure))))
1997 (native-inputs
1998 `(("ocamlbuild" ,ocamlbuild)
1999 ("opam" ,opam)))
2000 (propagated-inputs
2001 `(("fmt" ,ocaml-fmt)
2002 ("lwt" ,ocaml-lwt)
2003 ("mtime" ,ocaml-mtime)
2004 ("result" ,ocaml-result)
2005 ("cmdliner" ,ocaml-cmdliner)
2006 ("topkg" ,ocaml-topkg)))
2007 (home-page "http://erratique.ch/software/logs")
2008 (synopsis "Logging infrastructure for OCaml")
2009 (description "Logs provides a logging infrastructure for OCaml. Logging is
2010 performed on sources whose reporting level can be set independently. Log
2011 message report is decoupled from logging and is handled by a reporter.")
2012 (license license:isc)))
2013
2014 (define-public ocaml-fpath
2015 (package
2016 (name "ocaml-fpath")
2017 (version "0.7.2")
2018 (source (origin
2019 (method url-fetch)
2020 (uri (string-append "http://erratique.ch/software/fpath/releases/"
2021 "fpath-" version ".tbz"))
2022 (sha256
2023 (base32
2024 "1hr05d8bpqmqcfdavn4rjk9rxr7v2zl84866f5knjifrm60sxqic"))))
2025 (build-system ocaml-build-system)
2026 (arguments
2027 `(#:tests? #f
2028 #:build-flags (list "build")
2029 #:phases
2030 (modify-phases %standard-phases
2031 (delete 'configure))))
2032 (native-inputs
2033 `(("ocamlbuild" ,ocamlbuild)
2034 ("opam" ,opam)))
2035 (propagated-inputs
2036 `(("topkg" ,ocaml-topkg)
2037 ("astring" ,ocaml-astring)))
2038 (home-page "http://erratique.ch/software/fpath")
2039 (synopsis "File system paths for OCaml")
2040 (description "Fpath is an OCaml module for handling file system paths with
2041 POSIX or Windows conventions. Fpath processes paths without accessing the
2042 file system and is independent from any system library.")
2043 (license license:isc)))
2044
2045 (define-public ocaml-bos
2046 (package
2047 (name "ocaml-bos")
2048 (version "0.2.0")
2049 (source (origin
2050 (method url-fetch)
2051 (uri (string-append "http://erratique.ch/software/bos/releases/"
2052 "bos-" version ".tbz"))
2053 (sha256
2054 (base32
2055 "1s10iqx8rgnxr5n93lf4blwirjf8nlm272yg5sipr7lsr35v49wc"))))
2056 (build-system ocaml-build-system)
2057 (arguments
2058 `(#:tests? #f
2059 #:build-flags (list "build")
2060 #:phases
2061 (modify-phases %standard-phases
2062 (delete 'configure))))
2063 (native-inputs
2064 `(("ocamlbuild" ,ocamlbuild)
2065 ("opam" ,opam)))
2066 (propagated-inputs
2067 `(("topkg" ,ocaml-topkg)
2068 ("astring" ,ocaml-astring)
2069 ("fmt" ,ocaml-fmt)
2070 ("fpath" ,ocaml-fpath)
2071 ("logs" ,ocaml-logs)
2072 ("rresult" ,ocaml-rresult)))
2073 (home-page "http://erratique.ch/software/bos")
2074 (synopsis "Basic OS interaction for OCaml")
2075 (description "Bos provides support for basic and robust interaction with
2076 the operating system in OCaml. It has functions to access the process
2077 environment, parse command line arguments, interact with the file system and
2078 run command line programs.")
2079 (license license:isc)))
2080
2081 (define-public ocaml-xmlm
2082 (package
2083 (name "ocaml-xmlm")
2084 (version "1.3.0")
2085 (source (origin
2086 (method url-fetch)
2087 (uri (string-append "http://erratique.ch/software/xmlm/releases/"
2088 "xmlm-" version ".tbz"))
2089 (sha256
2090 (base32
2091 "1rrdxg5kh9zaqmgapy9bhdqyxbbvxxib3bdfg1vhw4rrkp1z0x8n"))))
2092 (build-system ocaml-build-system)
2093 (arguments
2094 `(#:tests? #f
2095 #:build-flags (list "build")
2096 #:phases
2097 (modify-phases %standard-phases
2098 (delete 'configure))))
2099 (native-inputs
2100 `(("ocamlbuild" ,ocamlbuild)
2101 ("ocaml-topkg" ,ocaml-topkg)
2102 ("opam" ,opam)))
2103 (home-page "http://erratique.ch/software/xmlm")
2104 (synopsis "Streaming XML codec for OCaml")
2105 (description "Xmlm is a streaming codec to decode and encode the XML data
2106 format. It can process XML documents without a complete in-memory
2107 representation of the data.")
2108 (license license:isc)))
2109
2110 (define-public ocaml4.07-gen
2111 (package
2112 (name "ocaml4.07-gen")
2113 (version "0.5.2")
2114 (source (origin
2115 (method git-fetch)
2116 (uri (git-reference
2117 (url "https://github.com/c-cube/gen")
2118 (commit version)))
2119 (file-name (git-file-name name version))
2120 (sha256
2121 (base32
2122 "1h9g508rnj2j8va5nvhamzscp954vrkh0hdf4pn3d10pcfyslfg2"))))
2123 (build-system dune-build-system)
2124 (arguments
2125 `(#:tests? #f; no tests
2126 #:package "gen"
2127 #:ocaml ,ocaml-4.07
2128 #:findlib ,ocaml4.07-findlib
2129 #:dune ,ocaml4.07-dune))
2130 (propagated-inputs
2131 `(("ocaml-odoc" ,ocaml4.07-odoc)))
2132 (native-inputs
2133 `(("ocaml-qtest" ,(package-with-ocaml4.07 ocaml-qtest))
2134 ("ocaml-qcheck" ,(package-with-ocaml4.07 ocaml-qcheck))))
2135 (home-page "https://github.com/c-cube/gen/")
2136 (synopsis "Iterators for OCaml, both restartable and consumable")
2137 (description "Gen implements iterators of OCaml, that are both restartable
2138 and consumable.")
2139 (license license:bsd-2)))
2140
2141 (define-public ocaml4.07-sedlex
2142 (package
2143 (name "ocaml4.07-sedlex")
2144 (version "2.1")
2145 (source (origin
2146 (method git-fetch)
2147 (uri (git-reference
2148 (url "https://github.com/ocaml-community/sedlex")
2149 (commit (string-append "v" version))))
2150 (file-name (git-file-name name version))
2151 (sha256
2152 (base32
2153 "05f6qa8x3vhpdz1fcnpqk37fpnyyq13icqsk2gww5idjnh6kng26"))))
2154 (build-system dune-build-system)
2155 (arguments
2156 `(#:tests? #f; no tests
2157 #:package "sedlex"
2158 #:phases
2159 (modify-phases %standard-phases
2160 (add-before 'build 'copy-resources
2161 (lambda* (#:key inputs #:allow-other-keys)
2162 (with-directory-excursion "src/generator/data"
2163 (for-each
2164 (lambda (file)
2165 (copy-file (assoc-ref inputs file) file))
2166 '("DerivedCoreProperties.txt" "DerivedGeneralCategory.txt"
2167 "PropList.txt")))
2168 #t))
2169 (add-before 'build 'chmod
2170 (lambda _
2171 (for-each (lambda (file) (chmod file #o644)) (find-files "." ".*"))
2172 #t)))
2173 #:ocaml ,ocaml-4.07
2174 #:findlib ,ocaml4.07-findlib
2175 #:dune ,ocaml4.07-dune))
2176 (native-inputs
2177 `(("ocamlbuild" ,(package-with-ocaml4.07 ocamlbuild))))
2178 (propagated-inputs
2179 `(("ocaml-gen" ,ocaml4.07-gen)
2180 ("ocaml-ppx-tools-versioned"
2181 ,(package-with-ocaml4.07 ocaml-ppx-tools-versioned))
2182 ("ocaml-uchar" ,(package-with-ocaml4.07 ocaml-uchar))))
2183 ;; These three files are needed by src/generator/data/dune, but would be
2184 ;; downloaded using curl at build time.
2185 (inputs
2186 `(("DerivedCoreProperties.txt"
2187 ,(origin
2188 (method url-fetch)
2189 (uri "https://www.unicode.org/Public/12.1.0/ucd/DerivedCoreProperties.txt")
2190 (sha256
2191 (base32
2192 "0s6sn1yr9qmb2i6gf8dir2zpsbjv1frdfzy3i2yjylzvf637msx6"))))
2193 ("DerivedGeneralCategory.txt"
2194 ,(origin
2195 (method url-fetch)
2196 (uri "https://www.unicode.org/Public/12.1.0/ucd/extracted/DerivedGeneralCategory.txt")
2197 (sha256
2198 (base32
2199 "1rifzq9ba6c58dn0lrmcb5l5k4ksx3zsdkira3m5p6h4i2wriy3q"))))
2200 ("PropList.txt"
2201 ,(origin
2202 (method url-fetch)
2203 (uri "https://www.unicode.org/Public/12.1.0/ucd/PropList.txt")
2204 (sha256
2205 (base32
2206 "0gsb1jpj3mnqbjgbavi4l95gl6g4agq58j82km22fdfg63j3w3fk"))))))
2207 (home-page "https://www.cduce.org/download.html#side")
2208 (synopsis "Lexer generator for Unicode and OCaml")
2209 (description "Lexer generator for Unicode and OCaml.")
2210 (license license:expat)))
2211
2212 (define-public ocaml-uchar
2213 (package
2214 (name "ocaml-uchar")
2215 (version "0.0.2")
2216 (source
2217 (origin
2218 (method url-fetch)
2219 (uri (string-append "https://github.com/ocaml/uchar/releases/download/v"
2220 version "/uchar-" version ".tbz"))
2221 (sha256 (base32
2222 "1w2saw7zanf9m9ffvz2lvcxvlm118pws2x1wym526xmydhqpyfa7"))))
2223 (build-system ocaml-build-system)
2224 (arguments
2225 `(#:tests? #f
2226 #:build-flags (list "native=true" "native-dynlink=true")
2227 #:phases
2228 (modify-phases %standard-phases
2229 (delete 'configure))))
2230 (native-inputs
2231 `(("ocamlbuild" ,ocamlbuild)
2232 ("opam" ,opam)))
2233 (home-page "https://github.com/ocaml/uchar")
2234 (synopsis "Compatibility library for OCaml's Uchar module")
2235 (description "The uchar package provides a compatibility library for the
2236 `Uchar` module introduced in OCaml 4.03.")
2237 (license license:lgpl2.1)))
2238
2239 (define-public ocaml-uutf
2240 (package
2241 (name "ocaml-uutf")
2242 (version "1.0.1")
2243 (source (origin
2244 (method url-fetch)
2245 (uri (string-append "http://erratique.ch/software/uutf/releases/"
2246 "uutf-" version ".tbz"))
2247 (sha256
2248 (base32
2249 "1gp96dcggq7s84934vimxh89caaxa77lqiff1yywbwkilkkjcfqj"))))
2250 (build-system ocaml-build-system)
2251 (arguments
2252 `(#:tests? #f
2253 #:build-flags (list "build")
2254 #:phases
2255 (modify-phases %standard-phases
2256 (delete 'configure))))
2257 (native-inputs
2258 `(("ocamlbuild" ,ocamlbuild)
2259 ("opam" ,opam)
2260 ("topkg" ,ocaml-topkg)))
2261 (propagated-inputs
2262 `(("uchar" ,ocaml-uchar)
2263 ("cmdliner" ,ocaml-cmdliner)))
2264 (home-page "http://erratique.ch/software/uutf")
2265 (synopsis "Non-blocking streaming Unicode codec for OCaml")
2266 (description "Uutf is a non-blocking streaming codec to decode and encode
2267 the UTF-8, UTF-16, UTF-16LE and UTF-16BE encoding schemes. It can efficiently
2268 work character by character without blocking on IO. Decoders perform character
2269 position tracking and support newline normalization.
2270
2271 Functions are also provided to fold over the characters of UTF encoded OCaml
2272 string values and to directly encode characters in OCaml Buffer.t values.")
2273 (license license:isc)))
2274
2275 (define-public ocaml-jsonm
2276 (package
2277 (name "ocaml-jsonm")
2278 (version "1.0.1")
2279 (source (origin
2280 (method url-fetch)
2281 (uri (string-append "http://erratique.ch/software/jsonm/releases/"
2282 "jsonm-" version ".tbz"))
2283 (sha256
2284 (base32
2285 "1176dcmxb11fnw49b7yysvkjh0kpzx4s48lmdn5psq9vshp5c29w"))))
2286 (build-system ocaml-build-system)
2287 (arguments
2288 `(#:tests? #f
2289 #:build-flags (list "build")
2290 #:phases
2291 (modify-phases %standard-phases
2292 (delete 'configure))))
2293 (native-inputs
2294 `(("ocamlbuild" ,ocamlbuild)
2295 ("opam" ,opam)
2296 ("topkg" ,ocaml-topkg)))
2297 (propagated-inputs
2298 `(("uutf" ,ocaml-uutf)
2299 ("cmdliner" ,ocaml-cmdliner)))
2300 (home-page "http://erratique.ch/software/jsonm")
2301 (synopsis "Non-blocking streaming JSON codec for OCaml")
2302 (description "Jsonm is a non-blocking streaming codec to decode and encode
2303 the JSON data format. It can process JSON text without blocking on IO and
2304 without a complete in-memory representation of the data.")
2305 (license license:isc)))
2306
2307 (define-public ocaml-ocurl
2308 (package
2309 (name "ocaml-ocurl")
2310 (version "0.9.1")
2311 (source (origin
2312 (method url-fetch)
2313 (uri (string-append "http://ygrek.org.ua/p/release/ocurl/ocurl-"
2314 version ".tar.gz"))
2315 (sha256
2316 (base32
2317 "0n621cxb9012pj280c7821qqsdhypj8qy9qgrah79dkh6a8h2py6"))))
2318 (build-system ocaml-build-system)
2319 (arguments
2320 `(#:phases
2321 (modify-phases %standard-phases
2322 (add-before 'configure 'fix-/bin/sh
2323 (lambda* (#:key inputs #:allow-other-keys)
2324 (substitute* "configure"
2325 (("-/bin/sh") (string-append "-" (which "bash")))))))))
2326 (native-inputs
2327 `(("pkg-config" ,pkg-config)))
2328 (inputs `(("curl" ,curl)))
2329 (home-page "http://ocurl.forge.ocamlcore.org/")
2330 (synopsis "OCaml bindings for libcurl")
2331 (description "Client-side URL transfer library, supporting HTTP and a
2332 multitude of other network protocols (FTP/SMTP/RTSP/etc).")
2333 (license license:isc)))
2334
2335 (define-public ocaml-base64
2336 (package
2337 (name "ocaml-base64")
2338 (version "3.4.0")
2339 (source (origin
2340 (method git-fetch)
2341 (uri (git-reference
2342 (url "https://github.com/mirage/ocaml-base64")
2343 (commit (string-append "v" version))))
2344 (file-name (git-file-name name version))
2345 (sha256
2346 (base32
2347 "0aa1m1sr8p1hgc10p96mij7p22r3qcysvzy6fz2jqamfgswchgqc"))))
2348 (build-system dune-build-system)
2349 (arguments
2350 `(#:phases
2351 (modify-phases %standard-phases
2352 (add-before 'build 'fix-dune
2353 (lambda _
2354 ;; This package expects dune 2, which unbundled its configurator
2355 ;; module. We still use dune 1, so we need to let it know we need
2356 ;; its internal module.
2357 (substitute* "config/dune"
2358 (("dune-configurator") "dune.configurator"))
2359 #t)))))
2360 (native-inputs
2361 `(("ocaml-alcotest" ,ocaml-alcotest)
2362 ("ocaml-bos" ,ocaml-bos)
2363 ("ocaml-rresult" ,ocaml-rresult)))
2364 (home-page "https://github.com/mirage/ocaml-base64")
2365 (synopsis "Base64 encoding for OCaml")
2366 (description "Base64 is a group of similar binary-to-text encoding schemes
2367 that represent binary data in an ASCII string format by translating it into a
2368 radix-64 representation. It is specified in RFC 4648.")
2369 (license license:isc)))
2370
2371 (define-public ocamlify
2372 (package
2373 (name "ocamlify")
2374 (version "0.0.2")
2375 (source
2376 (origin
2377 (method url-fetch)
2378 (uri (string-append "https://download.ocamlcore.org/ocamlify/ocamlify/"
2379 version "/ocamlify-" version ".tar.gz"))
2380 (sha256
2381 (base32 "1f0fghvlbfryf5h3j4as7vcqrgfjb4c8abl5y0y5h069vs4kp5ii"))))
2382 (build-system ocaml-build-system)
2383 (arguments
2384 `(#:phases
2385 (modify-phases %standard-phases
2386 (add-after 'unpack 'disable-safe-string
2387 ;; Work around ‘Error: This expression has type string but an
2388 ;; expression was expected of type bytes’ since OCaml 4.06.
2389 (lambda _
2390 (setenv "OCAMLPARAM" "safe-string=0,_")
2391 #t))
2392 (delete 'check) ; tests are run during the build
2393 (replace 'configure
2394 (lambda* (#:key outputs #:allow-other-keys)
2395 (invoke "ocaml" "setup.ml" "-configure" "--prefix"
2396 (assoc-ref outputs "out")))))))
2397 (native-inputs
2398 `(("ocamlbuild" ,ocamlbuild)))
2399 (home-page "https://forge.ocamlcore.org/projects/ocamlify")
2400 (synopsis "Include files in OCaml code")
2401 (description "OCamlify creates OCaml source code by including
2402 whole files into OCaml string or string list. The code generated can be
2403 compiled as a standard OCaml file. It allows embedding external resources as
2404 OCaml code.")
2405 (license license:lgpl2.1+))); with the OCaml static compilation exception
2406
2407 (define-public omake
2408 (package
2409 (name "omake")
2410 (version "0.10.3")
2411 (source (origin
2412 (method url-fetch)
2413 (uri (string-append "http://download.camlcity.org/download/"
2414 "omake-" version ".tar.gz"))
2415 (sha256
2416 (base32
2417 "07bdg1h5i7qnlv9xq81ad5hfypl10hxm771h4rjyl5cn8plhfcgz"))
2418 (patches (search-patches "omake-fix-non-determinism.patch"))))
2419 (build-system ocaml-build-system)
2420 (arguments
2421 `(#:make-flags
2422 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
2423 #:tests? #f ; no test target
2424 #:phases
2425 (modify-phases %standard-phases
2426 (add-before 'configure 'fix-makefile
2427 (lambda* (#:key outputs #:allow-other-keys)
2428 (substitute* "mk/osconfig_unix.mk"
2429 (("CC = cc") "CC = gcc")))))))
2430 (native-inputs `(("hevea" ,hevea)))
2431 (home-page "http://projects.camlcity.org/projects/omake.html")
2432 (synopsis "Build system designed for scalability and portability")
2433 (description "Similar to make utilities you may have used, but it features
2434 many additional enhancements, including:
2435
2436 @enumerate
2437 @item Support for projects spanning several directories or directory hierarchies.
2438 @item Fast, reliable, automated, scriptable dependency analysis using MD5 digests,
2439 with full support for incremental builds.
2440 @item Dependency analysis takes the command lines into account — whenever the
2441 command line used to build a target changes, the target is considered
2442 out-of-date.
2443 @item Fully scriptable, includes a library that providing support for standard
2444 tasks in C, C++, OCaml, and LaTeX projects, or a mixture thereof.
2445 @end enumerate")
2446 (license (list license:lgpl2.1 ; libmojave
2447 license:expat ; OMake scripts
2448 license:gpl2)))) ; OMake itself, with ocaml linking exception
2449 ; see LICENSE.OMake
2450
2451 (define-public ocaml-batteries
2452 (package
2453 (name "ocaml-batteries")
2454 (version "2.10.0")
2455 (source (origin
2456 (method url-fetch)
2457 (uri (string-append "https://github.com/ocaml-batteries-team/"
2458 "batteries-included/releases/download/v"
2459 version "/batteries-" version ".tar.gz"))
2460 (sha256
2461 (base32
2462 "08ghw87d56h1a6y1nnh3x2wy9xj25jqfk5sp6ma9nsyd37babb0h"))))
2463 (build-system ocaml-build-system)
2464 (native-inputs
2465 `(("ocamlbuild" ,ocamlbuild)
2466 ("qtest" ,ocaml-qtest)))
2467 (propagated-inputs
2468 `(("ocaml-num" ,ocaml-num)))
2469 (arguments
2470 `(#:phases
2471 (modify-phases %standard-phases
2472 (delete 'check) ; tests are run by the build phase
2473 (add-before 'build 'fix-nondeterminism
2474 (lambda _
2475 (substitute* "setup.ml"
2476 (("Sys.readdir dirname")
2477 "let a = Sys.readdir dirname in Array.sort String.compare a; a"))
2478 #t))
2479 (replace 'build
2480 (lambda* (#:key inputs outputs #:allow-other-keys)
2481 (let ((files
2482 (map (lambda (str)
2483 (substring str 0 (- (string-length str) 1)))
2484 (append
2485 (find-files "src" ".*.mliv")
2486 (find-files "src" ".*.mlv")
2487 (find-files "src" ".*.mlp")))))
2488 (apply invoke "ocamlbuild" "-no-links" "-use-ocamlfind" "-I" "num"
2489 "-lflag" "-dllpath-all" files)
2490 (for-each (lambda (file)
2491 (copy-file (string-append "_build/" file) file))
2492 files))
2493 (invoke "ocamlbuild" "-no-links" "-use-ocamlfind" "-I" "num"
2494 "-lflag" "-dllpath-all" "build/mkconf.byte")
2495 (copy-file "_build/build/mkconf.byte" "build/mkconf.byte")
2496 (invoke "make" "all")
2497 #t)))))
2498 (home-page "http://batteries.forge.ocamlcore.org/")
2499 (synopsis "Development platform for the OCaml programming language")
2500 (description "Define a standard set of libraries which may be expected on
2501 every compliant installation of OCaml and organize these libraries into a
2502 hierarchy of modules.")
2503 (license license:lgpl2.1+)))
2504
2505 (define-public ocaml4.07-pcre
2506 (package
2507 (name "ocaml4.07-pcre")
2508 (version "7.4.1")
2509 (source (origin
2510 (method git-fetch)
2511 (uri (git-reference
2512 (url "https://github.com/mmottl/pcre-ocaml")
2513 (commit version)))
2514 (file-name (git-file-name name version))
2515 (sha256
2516 (base32
2517 "11sd8g668h48790lamz0riw9jgnfkaif5qdfa0akcndwa6aj07jf"))))
2518 (build-system dune-build-system)
2519 (arguments
2520 `(#:test-target "."
2521 #:ocaml ,ocaml-4.07
2522 #:findlib ,ocaml4.07-findlib
2523 #:dune ,ocaml4.07-dune))
2524 (native-inputs
2525 `(("ocaml-base" ,ocaml4.07-base)
2526 ("pcre:bin" ,pcre "bin")))
2527 (propagated-inputs `(("pcre" ,pcre)))
2528 (home-page "https://mmottl.github.io/pcre-ocaml")
2529 (synopsis "Bindings to the Perl Compatibility Regular Expressions library")
2530 (description "Pcre-ocaml offers library functions for string pattern
2531 matching and substitution, similar to the functionality offered by the Perl
2532 language.")
2533 (license license:lgpl2.1+))); with the OCaml link exception
2534
2535 (define-public ocaml4.07-expect
2536 (package
2537 (name "ocaml4.07-expect")
2538 (version "0.0.6")
2539 (source (origin
2540 (method url-fetch)
2541 (uri (ocaml-forge-uri name version 1736))
2542 (sha256
2543 (base32
2544 "098qvg9d4yrqzr5ax291y3whrpax0m3sx4gi6is0mblc96r9yqk0"))))
2545 (arguments
2546 `(#:tests? #f
2547 #:ocaml ,ocaml-4.07
2548 #:findlib ,ocaml4.07-findlib))
2549 (build-system ocaml-build-system)
2550 (native-inputs
2551 `(("ocamlbuild" ,(package-with-ocaml4.07 ocamlbuild))
2552 ("ocaml-num" ,(package-with-ocaml4.07 ocaml-num))
2553 ("ocaml-pcre" ,ocaml4.07-pcre)
2554 ("ounit" ,(package-with-ocaml4.07 ocaml-ounit))))
2555 (propagated-inputs
2556 `(("batteries" ,(package-with-ocaml4.07 ocaml-batteries))))
2557 (home-page "https://forge.ocamlcore.org/projects/ocaml-expect/")
2558 (synopsis "Simple implementation of expect")
2559 (description "Help building unitary testing of interactive program. You
2560 can match the question using a regular expression or a timeout.")
2561 (license license:lgpl2.1+))) ; with the OCaml static compilation exception
2562
2563 (define-public ocaml-stdlib-shims
2564 (package
2565 (name "ocaml-stdlib-shims")
2566 (version "0.1.0")
2567 (source (origin
2568 (method git-fetch)
2569 (uri (git-reference
2570 (url "https://github.com/ocaml/stdlib-shims")
2571 (commit version)))
2572 (file-name (git-file-name name version))
2573 (sha256
2574 (base32
2575 "007dwywsr5285z0np6a9nr0h8iqmyzfrlx6s5xaqcwj69zabsrjm"))))
2576 (build-system dune-build-system)
2577 (home-page "https://github.com/ocaml/stdlib-shims")
2578 (synopsis "OCaml stdlib features backport to older OCaml compilers")
2579 (description "This package backports some of the new stdlib features to
2580 older compilers, such as the Stdlib module. This allows projects that require
2581 compatibility with older compiler to use these new features in their code.")
2582 ;; with ocaml-linking exception
2583 (license license:lgpl2.1+)))
2584
2585 (define-public ocaml-fileutils
2586 (package
2587 (name "ocaml-fileutils")
2588 (version "0.6.2")
2589 (source (origin
2590 (method git-fetch)
2591 (uri (git-reference
2592 (url "https://github.com/gildor478/ocaml-fileutils")
2593 (commit (string-append "v" version))))
2594 (file-name (git-file-name name version))
2595 (sha256
2596 (base32
2597 "01qf51b8pb7vyfba7y0kb7ajwj1950im25d7f59821zwsibns3d9"))))
2598 (build-system dune-build-system)
2599 (propagated-inputs
2600 `(("ocaml-stdlib-shims" ,ocaml-stdlib-shims)))
2601 (native-inputs
2602 `(("ocaml-ounit" ,ocaml-ounit)))
2603 (home-page "http://ocaml-fileutils.forge.ocamlcore.org")
2604 (synopsis "Pure OCaml functions to manipulate real file and filename")
2605 (description "Library to provide pure OCaml functions to manipulate real
2606 file (POSIX like) and filename.")
2607 (license license:lgpl2.1+))) ; with the OCaml static compilation exception
2608
2609 (define-public ocaml-oasis
2610 (package
2611 (name "ocaml-oasis")
2612 (version "0.4.11")
2613 (source (origin
2614 (method url-fetch)
2615 (uri (ocaml-forge-uri name version 1757))
2616 (sha256
2617 (base32
2618 "0bn13mzfa98dq3y0jwzzndl55mnywaxv693z6f1rlvpdykp3vdqq"))
2619 (modules '((guix build utils)))
2620 (snippet
2621 '(begin
2622 (substitute* "test/test-main/Test.ml"
2623 ;; most of these tests fail because ld cannot find crti.o, but according
2624 ;; to the log file, the environment variables {LD_,}LIBRARY_PATH
2625 ;; are set correctly when LD_LIBRARY_PATH is defined beforhand.
2626 (("TestBaseCompat.tests;") "")
2627 (("TestExamples.tests;") "")
2628 (("TestFull.tests;") "")
2629 (("TestPluginDevFiles.tests;") "")
2630 (("TestPluginInternal.tests;") "")
2631 (("TestPluginOCamlbuild.tests;") "")
2632 (("TestPluginOMake.tests;") ""))
2633 #t))))
2634 (build-system ocaml-build-system)
2635 (arguments
2636 `(#:tests? #f))
2637 (native-inputs
2638 `(("ocamlbuild" ,ocamlbuild)
2639 ("ocamlify" ,ocamlify)
2640 ("ocamlmod" ,ocamlmod)))
2641 (home-page "https://oasis.forge.ocamlcore.org")
2642 (synopsis "Integrates a configure, build, install system in OCaml projects")
2643 (description "OASIS is a tool to integrate a configure, build and install
2644 system in your OCaml projects. It helps to create standard entry points in your
2645 build system and allows external tools to analyse your project easily.")
2646 (license license:lgpl2.1+))) ; with ocaml static compilation exception
2647
2648 (define-public ocaml-js-build-tools
2649 (package
2650 (name "ocaml-js-build-tools")
2651 (version "113.33.06")
2652 (source (janestreet-origin "js-build-tools" version
2653 "0r8z4fz8iy5y6hkdlkpwf6rk4qigcr3dzyv35585xgg2ahf12zy6"))
2654 (native-inputs
2655 `(("oasis" ,ocaml-oasis)
2656 ("ocamlbuild" ,ocamlbuild)
2657 ("opam" ,opam)))
2658 (build-system ocaml-build-system)
2659 (arguments janestreet-arguments)
2660 (home-page "https://github.com/janestreet/js-build-tools")
2661 (synopsis "Collection of tools to help building Jane Street Packages")
2662 (description "This package contains tools to help building Jane Street
2663 packages, but can be used for other purposes. It contains:
2664 @enumerate
2665 @item an @command{oasis2opam-install} tool to produce a @file{.install} file
2666 from the oasis build log
2667 @item a @code{js_build_tools} ocamlbuild plugin with various goodies.
2668 @end enumerate")
2669 (license license:asl2.0)))
2670
2671 (define-public ocaml-cppo
2672 (package
2673 (name "ocaml-cppo")
2674 (version "1.6.6")
2675 (source
2676 (origin
2677 (method git-fetch)
2678 (uri (git-reference
2679 (url "https://github.com/mjambon/cppo")
2680 (commit (string-append "v" version))))
2681 (file-name (git-file-name name version))
2682 (sha256 (base32
2683 "1smcc0l6fh2n0y6bp96c69j5nw755jja99w0b206wx3yb2m4w2hs"))))
2684 (build-system dune-build-system)
2685 (arguments
2686 `(#:tests? #f
2687 #:build-flags (list "--profile" "release")))
2688 (native-inputs
2689 `(("ocamlbuild" ,ocamlbuild)))
2690 (home-page "https://github.com/mjambon/cppo")
2691 (synopsis "Equivalent of the C preprocessor for OCaml programs")
2692 (description "Cppo is an equivalent of the C preprocessor for OCaml
2693 programs. It allows the definition of simple macros and file inclusion. Cppo is:
2694 @enumerate
2695 @item more OCaml-friendly than @command{cpp}
2696 @item easy to learn without consulting a manual
2697 @item reasonably fast
2698 @item simple to install and to maintain.
2699 @end enumerate")
2700 (license license:bsd-3)))
2701
2702 (define-public ocaml-seq
2703 (package
2704 (name "ocaml-seq")
2705 (version "0.1")
2706 (source
2707 (origin
2708 (method git-fetch)
2709 (uri (git-reference
2710 (url "https://github.com/c-cube/seq")
2711 (commit version)))
2712 (file-name (git-file-name name version))
2713 (sha256
2714 (base32 "1cjpsc7q76yfgq9iyvswxgic4kfq2vcqdlmxjdjgd4lx87zvcwrv"))))
2715 (build-system ocaml-build-system)
2716 (arguments
2717 `(#:tests? #f
2718 #:phases
2719 (modify-phases %standard-phases
2720 (delete 'configure)
2721 (delete 'build)
2722 (replace 'install
2723 (lambda* (#:key outputs #:allow-other-keys)
2724 (let ((install-dir (string-append (assoc-ref outputs "out")
2725 "/lib/ocaml/site-lib/seq")))
2726 (mkdir-p install-dir)
2727 (with-output-to-file (string-append install-dir "/META")
2728 (lambda _
2729 (display "name=\"seq\"
2730 version=\"[distributed with ocaml]\"
2731 description=\"dummy package for compatibility\"
2732 requires=\"\"")))
2733 #t))))))
2734 (home-page "https://github.com/c-cube/seq")
2735 (synopsis "OCaml's standard iterator type")
2736 (description "This package is a compatibility package for OCaml's
2737 standard iterator type starting from 4.07.")
2738 (license license:lgpl2.1+)))
2739
2740 (define-public ocaml-re
2741 (package
2742 (name "ocaml-re")
2743 (version "1.9.0")
2744 (source
2745 (origin
2746 (method git-fetch)
2747 (uri (git-reference
2748 (url "https://github.com/ocaml/ocaml-re")
2749 (commit version)))
2750 (file-name (git-file-name name version))
2751 (sha256
2752 (base32 "07ycb103mr4mrkxfd63cwlsn023xvcjp0ra0k7n2gwrg0mwxmfss"))))
2753 (build-system dune-build-system)
2754 (arguments
2755 `(#:tests? #f
2756 #:build-flags (list "--profile" "release")))
2757 (propagated-inputs
2758 `(("ocaml-seq" ,ocaml-seq)))
2759 (native-inputs
2760 `(("ounit" ,ocaml-ounit)))
2761 (home-page "https://github.com/ocaml/ocaml-re/")
2762 (synopsis "Regular expression library for OCaml")
2763 (description "Pure OCaml regular expressions with:
2764 @enumerate
2765 @item Perl-style regular expressions (module Re_perl)
2766 @item Posix extended regular expressions (module Re_posix)
2767 @item Emacs-style regular expressions (module Re_emacs)
2768 @item Shell-style file globbing (module Re_glob)
2769 @item Compatibility layer for OCaml's built-in Str module (module Re_str)
2770 @end enumerate")
2771 (license license:expat)))
2772
2773 (define-public ocaml-ocplib-endian
2774 (package
2775 (name "ocaml-ocplib-endian")
2776 (version "1.0")
2777 (source (origin
2778 (method git-fetch)
2779 (uri (git-reference
2780 (url "https://github.com/OCamlPro/ocplib-endian/")
2781 (commit version)))
2782 (sha256
2783 (base32
2784 "0s1ld3kavz892b8awyxyg1mr98h2g61gy9ci5v6yb49bsii6wicw"))
2785 (file-name (git-file-name name version))))
2786 (build-system ocaml-build-system)
2787 (native-inputs
2788 `(("cppo" ,ocaml-cppo)
2789 ("ocamlbuild" ,ocamlbuild)))
2790 (home-page "https://github.com/OCamlPro/ocplib-endian")
2791 (synopsis "Optimised functions to read and write int16/32/64 from strings
2792 and bigarrays")
2793 (description "Optimised functions to read and write int16/32/64 from strings
2794 and bigarrays, based on new primitives added in version 4.01. It works on
2795 strings, bytes and bigstring (Bigarrys of chars), and provides submodules for
2796 big- and little-endian, with their unsafe counter-parts.")
2797 (license license:lgpl2.1)))
2798
2799 (define-public ocaml-cstruct
2800 (package
2801 (name "ocaml-cstruct")
2802 (version "4.0.0")
2803 (source (origin
2804 (method git-fetch)
2805 (uri (git-reference
2806 (url "https://github.com/mirage/ocaml-cstruct")
2807 (commit (string-append "v" version))))
2808 (file-name (git-file-name name version))
2809 (sha256
2810 (base32
2811 "0m4bz0digcsc8l2msfikwcbi1y371kccx6xnkwrz212mf5mp98bv"))))
2812 (build-system dune-build-system)
2813 (arguments
2814 `(#:package "cstruct"
2815 #:test-target "."))
2816 (native-inputs
2817 `(("ocaml-alcotest" ,ocaml-alcotest)))
2818 (home-page "https://github.com/mirage/ocaml-cstruct")
2819 (synopsis "Access C structures via a camlp4 extension")
2820 (description "Cstruct is a library and syntax extension to make it easier
2821 to access C-like structures directly from OCaml. It supports both reading and
2822 writing to these structures, and they are accessed via the Bigarray module.")
2823 (license license:isc)))
2824
2825 (define-public ocaml-hex
2826 (package
2827 (name "ocaml-hex")
2828 (version "1.4.0")
2829 (source (origin
2830 (method git-fetch)
2831 (uri (git-reference
2832 (url "https://github.com/mirage/ocaml-hex")
2833 (commit (string-append "v" version))))
2834 (file-name (git-file-name name version))
2835 (sha256
2836 (base32
2837 "0c8nhibcwy0ykzca4jn3gqb8ylq21ff88y82gl60wyzijr64rn0q"))))
2838 (build-system dune-build-system)
2839 (arguments
2840 `(#:test-target "."))
2841 (propagated-inputs
2842 `(("ocaml-bigarray-compat" ,ocaml-bigarray-compat)
2843 ("cstruct" ,ocaml-cstruct)))
2844 (home-page "https://github.com/mirage/ocaml-hex/")
2845 (synopsis "Minimal library providing hexadecimal converters")
2846 (description "Hex is a minimal library providing hexadecimal converters.")
2847 (license license:isc)))
2848
2849 (define-public ocaml4.07-ezjsonm
2850 (package
2851 (name "ocaml4.07-ezjsonm")
2852 (version "1.1.0")
2853 (source
2854 (origin
2855 (method git-fetch)
2856 (uri (git-reference
2857 (url "https://github.com/mirage/ezjsonm")
2858 (commit (string-append "v" version))))
2859 (file-name (git-file-name name version))
2860 (sha256
2861 (base32 "064j9pzy01p3dv947khqyn7fkjbs3jmrqsg8limb4abnlaqxxs2s"))))
2862 (build-system dune-build-system)
2863 (arguments
2864 `(#:package "ezjsonm"
2865 #:test-target "."
2866 #:ocaml ,ocaml-4.07
2867 #:findlib ,ocaml4.07-findlib
2868 #:dune ,ocaml4.07-dune))
2869 (native-inputs
2870 `(("ocaml-alcotest" ,(package-with-ocaml4.07 ocaml-alcotest))))
2871 (propagated-inputs
2872 `(("ocaml-hex" ,(package-with-ocaml4.07 ocaml-hex))
2873 ("ocaml-jsonm" ,(package-with-ocaml4.07 ocaml-jsonm))
2874 ("ocaml-sexplib" ,ocaml4.07-sexplib)))
2875 (home-page "https://github.com/mirage/ezjsonm/")
2876 (synopsis "Read and write JSON data")
2877 (description "Ezjsonm provides more convenient (but far less flexible) input
2878 and output functions that go to and from [string] values than jsonm. This avoids
2879 the need to write signal code, which is useful for quick scripts that manipulate
2880 JSON.")
2881 (license license:isc)))
2882
2883 (define-public ocaml4.07-uri
2884 (package
2885 (name "ocaml4.07-uri")
2886 (version "2.2.0")
2887 (source
2888 (origin
2889 (method git-fetch)
2890 (uri (git-reference
2891 (url "https://github.com/mirage/ocaml-uri")
2892 (commit (string-append "v" version))))
2893 (file-name (git-file-name name version))
2894 (sha256
2895 (base32 "1ppbav41mszpjcl0zi3fyg958cxyfs57i7kvha4ds9ydn89bjmrh"))))
2896 (build-system dune-build-system)
2897 (arguments
2898 `(#:test-target "."
2899 #:phases
2900 (modify-phases %standard-phases
2901 (add-before 'build 'update-deprecated
2902 (lambda _
2903 (substitute* "lib/uri.ml"
2904 (("Re.get") "Re.Group.get")))))
2905 #:ocaml ,ocaml-4.07
2906 #:findlib ,ocaml4.07-findlib
2907 #:dune ,ocaml4.07-dune))
2908 (native-inputs
2909 `(("ocaml-ounit" ,(package-with-ocaml4.07 ocaml-ounit))
2910 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)))
2911 (propagated-inputs
2912 `(("ocaml-re" ,(package-with-ocaml4.07 ocaml-re))
2913 ("ocaml-sexplib0" ,ocaml4.07-sexplib0)
2914 ("ocaml-stringext" ,(package-with-ocaml4.07 ocaml-stringext))))
2915 (home-page "https://github.com/mirage/ocaml-uri")
2916 (synopsis "RFC3986 URI/URL parsing library")
2917 (description "OCaml-uri is a library for parsing URI/URL in the RFC3986 format.")
2918 (license license:isc)))
2919
2920 (define-public ocaml-easy-format
2921 (package
2922 (name "ocaml-easy-format")
2923 (version "1.3.2")
2924 (source (origin
2925 (method git-fetch)
2926 (uri (git-reference
2927 (url "https://github.com/mjambon/easy-format")
2928 (commit version)))
2929 (file-name (git-file-name name version))
2930 (sha256
2931 (base32
2932 "1fc95q2ypck6m6rv3kiawwilh5ac93v2hcp823mj608d5kj79xkb"))))
2933 (build-system dune-build-system)
2934 (arguments
2935 `(#:package "easy-format"
2936 #:phases
2937 (modify-phases %standard-phases
2938 (add-before 'build 'make-writable
2939 (lambda _
2940 (for-each
2941 (lambda (file)
2942 (chmod file #o644))
2943 (find-files "." "."))
2944 #t)))))
2945 (home-page "https://github.com/mjambon/easy-format")
2946 (synopsis "Interface to the Format module")
2947 (description "Easy-format is a high-level and functional interface to the
2948 Format module of the OCaml standard library.")
2949 (license license:bsd-3)))
2950
2951 (define-public ocaml4.07-piqilib
2952 (package
2953 (name "ocaml4.07-piqilib")
2954 (version "0.6.15")
2955 (source
2956 (origin
2957 (method git-fetch)
2958 (uri (git-reference
2959 (url "https://github.com/alavrik/piqi")
2960 (commit (string-append "v" version))))
2961 (file-name (git-file-name name version))
2962 (sha256
2963 (base32 "0v04hs85xv6d4ysqxyv1dik34dx49yab9shpi4x7iv19qlzl7csb"))))
2964 (build-system ocaml-build-system)
2965 (arguments
2966 `(#:phases
2967 (modify-phases %standard-phases
2968 (add-before 'configure 'fix-ocamlpath
2969 (lambda _
2970 (substitute* '("Makefile" "make/Makefile.ocaml")
2971 (("OCAMLPATH := ") "OCAMLPATH := $(OCAMLPATH):"))
2972 #t))
2973 (replace 'configure
2974 (lambda* (#:key outputs #:allow-other-keys)
2975 (let ((out (assoc-ref outputs "out")))
2976 (substitute* "make/OCamlMakefile"
2977 (("/bin/sh") (which "bash")))
2978 (invoke "./configure" "--prefix" out "--ocaml-libdir"
2979 (string-append out "/lib/ocaml/site-lib")))
2980 #t))
2981 (add-after 'build 'build-ocaml
2982 (lambda* (#:key outputs #:allow-other-keys)
2983 (invoke "make" "ocaml")
2984 #t))
2985 (add-after 'install 'install-ocaml
2986 (lambda* (#:key outputs #:allow-other-keys)
2987 (invoke "make" "ocaml-install")
2988 #t))
2989 (add-after 'install-ocaml 'link-stubs
2990 (lambda* (#:key outputs #:allow-other-keys)
2991 (let* ((out (assoc-ref outputs "out"))
2992 (stubs (string-append out "/lib/ocaml/site-lib/stubslibs"))
2993 (lib (string-append out "/lib/ocaml/site-lib/piqilib")))
2994 (mkdir-p stubs)
2995 (symlink (string-append lib "/dllpiqilib_stubs.so")
2996 (string-append stubs "/dllpiqilib_stubs.so"))
2997 #t))))
2998 #:ocaml ,ocaml-4.07
2999 #:findlib ,ocaml4.07-findlib))
3000 (native-inputs
3001 `(("which" ,which)))
3002 (propagated-inputs
3003 `(("ocaml-xmlm" ,(package-with-ocaml4.07 ocaml-xmlm))
3004 ("ocaml-sedlex" ,ocaml4.07-sedlex)
3005 ("ocaml-easy-format" ,(package-with-ocaml4.07 ocaml-easy-format))
3006 ("ocaml-base64" ,(package-with-ocaml4.07 ocaml-base64))))
3007 (home-page "http://piqi.org")
3008 (synopsis "Data serialization and conversion library")
3009 (description "Piqilib is the common library used by the piqi command-line
3010 tool and piqi-ocaml.")
3011 (license license:asl2.0)))
3012
3013 (define-public ocaml-uuidm
3014 (package
3015 (name "ocaml-uuidm")
3016 (version "0.9.6")
3017 (source (origin
3018 (method url-fetch)
3019 (uri (string-append "http://erratique.ch/software/uuidm/"
3020 "releases/uuidm-" version ".tbz"))
3021 (sha256
3022 (base32
3023 "0hz4fdx0x16k0pw9995vkz5d1hmzz6b16wck9li399rcbfnv5jlc"))))
3024 (build-system ocaml-build-system)
3025 (arguments
3026 `(#:build-flags
3027 (list "build" "--tests" "true" "--with-cmdliner" "true")
3028 #:phases
3029 (modify-phases %standard-phases
3030 (delete 'configure))))
3031 (native-inputs
3032 `(("ocamlbuild" ,ocamlbuild)
3033 ("opam" ,opam)))
3034 (propagated-inputs
3035 `(("cmdliner" ,ocaml-cmdliner)
3036 ("topkg" ,ocaml-topkg)))
3037 (home-page "http://erratique.ch/software/uuidm")
3038 (synopsis "Universally unique identifiers for OCaml")
3039 (description "Uuidm is an OCaml module implementing 128 bits universally
3040 unique identifiers (UUIDs) version 3, 5 (named based with MD5, SHA-1 hashing)
3041 and 4 (random based) according to RFC 4122.")
3042 (license license:isc)))
3043
3044 (define-public ocaml-graph
3045 (package
3046 (name "ocaml-graph")
3047 (version "1.8.8")
3048 (source (origin
3049 (method url-fetch)
3050 (uri (string-append "http://ocamlgraph.lri.fr/download/"
3051 "ocamlgraph-" version ".tar.gz"))
3052 (sha256
3053 (base32
3054 "0m9g16wrrr86gw4fz2fazrh8nkqms0n863w7ndcvrmyafgxvxsnr"))))
3055 (build-system ocaml-build-system)
3056 (arguments
3057 `(#:install-target "install-findlib"
3058 #:tests? #f
3059 #:phases
3060 (modify-phases %standard-phases
3061 (add-before 'configure 'set-shell
3062 (lambda* (#:key inputs #:allow-other-keys)
3063 (setenv "CONFIG_SHELL" (string-append (assoc-ref inputs "bash")
3064 "/bin/sh")))))))
3065 (inputs `(("lablgtk" ,lablgtk)))
3066 (properties `((upstream-name . "ocamlgraph")))
3067 (home-page "http://ocamlgraph.lri.fr/")
3068 (synopsis "Graph library for OCaml")
3069 (description "OCamlgraph is a generic graph library for OCaml.")
3070 (license license:lgpl2.1)))
3071
3072 (define-public ocaml4.07-piqi
3073 (package
3074 (name "ocaml4.07-piqi")
3075 (version "0.7.7")
3076 (source (origin
3077 (method git-fetch)
3078 (uri (git-reference
3079 (url "https://github.com/alavrik/piqi-ocaml")
3080 (commit (string-append "v" version))))
3081 (file-name (git-file-name name version))
3082 (sha256
3083 (base32
3084 "1913jpsb8mvqi8609j4g4sm5jhg50dq0xqxgy8nmvknfryyc89nm"))))
3085 (build-system ocaml-build-system)
3086 (arguments
3087 `(#:make-flags
3088 (list (string-append "DESTDIR=" (assoc-ref %outputs "out"))
3089 (string-append "SHELL=" (assoc-ref %build-inputs "bash")
3090 "/bin/sh"))
3091 #:phases
3092 (modify-phases %standard-phases
3093 (add-after 'unpack 'make-files-writable
3094 (lambda _
3095 (for-each make-file-writable (find-files "."))
3096 #t))
3097 (delete 'configure))
3098 #:ocaml ,ocaml-4.07
3099 #:findlib ,ocaml4.07-findlib))
3100 (native-inputs
3101 `(("which" ,which)
3102 ("protobuf" ,protobuf))) ; for tests
3103 (propagated-inputs
3104 `(("ocaml-num" ,(package-with-ocaml4.07 ocaml-num))
3105 ("ocaml-piqilib" ,ocaml4.07-piqilib)
3106 ("ocaml-stdlib-shims" ,(package-with-ocaml4.07 ocaml-stdlib-shims))))
3107 (home-page "https://github.com/alavrik/piqi-ocaml")
3108 (synopsis "Protocol serialization system for OCaml")
3109 (description "Piqi is a multi-format data serialization system for OCaml.
3110 It provides a uniform interface for serializing OCaml data structures to JSON,
3111 XML and Protocol Buffers formats.")
3112 (license license:asl2.0)))
3113
3114 (define-public bap
3115 (package
3116 (name "bap")
3117 (version "2.0.0")
3118 (home-page "https://github.com/BinaryAnalysisPlatform/bap")
3119 (source (origin
3120 (method git-fetch)
3121 (uri (git-reference
3122 (url home-page)
3123 (commit (string-append "v" version))))
3124 (file-name (git-file-name name version))
3125 (sha256
3126 (base32
3127 "0lb9xkfp67wjjqr75p6krivmjra7l5673236v9ny4gp0xi0755bk"))))
3128 (build-system ocaml-build-system)
3129 (native-inputs
3130 `(("ocaml-oasis" ,(package-with-ocaml4.07 ocaml-oasis))
3131 ("clang" ,clang-3.8)
3132 ("ocaml-ounit" ,(package-with-ocaml4.07 ocaml-ounit))))
3133 (propagated-inputs
3134 `(("camlzip" ,(package-with-ocaml4.07 camlzip))
3135 ("ocaml-bitstring" ,(package-with-ocaml4.07 ocaml-bitstring))
3136 ("ocaml-cmdliner" ,(package-with-ocaml4.07 ocaml-cmdliner))
3137 ("ocaml-core-kernel" ,ocaml4.07-core-kernel)
3138 ("ocaml-ezjsonm" ,ocaml4.07-ezjsonm)
3139 ("ocaml-fileutils" ,(package-with-ocaml4.07 ocaml-fileutils))
3140 ("ocaml-frontc" ,(package-with-ocaml4.07 ocaml-frontc))
3141 ("ocaml-graph" ,(package-with-ocaml4.07 ocaml-graph))
3142 ("ocaml-ocurl" ,(package-with-ocaml4.07 ocaml-ocurl))
3143 ("ocaml-piqi" ,ocaml4.07-piqi)
3144 ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane)
3145 ("ocaml-utop" ,ocaml4.07-utop)
3146 ("ocaml-uuidm" ,(package-with-ocaml4.07 ocaml-uuidm))
3147 ("ocaml-uri" ,ocaml4.07-uri)
3148 ("ocaml-zarith" ,(package-with-ocaml4.07 ocaml-zarith))))
3149 (inputs
3150 `(("gmp" ,gmp)
3151 ("llvm" ,llvm-3.8)
3152 ("ncurses" ,ncurses)))
3153 (arguments
3154 `(#:use-make? #t
3155 #:phases
3156 (modify-phases %standard-phases
3157 (add-before 'configure 'fix-ncurses
3158 (lambda _
3159 (substitute* "oasis/llvm"
3160 (("-lcurses") "-lncurses"))
3161 #t))
3162 (replace 'configure
3163 (lambda* (#:key outputs inputs #:allow-other-keys)
3164 ;; add write for user, to prevent a failure in the install phase
3165 (for-each
3166 (lambda (file)
3167 (let ((stat (stat file)))
3168 (chmod file (+ #o200 (stat:mode stat)))))
3169 (find-files "." "."))
3170 (invoke "./configure" "--prefix"
3171 (assoc-ref outputs "out")
3172 "--libdir"
3173 (string-append
3174 (assoc-ref outputs "out")
3175 "/lib/ocaml/site-lib")
3176 "--with-llvm-version=3.8"
3177 "--with-llvm-config=llvm-config"
3178 "--enable-everything"))))
3179 #:ocaml ,ocaml-4.07
3180 #:findlib ,ocaml4.07-findlib))
3181 (synopsis "Binary Analysis Platform")
3182 (description "Binary Analysis Platform is a framework for writing program
3183 analysis tools, that target binary files. The framework consists of a plethora
3184 of libraries, plugins, and frontends. The libraries provide code reusability,
3185 the plugins facilitate extensibility, and the frontends serve as entry points.")
3186 (license license:expat)))
3187
3188 (define-public ocaml-camomile
3189 (package
3190 (name "ocaml-camomile")
3191 (version "1.0.2")
3192 (home-page "https://github.com/yoriyuki/Camomile")
3193 (source (origin
3194 (method url-fetch)
3195 (uri (string-append home-page "/releases/download/" version
3196 "/camomile-" version ".tbz"))
3197 (sha256
3198 (base32
3199 "0chn7ldqb3wyf95yhmsxxq65cif56smgz1mhhc7m0dpwmyq1k97h"))))
3200 (build-system dune-build-system)
3201 (arguments
3202 `(#:build-flags (list "--profile" "release")
3203 #:test-target "camomile-test"
3204 #:tests? #f; Tests fail, see https://github.com/yoriyuki/Camomile/issues/82
3205 #:phases
3206 (modify-phases %standard-phases
3207 (add-before 'build 'fix-usr-share
3208 (lambda* (#:key outputs #:allow-other-keys)
3209 (substitute* '("Camomile/dune" "configure.ml")
3210 (("/usr/share") (string-append (assoc-ref outputs "out") "/share")))
3211 #t)))))
3212 (synopsis "Comprehensive Unicode library")
3213 (description "Camomile is a Unicode library for OCaml. Camomile provides
3214 Unicode character type, UTF-8, UTF-16, UTF-32 strings, conversion to/from about
3215 200 encodings, collation and locale-sensitive case mappings, and more. The
3216 library is currently designed for Unicode Standard 3.2.")
3217 ;; with an exception for linked libraries to use a different license
3218 (license license:lgpl2.0+)))
3219
3220 (define-public ocaml4.07-charinfo-width
3221 (package
3222 (name "ocaml4.07-charinfo-width")
3223 (version "1.1.0")
3224 (source (origin
3225 (method url-fetch)
3226 (uri (string-append "https://bitbucket.org/zandoye/charinfo_width"
3227 "/get/" version ".tar.gz"))
3228 (file-name (string-append name "-" version ".tar.gz"))
3229 (sha256
3230 (base32
3231 "00bv4p1yqs8y0z4z07wd9w9yyv669dikp9b04dcjbwpiy2wy0086"))))
3232 (build-system dune-build-system)
3233 (arguments
3234 `(#:ocaml ,ocaml-4.07
3235 #:findlib ,ocaml4.07-findlib
3236 #:dune ,ocaml4.07-dune))
3237 (propagated-inputs
3238 `(("ocaml-result" ,(package-with-ocaml4.07 ocaml-result))
3239 ("ocaml-camomile" ,(package-with-ocaml4.07 ocaml-camomile))))
3240 (native-inputs
3241 `(("ocaml-ppx-expect" ,ocaml4.07-ppx-expect)))
3242 (properties
3243 `((upstream-name . "charInfo_width")))
3244 (home-page "https://bitbucket.org/zandoye/charinfo_width/")
3245 (synopsis "Determine column width for a character")
3246 (description "This module is implements purely in OCaml a character width
3247 function that follows the prototype of POSIX's wcwidth.")
3248 (license license:expat)))
3249
3250 (define-public ocaml4.07-zed
3251 (package
3252 (name "ocaml4.07-zed")
3253 (version "2.0.3")
3254 (source
3255 (origin
3256 (method git-fetch)
3257 (uri (git-reference
3258 (url "https://github.com/diml/zed")
3259 (commit version)))
3260 (file-name (git-file-name name version))
3261 (sha256
3262 (base32 "0pa9awinqr0plp4b2az78dwpvh01pwaljnn5ydg8mc6hi7rmir55"))))
3263 (build-system dune-build-system)
3264 (arguments
3265 `(#:test-target "."
3266 #:ocaml ,ocaml-4.07
3267 #:findlib ,ocaml4.07-findlib
3268 #:dune ,ocaml4.07-dune))
3269 (propagated-inputs
3270 `(("ocaml-camomile" ,(package-with-ocaml4.07 ocaml-camomile))
3271 ("ocaml-charinfo-width" ,ocaml4.07-charinfo-width)
3272 ("ocaml-react" ,(package-with-ocaml4.07 ocaml-react))))
3273 (home-page "https://github.com/diml/zed")
3274 (synopsis "Abstract engine for text editing in OCaml")
3275 (description "Zed is an abstract engine for text edition. It can be used
3276 to write text editors, edition widgets, readlines, etc. You just have to
3277 connect an engine to your inputs and rendering functions to get an editor.")
3278 (license license:bsd-3)))
3279
3280 (define-public ocaml4.07-lambda-term
3281 (package
3282 (name "ocaml4.07-lambda-term")
3283 (version "2.0.2")
3284 (source
3285 (origin
3286 (method git-fetch)
3287 (uri (git-reference
3288 (url "https://github.com/diml/lambda-term")
3289 (commit version)))
3290 (file-name (git-file-name name version))
3291 (sha256
3292 (base32 "0zcjy6fvf0d3i2ssz96asl889n3r6bplyzk7xvb2s3dkxbgcisyy"))))
3293 (build-system dune-build-system)
3294 (arguments
3295 `(#:build-flags (list "--profile" "release")
3296 #:tests? #f
3297 #:ocaml ,ocaml-4.07
3298 #:findlib ,ocaml4.07-findlib
3299 #:dune ,ocaml4.07-dune))
3300 (propagated-inputs
3301 `(("ocaml-lwt" ,(package-with-ocaml4.07 ocaml-lwt))
3302 ("ocaml-lwt-log" ,(package-with-ocaml4.07 ocaml-lwt-log))
3303 ("ocaml-lwt-react" ,(package-with-ocaml4.07 ocaml-lwt-react))
3304 ("ocaml-zed" ,ocaml4.07-zed)))
3305 (inputs
3306 `(("libev" ,libev)))
3307 (home-page "https://github.com/diml/lambda-term")
3308 (synopsis "Terminal manipulation library for OCaml")
3309 (description "Lambda-Term is a cross-platform library for manipulating the
3310 terminal. It provides an abstraction for keys, mouse events, colors, as well as
3311 a set of widgets to write curses-like applications. The main objective of
3312 Lambda-Term is to provide a higher level functional interface to terminal
3313 manipulation than, for example, ncurses, by providing a native OCaml interface
3314 instead of bindings to a C library.")
3315 (license license:bsd-3)))
3316
3317 (define-public ocaml4.07-utop
3318 (package
3319 (name "ocaml4.07-utop")
3320 (version "2.4.3")
3321 (source
3322 (origin
3323 (method git-fetch)
3324 (uri (git-reference
3325 (url "https://github.com/ocaml-community/utop")
3326 (commit version)))
3327 (file-name (git-file-name name version))
3328 (sha256
3329 (base32 "1bl4943qpi3qy152dbdm5glhx19zsiylmn4rcxi8l66g58hikyjp"))))
3330 (build-system dune-build-system)
3331 (arguments
3332 `(#:test-target "."
3333 #:ocaml ,ocaml-4.07
3334 #:findlib ,ocaml4.07-findlib
3335 #:dune ,ocaml4.07-dune))
3336 (native-inputs
3337 `(("cppo" ,(package-with-ocaml4.07 ocaml-cppo))))
3338 (propagated-inputs
3339 `(("lambda-term" ,ocaml4.07-lambda-term)
3340 ("lwt" ,(package-with-ocaml4.07 ocaml-lwt))
3341 ("react" ,(package-with-ocaml4.07 ocaml-react))
3342 ("camomile" ,(package-with-ocaml4.07 ocaml-camomile))
3343 ("zed" ,ocaml4.07-zed)))
3344 (home-page "https://github.com/ocaml-community/utop")
3345 (synopsis "Improved interface to the OCaml toplevel")
3346 (description "UTop is an improved toplevel for OCaml. It can run in a
3347 terminal or in Emacs. It supports line editing, history, real-time and context
3348 sensitive completion, colors, and more.")
3349 (license license:bsd-3)))
3350
3351 (define-public ocaml-integers
3352 (package
3353 (name "ocaml-integers")
3354 (version "0.3.0")
3355 (home-page "https://github.com/ocamllabs/ocaml-integers")
3356 (source (origin
3357 (method url-fetch)
3358 (uri (string-append home-page
3359 "/releases/download/v0.2.2/integers-"
3360 version ".tbz"))
3361 (file-name (string-append name "-" version ".tbz"))
3362 (sha256
3363 (base32
3364 "08b1ljw88ny3l0mdq6xmffjk8anfc77igryva5jz1p6f4f746ywk"))))
3365 (build-system ocaml-build-system)
3366 (arguments
3367 `(#:tests? #f; no tests
3368 #:build-flags (list "build")
3369 #:phases
3370 (modify-phases %standard-phases
3371 (delete 'configure))))
3372 (native-inputs
3373 `(("ocamlbuild" ,ocamlbuild)))
3374 (inputs
3375 `(("topkg" ,ocaml-topkg)
3376 ("opam" ,opam)))
3377 (synopsis "Various signed and unsigned integer types for OCaml")
3378 (description "The ocaml-integers library provides a number of 8-, 16-, 32-
3379 and 64-bit signed and unsigned integer types, together with aliases such as
3380 long and size_t whose sizes depend on the host platform.")
3381 (license license:expat)))
3382
3383 (define-public ocaml-ctypes
3384 (package
3385 (name "ocaml-ctypes")
3386 (version "0.14.0")
3387 (home-page "https://github.com/ocamllabs/ocaml-ctypes")
3388 (source (origin
3389 (method git-fetch)
3390 (uri (git-reference
3391 (url home-page)
3392 (commit version)))
3393 (file-name (git-file-name name version))
3394 (sha256
3395 (base32
3396 "1b2q3h63ngf4x9qp65qwapf2dg9q0mcdah6qjm2q0c7v2p5vysv9"))))
3397 (build-system ocaml-build-system)
3398 (arguments
3399 `(#:tests? #f; require an old lwt
3400 #:make-flags
3401 (list (string-append "INSTALL_HEADERS = $(wildcard $($(PROJECT).dir)/*.h)"))
3402 #:phases
3403 (modify-phases %standard-phases
3404 (add-after 'unpack 'make-writable
3405 (lambda _
3406 (for-each
3407 (lambda (file)
3408 (let ((stat (stat file)))
3409 (chmod file (+ #o200 (stat:mode stat)))))
3410 (find-files "." "."))
3411 #t))
3412 (delete 'configure))))
3413 (native-inputs
3414 `(("pkg-config" ,pkg-config)))
3415 (inputs
3416 `(("libffi" ,libffi)
3417 ("ounit" ,ocaml-ounit)
3418 ("integers" ,ocaml-integers)
3419 ("lwt" ,ocaml-lwt)
3420 ("topkg" ,ocaml-topkg)
3421 ("opam" ,opam)))
3422 (synopsis "Library for binding to C libraries using pure OCaml")
3423 (description "Ctypes is a library for binding to C libraries using pure
3424 OCaml. The primary aim is to make writing C extensions as straightforward as
3425 possible. The core of ctypes is a set of combinators for describing the
3426 structure of C types -- numeric types, arrays, pointers, structs, unions and
3427 functions. You can use these combinators to describe the types of the
3428 functions that you want to call, then bind directly to those functions -- all
3429 without writing or generating any C!")
3430 (license license:expat)))
3431
3432 (define-public ocaml-ocb-stubblr
3433 (package
3434 (name "ocaml-ocb-stubblr")
3435 (version "0.1.1")
3436 (home-page "https://github.com/pqwy/ocb-stubblr")
3437 (source (origin
3438 (method url-fetch)
3439 (uri (string-append
3440 home-page "/releases/download/v0.1.1/ocb-stubblr-"
3441 version ".tbz"))
3442 (file-name (string-append name "-" version ".tbz"))
3443 (sha256
3444 (base32
3445 "167b7x1j21mkviq8dbaa0nmk4rps2ilvzwx02igsc2706784z72f"))))
3446 (build-system ocaml-build-system)
3447 (arguments
3448 `(#:build-flags (list "build" "--tests" "true")
3449 #:phases
3450 (modify-phases %standard-phases
3451 (delete 'configure)
3452 (add-before 'build 'fix-for-guix
3453 (lambda _
3454 (substitute* "src/ocb_stubblr.ml"
3455 ;; Do not fail when opam is not present or initialized
3456 (("error_msgf \"error running opam\"") "\"\"")
3457 ;; Guix doesn't have cc, but it has gcc
3458 (("\"cc\"") "\"gcc\""))
3459 #t)))))
3460 (inputs
3461 `(("topkg" ,ocaml-topkg)
3462 ("opam" ,opam)))
3463 (native-inputs
3464 `(("astring" ,ocaml-astring)
3465 ("ocamlbuild" ,ocamlbuild)))
3466 (synopsis "OCamlbuild plugin for C stubs")
3467 (description "Ocb-stubblr is about ten lines of code that you need to
3468 repeat over, over, over and over again if you are using ocamlbuild to build
3469 OCaml projects that contain C stubs.")
3470 (license license:isc)))
3471
3472 (define-public ocaml-tsdl
3473 (package
3474 (name "ocaml-tsdl")
3475 (version "0.9.7")
3476 (home-page "https://erratique.ch/software/tsdl")
3477 (source (origin
3478 (method url-fetch)
3479 (uri (string-append home-page "/releases/tsdl-"
3480 version ".tbz"))
3481 (file-name (string-append name "-" version ".tar.gz"))
3482 (sha256
3483 (base32
3484 "1zwv0ixkigh1gzk5n49rwvz2f2m62jdkkqg40j7dclg4gri7691f"))))
3485 (build-system ocaml-build-system)
3486 (arguments
3487 `(#:build-flags '("build")
3488 #:tests? #f; tests require a display device
3489 #:phases
3490 (modify-phases %standard-phases
3491 (delete 'configure))))
3492 (native-inputs
3493 `(("ocamlbuild" ,ocamlbuild)
3494 ("ocaml-astring" ,ocaml-astring)
3495 ("opam" ,opam)
3496 ("pkg-config" ,pkg-config)))
3497 (inputs
3498 `(("topkg" ,ocaml-topkg)
3499 ("sdl2" ,sdl2)
3500 ("integers" ,ocaml-integers)
3501 ("ctypes" ,ocaml-ctypes)))
3502 (synopsis "Thin bindings to SDL for OCaml")
3503 (description "Tsdl is an OCaml library providing thin bindings to the
3504 cross-platform SDL C library.")
3505 (license license:isc)))
3506
3507 (define-public dedukti
3508 (package
3509 (name "dedukti")
3510 (version "2.6.0")
3511 (home-page "https://deducteam.github.io/")
3512 (source
3513 (origin
3514 (method git-fetch)
3515 (uri (git-reference
3516 (url "https://github.com/deducteam/dedukti")
3517 (commit (string-append "v" version))))
3518 (file-name (git-file-name name version))
3519 (sha256
3520 (base32
3521 "0frl3diff033i4fmq304b8wbsdnc9mvlhmwd7a3zd699ng2lzbxb"))))
3522 (inputs
3523 `(("menhir" ,ocaml-menhir)))
3524 (native-inputs
3525 `(("ocamlbuild" ,ocamlbuild)))
3526 (build-system ocaml-build-system)
3527 (arguments
3528 `(#:phases
3529 (modify-phases %standard-phases
3530 (delete 'configure)
3531 (replace 'build
3532 (lambda _
3533 (invoke "make")
3534 #t))
3535 (replace 'check
3536 (lambda _
3537 (invoke "make" "tests")
3538 #t))
3539 (add-before 'install 'set-binpath
3540 ;; Change binary path in the makefile
3541 (lambda _
3542 (let ((out (assoc-ref %outputs "out")))
3543 (substitute* "GNUmakefile"
3544 (("BINDIR = (.*)$")
3545 (string-append "BINDIR = " out "/bin"))))
3546 #t))
3547 (replace 'install
3548 (lambda _
3549 (invoke "make" "install")
3550 #t)))))
3551 (synopsis "Proof-checker for the λΠ-calculus modulo theory, an extension of
3552 the λ-calculus")
3553 (description "Dedukti is a proof-checker for the λΠ-calculus modulo
3554 theory. The λΠ-calculus is an extension of the simply typed λ-calculus with
3555 dependent types. The λΠ-calculus modulo theory is itself an extension of the
3556 λΠ-calculus where the context contains variable declaration as well as rewrite
3557 rules. This system is not designed to develop proofs, but to check proofs
3558 developed in other systems. In particular, it enjoys a minimalistic syntax.")
3559 (license license:cecill-c)))
3560
3561 (define-public emacs-dedukti-mode
3562 (let ((commit "d7c3505a1046187de3c3aeb144455078d514594e"))
3563 (package
3564 (name "emacs-dedukti-mode")
3565 (version (git-version "0" "0" commit))
3566 (home-page "https://github.com/rafoo/dedukti-mode")
3567 (source (origin
3568 (method git-fetch)
3569 (uri (git-reference
3570 (url home-page)
3571 (commit commit)))
3572 (sha256
3573 (base32
3574 "1842wikq24c8rg0ac84vb1qby9ng1nssxswyyni4kq85lng5lcrp"))
3575 (file-name (git-file-name name version))))
3576 (inputs
3577 `(("dedukti" ,dedukti)))
3578 (build-system emacs-build-system)
3579 (arguments
3580 '(#:phases
3581 (modify-phases %standard-phases
3582 (add-before 'install 'patch-dkpath
3583 (lambda _
3584 (let ((dkcheck-path (which "dkcheck")))
3585 (substitute* "dedukti-mode.el"
3586 (("dedukti-path \"(.*)\"")
3587 (string-append "dedukti-path \"" dkcheck-path "\"")))))))))
3588 (synopsis "Emacs major mode for Dedukti files")
3589 (description "This package provides an Emacs major mode for editing
3590 Dedukti files.")
3591 (license license:cecill-b))))
3592
3593 (define-public emacs-flycheck-dedukti
3594 (let ((commit "3dbff5646355f39d57a3ec514f560a6b0082a1cd"))
3595 (package
3596 (name "emacs-flycheck-dedukti")
3597 (version (git-version "0" "0" commit))
3598 (home-page "https://github.com/rafoo/flycheck-dedukti")
3599 (source (origin
3600 (method git-fetch)
3601 (uri (git-reference
3602 (url home-page)
3603 (commit commit)))
3604 (sha256
3605 (base32
3606 "1ffpxnwl3wx244n44mbw81g00nhnykd0lnid29f4aw1av7w6nw8l"))
3607 (file-name (git-file-name name version))))
3608 (build-system emacs-build-system)
3609 (inputs
3610 `(("dedukti-mode" ,emacs-dedukti-mode)
3611 ("flycheck-mode" ,emacs-flycheck)))
3612 (synopsis "Flycheck integration for the dedukti language")
3613 (description "This package provides a frontend for Flycheck to perform
3614 syntax checking on dedukti files.")
3615 (license license:cecill-b))))
3616
3617 (define-public ocaml4.07-ppx-inline-test
3618 (package
3619 (name "ocaml4.07-ppx-inline-test")
3620 (version "0.12.0")
3621 (home-page "https://github.com/janestreet/ppx_inline_test")
3622 (source
3623 (origin
3624 (method git-fetch)
3625 (uri (git-reference
3626 (url (string-append home-page ".git"))
3627 (commit (string-append "v" version))))
3628 (file-name (git-file-name name version))
3629 (sha256
3630 (base32
3631 "0nyz411zim94pzbxm2l2v2l9jishcxwvxhh142792g2s18r4vn50"))))
3632 (build-system dune-build-system)
3633 (arguments
3634 ;see home page README for further information
3635 `(#:tests? #f
3636 #:ocaml ,ocaml-4.07
3637 #:findlib ,ocaml4.07-findlib
3638 #:dune ,ocaml4.07-dune))
3639 (inputs
3640 `(("ocaml-base" ,ocaml4.07-base)
3641 ("ocaml-migrate-parsetree"
3642 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
3643 ("ocaml-compiler-libs" ,ocaml4.07-compiler-libs)
3644 ("ocaml-sexplib0" ,ocaml4.07-sexplib0)
3645 ("ocaml-stdio" ,ocaml4.07-stdio)
3646 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
3647 (properties `((upstream-name . "ppx_inline_test")))
3648 (synopsis "Syntax extension for writing in-line tests in ocaml code")
3649 (description "This package contains a syntax extension for writing
3650 in-line tests in ocaml code. It is part of Jane Street's PPX rewriters
3651 collection.")
3652 (license license:expat)))
3653
3654 (define-public ocaml-bindlib
3655 (package
3656 (name "ocaml-bindlib")
3657 (version "5.0.1")
3658 (source
3659 (origin
3660 (method git-fetch)
3661 (uri (git-reference
3662 (url "https://github.com/rlepigre/ocaml-bindlib")
3663 (commit (string-append "ocaml-bindlib_" version))))
3664 (file-name (git-file-name name version))
3665 (sha256
3666 (base32
3667 "1f8kr81w8vsi4gv61xn1qbc6zrzkjp8l9ix0942vjh4gjxc74v75"))))
3668 (build-system ocaml-build-system)
3669 (arguments
3670 `(#:tests? #f ;no tests
3671 #:use-make? #t
3672 #:phases
3673 (modify-phases %standard-phases
3674 (delete 'configure)
3675 (replace 'build
3676 (lambda _
3677 (invoke "make")))
3678 (replace 'install
3679 (lambda _
3680 (invoke "make" "install"))))))
3681 (native-inputs
3682 `(("ocamlbuild" ,ocamlbuild)
3683 ("ocaml-findlib" ,ocaml-findlib)))
3684 (home-page "https://rlepigre.github.io/ocaml-bindlib/")
3685 (synopsis "OCaml Bindlib library for bound variables")
3686 (description "Bindlib is a library allowing the manipulation of data
3687 structures with bound variables. It is particularly useful when writing ASTs
3688 for programming languages, but also for manipulating terms of the λ-calculus
3689 or quantified formulas.")
3690 (license license:gpl3+)))
3691
3692 (define-public ocaml4.07-earley
3693 (package
3694 (name "ocaml4.07-earley")
3695 (version "2.0.0")
3696 (home-page "https://github.com/rlepigre/ocaml-earley")
3697 (source
3698 (origin
3699 (method git-fetch)
3700 (uri (git-reference
3701 (url (string-append home-page ".git"))
3702 (commit version)))
3703 (file-name (git-file-name name version))
3704 (sha256
3705 (base32
3706 "18k7bi7krc4bvqnhijz1q0pfr0nfahghfjifci8rh1q4i5zd0xz5"))))
3707 (build-system dune-build-system)
3708 (arguments
3709 `(#:test-target "."
3710 #:ocaml ,ocaml-4.07
3711 #:findlib ,ocaml4.07-findlib
3712 #:dune ,ocaml4.07-dune))
3713 (synopsis "Parsing library based on Earley Algorithm")
3714 (description "Earley is a parser combinator library base on Earley's
3715 algorithm. It is intended to be used in conjunction with an OCaml syntax
3716 extension which allows the definition of parsers inside the language. There
3717 is also support for writing OCaml syntax extensions in a camlp4 style.")
3718 (license license:cecill-b)))
3719
3720 (define-public ocaml-timed
3721 (package
3722 (name "ocaml-timed")
3723 (version "1.0")
3724 (home-page "https://github.com/rlepigre/ocaml-timed")
3725 (source (origin
3726 (method git-fetch)
3727 (uri (git-reference
3728 (url (string-append home-page ".git"))
3729 (commit (string-append name "_" version))))
3730 (sha256
3731 (base32
3732 "0hfxz710faxy5yk97bkfnw87r732jcxxhmjppwrbfdb6pd0wks96"))
3733 (file-name (git-file-name name version))))
3734 (build-system ocaml-build-system)
3735 (arguments
3736 '(#:phases
3737 (modify-phases %standard-phases
3738 (delete 'configure)
3739 (replace 'build
3740 (lambda _
3741 (invoke "make")))
3742 (replace 'install
3743 (lambda _
3744 (invoke "make" "install")))
3745 (replace 'check
3746 (lambda _
3747 (invoke "make" "tests"))))))
3748 (synopsis "Timed references for imperative state")
3749 (description "Timed references for imperative state. This module provides
3750 an alternative type for references (or mutable cells) supporting undo/redo
3751 operations. In particular, an abstract notion of time is used to capture the
3752 state of the references at any given point, so that it can be restored. Note
3753 that usual reference operations only have a constant time / memory overhead
3754 (compared to those of the standard library).
3755
3756 Moreover, we provide an alternative implementation based on the references
3757 of the standard library (Pervasives module). However, it is less efficient
3758 than the first one.")
3759 (license license:expat)))
3760
3761 (define-public ocaml-biniou
3762 (package
3763 (name "ocaml-biniou")
3764 (version "1.2.1")
3765 (home-page "https://github.com/mjambon/biniou")
3766 (source
3767 (origin
3768 (method git-fetch)
3769 (uri (git-reference
3770 (url (string-append home-page ".git"))
3771 (commit version)))
3772 (file-name (git-file-name name version))
3773 (sha256
3774 (base32
3775 "0x2kiy809n1j0yf32l7hj102y628jp5jdrkbi3z7ld8jq04h1790"))))
3776 (build-system dune-build-system)
3777 (arguments
3778 `(#:phases
3779 (modify-phases %standard-phases
3780 (add-before 'build 'make-writable
3781 (lambda _
3782 (for-each
3783 (lambda (file)
3784 (chmod file #o644))
3785 (find-files "." "."))
3786 #t)))))
3787 (inputs
3788 `(("ocaml-easy-format" ,ocaml-easy-format)))
3789 (native-inputs
3790 `(("which" ,which)))
3791 (synopsis "Data format designed for speed, safety, ease of use and backward
3792 compatibility")
3793 (description "Biniou (pronounced \"be new\" is a binary data format
3794 designed for speed, safety, ease of use and backward compatibility as
3795 protocols evolve. Biniou is vastly equivalent to JSON in terms of
3796 functionality but allows implementations several times faster (4 times faster
3797 than yojson), with 25-35% space savings.")
3798 (license license:bsd-3)))
3799
3800 (define-public ocaml-yojson
3801 (package
3802 (name "ocaml-yojson")
3803 (version "1.7.0")
3804 (home-page "https://github.com/ocaml-community/yojson")
3805 (source
3806 (origin
3807 (method git-fetch)
3808 (uri (git-reference
3809 (url (string-append home-page ".git"))
3810 (commit version)))
3811 (file-name (git-file-name name version))
3812 (sha256
3813 (base32
3814 "0zncsw8bgbkh1pfvfc7nh628hfj84lgx6jwhp9ashj3z1z0w3xjn"))))
3815 (build-system dune-build-system)
3816 (arguments
3817 `(#:test-target "."))
3818 (inputs
3819 `(("ocaml-biniou" ,ocaml-biniou)
3820 ("ocaml-easy-format" ,ocaml-easy-format)))
3821 (native-inputs
3822 `(("ocaml-alcotest" ,ocaml-alcotest)
3823 ("ocaml-cppo" ,ocaml-cppo)))
3824 (synopsis "Low-level JSON library for OCaml")
3825 (description "Yojson is an optimized parsing and printing library for the
3826 JSON format. It addresses a few shortcomings of json-wheel including 2x
3827 speedup, polymorphic variants and optional syntax for tuples and variants.
3828 @code{ydump} is a pretty printing command-line program provided with the
3829 yojson package. The program @code{atdgen} can be used to derive OCaml-JSON
3830 serializers and deserializers from type definitions.")
3831 (license license:bsd-3)))
3832
3833 (define-public ocaml-craml
3834 (package
3835 (name "ocaml-craml")
3836 (version "1.0.0")
3837 (home-page "https://github.com/realworldocaml/craml")
3838 (source
3839 (origin
3840 (method git-fetch)
3841 (uri (git-reference
3842 (url (string-append home-page ".git"))
3843 (commit version)))
3844 (file-name (git-file-name name version))
3845 (sha256
3846 (base32
3847 "197xjp4vmzdymf2ndinw271ihpf45h04mx8gqj8ypspxdr5fj1a5"))))
3848 (build-system dune-build-system)
3849 (arguments
3850 `(#:phases
3851 (modify-phases %standard-phases
3852 (add-before 'build 'upgrade
3853 (lambda _
3854 (invoke "dune" "upgrade")
3855 #t)))))
3856 (inputs
3857 `(("ocaml-fmt" ,ocaml-fmt)
3858 ("ocaml-astring" ,ocaml-astring)
3859 ("ocaml-logs" ,ocaml-logs)
3860 ("ocaml-cmdliner" ,ocaml-cmdliner)))
3861 (synopsis
3862 "CRAM-testing framework for testing command line applications")
3863 (description "CRAM is a is functional testing framework for command line
3864 applications. @code{craml} is freely inspired by the
3865 Mercurial's @code{https://www.selenic.com/blog/?p=663, unified test
3866 format}. @code{craml} is released as a single binary (called @code{craml}).")
3867 (license license:isc)))
3868
3869 (define-public ocaml4.07-merlin
3870 (package
3871 (name "ocaml4.07-merlin")
3872 (version "3.2.2")
3873 (home-page "https://ocaml.github.io/merlin/")
3874 (source
3875 (origin
3876 (method git-fetch)
3877 (uri (git-reference
3878 (url "https://github.com/ocaml/merlin")
3879 (commit (string-append "v" version))))
3880 (file-name (git-file-name name version))
3881 (sha256
3882 (base32
3883 "15ssgmwdxylbwhld9p1cq8x6kadxyhll5bfyf11dddj6cldna3hb"))))
3884 (build-system dune-build-system)
3885 (inputs
3886 `(("ocaml-biniou" ,(package-with-ocaml4.07 ocaml-biniou))
3887 ("ocaml-yojson" ,(package-with-ocaml4.07 ocaml-yojson))
3888 ("ocaml-easy-format" ,(package-with-ocaml4.07 ocaml-easy-format))))
3889 (native-inputs
3890 `(("ocaml-findlib" ,ocaml-findlib)))
3891 (arguments
3892 `(#:package "merlin"
3893 #:tests? #f ;; Errors in tests in version 3.2.2
3894 #:ocaml ,ocaml-4.07
3895 #:findlib ,ocaml4.07-findlib
3896 #:dune ,ocaml4.07-dune))
3897 (synopsis "Context sensitive completion for OCaml in Vim and Emacs")
3898 (description "Merlin is an editor service that provides modern IDE
3899 features for OCaml. Emacs and Vim support is provided out-of-the-box.
3900 External contributors added support for Visual Studio Code, Sublime Text and
3901 Atom.")
3902 (license license:expat)))
3903
3904 (define-public ocaml4.07-gsl
3905 (package
3906 (name "ocaml4.07-gsl")
3907 (version "1.24.0")
3908 (source
3909 (origin
3910 (method url-fetch)
3911 (uri
3912 (string-append
3913 "https://github.com/mmottl/gsl-ocaml/releases/download/"
3914 version "/gsl-" version ".tbz"))
3915 (sha256
3916 (base32
3917 "1l5zkkkg8sglsihrbf10ivq9s8xzl1y6ag89i4jqpnmi4m43fy34"))))
3918 (build-system dune-build-system)
3919 (arguments
3920 `(#:test-target "."
3921 #:phases
3922 (modify-phases %standard-phases
3923 (add-after 'unpack 'fix-gsl-directory
3924 (lambda* (#:key inputs #:allow-other-keys)
3925 (substitute* "src/config/discover.ml"
3926 (("/usr") (assoc-ref inputs "gsl")))
3927 #t)))
3928 #:ocaml ,ocaml-4.07
3929 #:findlib ,ocaml4.07-findlib
3930 #:dune ,ocaml4.07-dune))
3931 (inputs
3932 `(("gsl" ,gsl)))
3933 (propagated-inputs
3934 `(("ocaml-base" ,ocaml4.07-base)
3935 ("ocaml-stdio" ,ocaml4.07-stdio)))
3936 (home-page "https://mmottl.github.io/gsl-ocaml")
3937 (synopsis "Bindings to the GNU Scientific Library")
3938 (description
3939 "GSL-OCaml is an interface to the @dfn{GNU scientific library} (GSL) for
3940 the OCaml language.")
3941 (license license:gpl3+)))
3942
3943 (define-public ocaml4.07-gsl-1
3944 (package
3945 (inherit ocaml4.07-gsl)
3946 (version "1.19.3")
3947 (source (origin
3948 (method url-fetch)
3949 (uri (string-append "https://github.com/mmottl/gsl-ocaml"
3950 "/releases/download/v"
3951 version "/gsl-ocaml-" version ".tar.gz"))
3952 (sha256
3953 (base32
3954 "0nzp43hp8pbjqkrxnwp5lgjrabxayf61h18fjaydi0s5faq6f3xh"))))
3955 (build-system ocaml-build-system)
3956 (inputs
3957 `(("gsl" ,gsl)))
3958 (native-inputs
3959 `(("ocamlbuild" ,(package-with-ocaml4.07 ocamlbuild))))
3960 (arguments
3961 `(#:ocaml ,ocaml-4.07
3962 #:findlib ,ocaml4.07-findlib))
3963 (propagated-inputs '())))
3964
3965 (define-public cubicle
3966 (package
3967 (name "cubicle")
3968 (version "1.1.2")
3969 (source (origin
3970 (method url-fetch)
3971 (uri (string-append "http://cubicle.lri.fr/cubicle-"
3972 version ".tar.gz"))
3973 (sha256
3974 (base32
3975 "10kk80jdmpdvql88sdjsh7vqzlpaphd8vip2lp47aarxjkwjlz1q"))))
3976 (build-system gnu-build-system)
3977 (native-inputs
3978 `(("automake" ,automake)
3979 ("ocaml" ,ocaml)
3980 ("which" ,(@@ (gnu packages base) which))))
3981 (propagated-inputs
3982 `(("ocaml-num" ,ocaml-num)
3983 ("z3" ,z3)))
3984 (arguments
3985 `(#:configure-flags (list "--with-z3")
3986 #:make-flags (list "QUIET=")
3987 #:tests? #f
3988 #:phases
3989 (modify-phases %standard-phases
3990 (add-before 'configure 'configure-for-release
3991 (lambda _
3992 (substitute* "Makefile.in"
3993 (("SVNREV=") "#SVNREV="))
3994 #t))
3995 (add-before 'configure 'fix-/bin/sh
3996 (lambda _
3997 (substitute* "configure"
3998 (("-/bin/sh") (string-append "-" (which "sh"))))
3999 #t))
4000 (add-before 'configure 'fix-smt-z3wrapper.ml
4001 (lambda _
4002 (substitute* "Makefile.in"
4003 (("\\\\n") ""))
4004 #t))
4005 (add-before 'configure 'fix-ocaml-num
4006 (lambda* (#:key inputs #:allow-other-keys)
4007 (substitute* "Makefile.in"
4008 (("= \\$\\(FUNCTORYLIB\\)")
4009 (string-append "= -I "
4010 (assoc-ref inputs "ocaml-num")
4011 "/lib/ocaml/site-lib"
4012 " $(FUNCTORYLIB)")))
4013 #t)))))
4014 (home-page "http://cubicle.lri.fr/")
4015 (synopsis "Model checker for array-based systems")
4016 (description "Cubicle is a model checker for verifying safety properties
4017 of array-based systems. This is a syntactically restricted class of
4018 parametrized transition systems with states represented as arrays indexed by
4019 an arbitrary number of processes. Cache coherence protocols and mutual
4020 exclusion algorithms are typical examples of such systems.")
4021 (license license:asl2.0)))
4022
4023 (define-public ocaml4.07-sexplib0
4024 (package
4025 (name "ocaml4.07-sexplib0")
4026 (version "0.11.0")
4027 (home-page "https://github.com/janestreet/sexplib0")
4028 (source
4029 (origin
4030 (method git-fetch)
4031 (uri (git-reference
4032 (url (string-append home-page ".git"))
4033 (commit (string-append "v" version))))
4034 (file-name (git-file-name name version))
4035 (sha256
4036 (base32
4037 "07v3ggyss7xhfv14bjk1n87sr42iqwj4cgjiv2lcdfkqk49i2bmi"))))
4038 (build-system dune-build-system)
4039 (arguments
4040 `(#:tests? #f ;no tests
4041 #:ocaml ,ocaml-4.07
4042 #:findlib ,ocaml4.07-findlib
4043 #:dune ,ocaml4.07-dune))
4044 (synopsis "Library containing the definition of S-expressions and some
4045 base converters")
4046 (description "Part of Jane Street's Core library The Core suite of
4047 libraries is an industrial strength alternative to OCaml's standard library
4048 that was developed by Jane Street, the largest industrial user of OCaml.")
4049 (license license:expat)))
4050
4051 (define-public ocaml4.07-parsexp
4052 (package
4053 (name "ocaml4.07-parsexp")
4054 (version "0.11.0")
4055 (home-page "https://github.com/janestreet/parsexp")
4056 (source
4057 (origin
4058 (method git-fetch)
4059 (uri (git-reference
4060 (url (string-append home-page ".git"))
4061 (commit (string-append "v" version))))
4062 (file-name (git-file-name name version))
4063 (sha256
4064 (base32
4065 "1nyq23s5igd8cf3n4qxprjvhbmb6ighb3fy5mw7hxl0mdgsw5fvz"))))
4066 (build-system dune-build-system)
4067 (arguments
4068 `(#:ocaml ,ocaml-4.07
4069 #:findlib ,ocaml4.07-findlib
4070 #:dune ,ocaml4.07-dune))
4071 (inputs
4072 `(("ocaml-sexplib0" ,ocaml4.07-sexplib0)))
4073 (synopsis "S-expression parsing library")
4074 (description
4075 "This library provides generic parsers for parsing S-expressions from
4076 strings or other medium.
4077
4078 The library is focused on performances but still provide full generic
4079 parsers that can be used with strings, bigstrings, lexing buffers,
4080 character streams or any other sources effortlessly.
4081
4082 It provides three different class of parsers:
4083 @itemize
4084 @item
4085 the normal parsers, producing [Sexp.t] or [Sexp.t list] values
4086 @item
4087 the parsers with positions, building compact position sequences so
4088 that one can recover original positions in order to report properly
4089 located errors at little cost
4090 @item
4091 the Concrete Syntax Tree parsers, produce values of type
4092 @code{Parsexp.Cst.t} which record the concrete layout of the s-expression
4093 syntax, including comments
4094 @end itemize
4095
4096 This library is portable and doesn't provide IO functions. To read
4097 s-expressions from files or other external sources, you should use
4098 parsexp_io.")
4099 (license license:expat)))
4100
4101 (define-public ocaml4.07-sexplib
4102 (package
4103 (name "ocaml4.07-sexplib")
4104 (version "0.11.0")
4105 (home-page "https://github.com/janestreet/sexplib")
4106 (source
4107 (origin
4108 (method git-fetch)
4109 (uri (git-reference
4110 (url (string-append home-page ".git"))
4111 (commit (string-append "v" version))))
4112 (file-name (git-file-name name version))
4113 (sha256
4114 (base32
4115 "1qfl0m04rpcjvc4yw1hzh6r16jpwmap0sa9ax6zjji67dz4szpyb"))))
4116 (build-system dune-build-system)
4117 (arguments
4118 `(#:ocaml ,ocaml-4.07
4119 #:findlib ,ocaml4.07-findlib
4120 #:dune ,ocaml4.07-dune))
4121 (propagated-inputs
4122 `(("ocaml-num" ,(package-with-ocaml4.07 ocaml-num))
4123 ("ocaml-parsexp" ,ocaml4.07-parsexp)
4124 ("ocaml-sexplib0" ,ocaml4.07-sexplib0)))
4125 (synopsis
4126 "Library for serializing OCaml values to and from S-expressions")
4127 (description
4128 "This package is part of Jane Street's Core library. Sexplib contains
4129 functionality for parsing and pretty-printing s-expressions.")
4130 (license license:expat)))
4131
4132 (define-public ocaml4.07-base
4133 (package
4134 (name "ocaml4.07-base")
4135 (version "0.11.1")
4136 (home-page "https://github.com/janestreet/base")
4137 (source
4138 (origin
4139 (method git-fetch)
4140 (uri (git-reference
4141 (url (string-append home-page ".git"))
4142 (commit (string-append "v" version))))
4143 (file-name (git-file-name name version))
4144 (sha256
4145 (base32
4146 "0j6xb4265jr41vw4fjzak6yr8s30qrnzapnc6rl1dxy8bjai0nir"))))
4147 (build-system dune-build-system)
4148 (propagated-inputs
4149 `(("ocaml-sexplib0" ,ocaml4.07-sexplib0)))
4150 (arguments
4151 `(#:phases
4152 (modify-phases %standard-phases
4153 (replace 'build
4154 ;; make warnings non fatal (jbuilder behaviour)
4155 (lambda _
4156 (invoke "dune" "build" "@install" "--profile=release"))))
4157 #:ocaml ,ocaml-4.07
4158 #:findlib ,ocaml4.07-findlib
4159 #:dune ,ocaml4.07-dune))
4160 (synopsis
4161 "Full standard library replacement for OCaml")
4162 (description
4163 "Base is a complete and portable alternative to the OCaml standard
4164 library. It provides all standard functionalities one would expect
4165 from a language standard library. It uses consistent conventions
4166 across all of its module.
4167
4168 Base aims to be usable in any context. As a result system dependent
4169 features such as I/O are not offered by Base. They are instead
4170 provided by companion libraries such as
4171 @url{https://github.com/janestreet/stdio, ocaml-stdio}.")
4172 (license license:expat)))
4173
4174 (define-public ocaml4.07-compiler-libs
4175 (package
4176 (name "ocaml4.07-compiler-libs")
4177 (version "0.11.0")
4178 (home-page "https://github.com/janestreet/ocaml-compiler-libs")
4179 (source
4180 (origin
4181 (method git-fetch)
4182 (uri (git-reference
4183 (url (string-append home-page ".git"))
4184 (commit (string-append "v" version))))
4185 (file-name (git-file-name name version))
4186 (sha256
4187 (base32
4188 "03jds7bszh8wwpfwxb3dg0gyr1j1872wxwx1xqhry5ir0i84bg0s"))))
4189 (build-system dune-build-system)
4190 (arguments
4191 `(#:tests? #f ;no tests
4192 #:ocaml ,ocaml-4.07
4193 #:findlib ,ocaml4.07-findlib
4194 #:dune ,ocaml4.07-dune))
4195 (properties `((upstream-name . "ocaml-compiler-libs")))
4196 (synopsis "Compiler libraries repackaged")
4197 (description "This package simply repackages the OCaml compiler libraries
4198 so they don't expose everything at toplevel. For instance, @code{Ast_helper}
4199 is now @code{Ocaml_common.Ast_helper}.")
4200 (license license:expat)))
4201
4202 (define-public ocaml4.07-stdio
4203 (package
4204 (name "ocaml4.07-stdio")
4205 (version "0.11.0")
4206 (home-page "https://github.com/janestreet/stdio")
4207 (source
4208 (origin
4209 (method git-fetch)
4210 (uri (git-reference
4211 (url (string-append home-page ".git"))
4212 (commit (string-append "v" version))))
4213 (file-name (git-file-name name version))
4214 (sha256
4215 (base32
4216 "1facajqhvq34g2wrg368y0ajxd6lrj5b3lyzyj0jhdmraxajjcwn"))))
4217 (build-system dune-build-system)
4218 (propagated-inputs
4219 `(("ocaml-base" ,ocaml4.07-base)
4220 ("ocaml-sexplib0" ,ocaml4.07-sexplib0)))
4221 (arguments
4222 `(#:tests? #f ;no tests
4223 #:ocaml ,ocaml-4.07
4224 #:findlib ,ocaml4.07-findlib
4225 #:dune ,ocaml4.07-dune))
4226 (synopsis "Standard IO library for OCaml")
4227 (description
4228 "Stdio implements simple input/output functionalities for OCaml. It
4229 re-exports the input/output functions of the OCaml standard libraries using
4230 a more consistent API.")
4231 (license license:expat)))
4232
4233 (define-public ocaml-ppx-derivers
4234 (package
4235 (name "ocaml-ppx-derivers")
4236 (version "1.2.1")
4237 (home-page
4238 "https://github.com/ocaml-ppx/ppx_derivers")
4239 (source
4240 (origin
4241 (method git-fetch)
4242 (uri (git-reference
4243 (url (string-append home-page ".git"))
4244 (commit version)))
4245 (file-name (git-file-name name version))
4246 (sha256
4247 (base32
4248 "0yqvqw58hbx1a61wcpbnl9j30n495k23qmyy2xwczqs63mn2nkpn"))))
4249 (build-system dune-build-system)
4250 (arguments
4251 '(#:tests? #f)) ;no tests
4252 (properties `((upstream-name . "ppx_derivers")))
4253 (synopsis "Shared @code{@@deriving} plugin registry")
4254 (description
4255 "Ppx_derivers is a tiny package whose sole purpose is to allow
4256 ppx_deriving and ppx_type_conv to inter-operate gracefully when linked
4257 as part of the same ocaml-migrate-parsetree driver.")
4258 (license license:bsd-3)))
4259
4260 (define-public ocaml4.07-ppxlib
4261 (package
4262 (name "ocaml4.07-ppxlib")
4263 (version "0.6.0")
4264 (home-page "https://github.com/ocaml-ppx/ppxlib")
4265 (source
4266 (origin
4267 (method git-fetch)
4268 (uri (git-reference
4269 (url (string-append home-page ".git"))
4270 (commit version)))
4271 (file-name (git-file-name name version))
4272 (sha256
4273 (base32
4274 "0my9x7sxb329h0lzshppdaawiyfbaw6g5f41yiy7bhl071rnlvbv"))))
4275 (build-system dune-build-system)
4276 (propagated-inputs
4277 `(("ocaml-base" ,ocaml4.07-base)
4278 ("ocaml-compiler-libs" ,ocaml4.07-compiler-libs)
4279 ("ocaml-migrate-parsetree"
4280 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4281 ("ocaml-ppx-derivers" ,(package-with-ocaml4.07 ocaml-ppx-derivers))
4282 ("ocaml-stdio" ,ocaml4.07-stdio)
4283 ("ocaml-result" ,(package-with-ocaml4.07 ocaml-result))
4284 ("ocaml-sexplib0" ,ocaml4.07-sexplib0)))
4285 (arguments
4286 `(#:phases
4287 (modify-phases %standard-phases
4288 (add-before 'check 'set-topfind
4289 (lambda* (#:key inputs #:allow-other-keys)
4290 ;; add the line #directory ".." at the top of each file
4291 ;; using #use "topfind";; to be able to find topfind
4292 (let* ((findlib-path (assoc-ref inputs "findlib"))
4293 (findlib-libdir
4294 (string-append findlib-path "/lib/ocaml/site-lib")))
4295 (substitute* '("test/base/test.ml"
4296 "test/code_path/test.ml"
4297 "test/deriving/test.ml"
4298 "test/driver/attributes/test.ml"
4299 "test/driver/non-compressible-suffix/test.ml"
4300 "test/driver/transformations/test.ml")
4301 (("#use \"topfind\";;" all)
4302 (string-append "#directory \"" findlib-libdir "\"\n"
4303 all))))
4304 #t)))
4305 #:ocaml ,ocaml-4.07
4306 #:findlib ,ocaml4.07-findlib
4307 #:dune ,ocaml4.07-dune))
4308 (synopsis
4309 "Base library and tools for ppx rewriters")
4310 (description
4311 "A comprehensive toolbox for ppx development. It features:
4312 @itemize
4313 @item an OCaml AST / parser / pretty-printer snapshot, to create a full frontend
4314 independent of the version of OCaml;
4315 @item a library for library for ppx rewriters in general, and type-driven code
4316 generators in particular;
4317 @item
4318 a feature-full driver for OCaml AST transformers;
4319 @item a quotation mechanism allowing to write values representing the
4320 OCaml AST in the OCaml syntax;
4321 @item a generator of open recursion classes from type definitions.
4322 @end itemize")
4323 (license license:expat)))
4324
4325 (define-public ocaml4.07-ppx-compare
4326 (package
4327 (name "ocaml4.07-ppx-compare")
4328 (version "0.11.1")
4329 (source (origin
4330 (method git-fetch)
4331 (uri (git-reference
4332 (url "https://github.com/janestreet/ppx_compare")
4333 (commit (string-append "v" version))))
4334 (file-name (git-file-name name version))
4335 (sha256
4336 (base32
4337 "06bq4m1bsm4jlx4g7wh5m99qky7xm4c2g52kaz6pv25hdn5agi2m"))))
4338 (build-system dune-build-system)
4339 (propagated-inputs
4340 `(("ocaml-base" ,ocaml4.07-base)
4341 ("ocaml-migrate-parsetree"
4342 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4343 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4344 (arguments
4345 `(#:ocaml ,ocaml-4.07
4346 #:findlib ,ocaml4.07-findlib
4347 #:dune ,ocaml4.07-dune))
4348 (properties `((upstream-name . "ppx_compare")))
4349 (home-page "https://github.com/janestreet/ppx_compare")
4350 (synopsis "Generation of comparison functions from types")
4351 (description "Generation of fast comparison functions from type expressions
4352 and definitions. Ppx_compare is a ppx rewriter that derives comparison functions
4353 from type representations. The scaffolded functions are usually much faster
4354 than ocaml's Pervasives.compare. Scaffolding functions also gives you more
4355 flexibility by allowing you to override them for a specific type and more safety
4356 by making sure that you only compare comparable values.")
4357 (license license:asl2.0)))
4358
4359 (define-public ocaml4.07-fieldslib
4360 (package
4361 (name "ocaml4.07-fieldslib")
4362 (version "0.11.0")
4363 (source (origin
4364 (method url-fetch)
4365 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4366 (version-major+minor version) "/files/"
4367 "fieldslib-v" version ".tar.gz"))
4368 (sha256
4369 (base32
4370 "12948pzxrl360lybm9fzyvplgcl87zjbn4m3sk1aw75zk85p1388"))))
4371 (build-system dune-build-system)
4372 (arguments
4373 ;; No tests
4374 `(#:tests? #f
4375 #:ocaml ,ocaml-4.07
4376 #:findlib ,ocaml4.07-findlib
4377 #:dune ,ocaml4.07-dune))
4378 (propagated-inputs
4379 `(("ocaml-base" ,ocaml4.07-base)
4380 ("ocaml-migrate-parsetree"
4381 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4382 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4383 (properties `((upstream-name . "fieldslib")))
4384 (home-page "https://github.com/janestreet/fieldslib")
4385 (synopsis "Syntax extension to record fields")
4386 (description "Syntax extension to define first class values representing
4387 record fields, to get and set record fields, iterate and fold over all fields
4388 of a record and create new record values.")
4389 (license license:asl2.0)))
4390
4391 (define-public ocaml4.07-variantslib
4392 (package
4393 (name "ocaml4.07-variantslib")
4394 (version "0.11.0")
4395 (source (origin
4396 (method url-fetch)
4397 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4398 (version-major+minor version)
4399 "/files/variantslib-v" version ".tar.gz"))
4400 (sha256
4401 (base32
4402 "1hsdwmkslvk4cznqr4lyyiy7vvk5spil226k0z2in26fxq6y0hf3"))))
4403 (build-system dune-build-system)
4404 (arguments
4405 ;; No tests
4406 `(#:tests? #f
4407 #:ocaml ,ocaml-4.07
4408 #:findlib ,ocaml4.07-findlib
4409 #:dune ,ocaml4.07-dune))
4410 (propagated-inputs
4411 `(("ocaml-base" ,ocaml4.07-base)
4412 ("ocaml-migrate-parsetree"
4413 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4414 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4415 (properties `((upstream-name . "variantslib")))
4416 (home-page "https://github.com/janestreet/variantslib")
4417 (synopsis "OCaml variants as first class values")
4418 (description "The Core suite of libraries is an alternative to OCaml's
4419 standard library.")
4420 (license license:asl2.0)))
4421
4422 (define-public ocaml4.07-ppx-fields-conv
4423 (package
4424 (name "ocaml4.07-ppx-fields-conv")
4425 (version "0.11.0")
4426 (source (origin
4427 (method url-fetch)
4428 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4429 (version-major+minor version)
4430 "/files/ppx_fields_conv-v" version ".tar.gz"))
4431 (sha256
4432 (base32
4433 "07zrd3qky2ppbfl55gpm90rvqa5860xgwcsvihrjmkrw6d0jirkc"))))
4434 (build-system dune-build-system)
4435 (propagated-inputs
4436 `(("ocaml-base" ,ocaml4.07-base)
4437 ("ocaml-fieldslib" ,ocaml4.07-fieldslib)
4438 ("ocaml-migrate-parsetree"
4439 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4440 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4441 (arguments
4442 `(#:ocaml ,ocaml-4.07
4443 #:findlib ,ocaml4.07-findlib
4444 #:dune ,ocaml4.07-dune))
4445 (properties `((upstream-name . "ppx_fields_conv")))
4446 (home-page "https://github.com/janestreet/ppx_fields_conv")
4447 (synopsis "Generation of accessor and iteration functions for ocaml records")
4448 (description "Ppx_fields_conv is a ppx rewriter that can be used to define
4449 first class values representing record fields, and additional routines, to get
4450 and set record fields, iterate and fold over all fields of a record and create
4451 new record values.")
4452 (license license:asl2.0)))
4453
4454 (define-public ocaml4.07-ppx-sexp-conv
4455 (package
4456 (name "ocaml4.07-ppx-sexp-conv")
4457 (version "0.11.2")
4458 (source (origin
4459 (method git-fetch)
4460 (uri (git-reference
4461 (url "https://github.com/janestreet/ppx_sexp_conv")
4462 (commit (string-append "v" version))))
4463 (file-name (git-file-name name version))
4464 (sha256
4465 (base32
4466 "0pqwnqy1xp309wvdcaax4lg02yk64lq2w03mbgfvf6ps5ry4gis9"))))
4467 (build-system dune-build-system)
4468 (propagated-inputs
4469 `(("ocaml-base" ,ocaml4.07-base)
4470 ("ocaml-migrate-parsetree"
4471 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4472 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4473 (arguments
4474 `(#:ocaml ,ocaml-4.07
4475 #:findlib ,ocaml4.07-findlib
4476 #:dune ,ocaml4.07-dune))
4477 (properties `((upstream-name . "ppx_sexp_conv")))
4478 (home-page "https://github.com/janestreet/ppx_sexp_conv")
4479 (synopsis "Generation of S-expression conversion functions from type definitions")
4480 (description "This package generates S-expression conversion functions from type
4481 definitions.")
4482 (license license:asl2.0)))
4483
4484 (define-public ocaml4.07-ppx-variants-conv
4485 (package
4486 (name "ocaml4.07-ppx-variants-conv")
4487 (version "0.11.1")
4488 (source (origin
4489 (method git-fetch)
4490 (uri (git-reference
4491 (url "https://github.com/janestreet/ppx_variants_conv")
4492 (commit (string-append "v" version))))
4493 (file-name (git-file-name name version))
4494 (sha256
4495 (base32
4496 "1yc0gsds5m2nv39zga8nnrca2n75rkqy5dz4xj1635ybz20hhbjd"))))
4497 (build-system dune-build-system)
4498 (propagated-inputs
4499 `(("ocaml-base" ,ocaml4.07-base)
4500 ("ocaml-variantslib" ,ocaml4.07-variantslib)
4501 ("ocaml-migrate-parsetree"
4502 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4503 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4504 (arguments
4505 `(#:ocaml ,ocaml-4.07
4506 #:findlib ,ocaml4.07-findlib
4507 #:dune ,ocaml4.07-dune))
4508 (properties
4509 `((upstream-name . "ppx_variants_conv")))
4510 (home-page
4511 "https://github.com/janestreet/ppx_variants_conv")
4512 (synopsis "Generation of accessor and iteration functions for OCaml variant types")
4513 (description
4514 "This package generates accessors and iteration functions for OCaml
4515 variant types.")
4516 (license license:asl2.0)))
4517
4518 (define-public ocaml4.07-ppx-custom-printf
4519 (package
4520 (name "ocaml4.07-ppx-custom-printf")
4521 (version "0.11.0")
4522 (source (origin
4523 (method url-fetch)
4524 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4525 (version-major+minor version)
4526 "/files/ppx_custom_printf-v" version ".tar.gz"))
4527 (sha256
4528 (base32
4529 "11b73smf3g3bpd9lg014pr4rx285nk9mnk6g6464ph51jv0sqzhj"))))
4530 (build-system dune-build-system)
4531 (propagated-inputs
4532 `(("ocaml-base" ,ocaml4.07-base)
4533 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
4534 ("ocaml-migrate-parsetree"
4535 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4536 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4537 (arguments
4538 `(#:ocaml ,ocaml-4.07
4539 #:findlib ,ocaml4.07-findlib
4540 #:dune ,ocaml4.07-dune))
4541 (properties `((upstream-name . "ppx_custom_printf")))
4542 (home-page "https://github.com/janestreet/ppx_custom_printf")
4543 (synopsis "Printf-style format-strings for user-defined string conversion")
4544 (description "Extensions to printf-style format-strings for user-defined
4545 string conversion.")
4546 (license license:asl2.0)))
4547
4548 (define-public ocaml4.07-bin-prot
4549 (package
4550 (name "ocaml4.07-bin-prot")
4551 (version "0.11.0")
4552 (source (origin
4553 (method url-fetch)
4554 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4555 (version-major+minor version)
4556 "/files/bin_prot-v" version ".tar.gz"))
4557 (sha256
4558 (base32
4559 "1rsd91gx36prj4whi76nsiz1bzpgal9nzyw3pxdz1alv4ilk2il6"))))
4560 (build-system dune-build-system)
4561 (inputs
4562 `(("ocaml-base" ,ocaml4.07-base)
4563 ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare)
4564 ("ocaml-ppx-custom-printf" ,ocaml4.07-ppx-custom-printf)
4565 ("ocaml-ppx-fields-conv" ,ocaml4.07-ppx-fields-conv)
4566 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
4567 ("ocaml-ppx-variants-conv" ,ocaml4.07-ppx-variants-conv)
4568 ("ocaml-migrate-parsetree"
4569 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))))
4570 (arguments
4571 `(#:ocaml ,ocaml-4.07
4572 #:findlib ,ocaml4.07-findlib
4573 #:dune ,ocaml4.07-dune))
4574 (properties `((upstream-name . "bin_prot")))
4575 (home-page "https://github.com/janestreet/bin_prot")
4576 (synopsis "Binary protocol generator")
4577 (description "This library contains functionality for reading and writing
4578 OCaml-values in a type-safe binary protocol. It is extremely efficient,
4579 typically supporting type-safe marshalling and unmarshalling of even highly
4580 structured values at speeds sufficient to saturate a gigabit connection. The
4581 protocol is also heavily optimized for size, making it ideal for long-term
4582 storage of large amounts of data.")
4583 (license (list
4584 license:asl2.0
4585 license:bsd-3))))
4586
4587 (define-public ocaml-octavius
4588 (package
4589 (name "ocaml-octavius")
4590 (version "1.2.2")
4591 (source (origin
4592 (method git-fetch)
4593 (uri (git-reference
4594 (url "https://github.com/ocaml-doc/octavius")
4595 (commit (string-append "v" version))))
4596 (file-name (git-file-name name version))
4597 (sha256
4598 (base32
4599 "1c5m51xcn2jv42kjjpklr6g63sgx1k885wfdp1yr4wrmiaj9cbpx"))))
4600 (build-system dune-build-system)
4601 (arguments
4602 `(#:phases
4603 (modify-phases %standard-phases
4604 (add-before 'build 'make-writable
4605 (lambda _
4606 (for-each (lambda (file)
4607 (chmod file #o644))
4608 (find-files "." "."))
4609 #t)))))
4610 (properties `((upstream-name . "octavius")))
4611 (home-page "https://github.com/ocaml-doc/octavius")
4612 (synopsis "Ocamldoc comment syntax parser")
4613 (description "Octavius is a library to parse the `ocamldoc` comment syntax.")
4614 (license license:isc)))
4615
4616 (define-public ocaml4.07-ppx-hash
4617 (package
4618 (name "ocaml4.07-ppx-hash")
4619 (version "0.11.1")
4620 (source (origin
4621 (method git-fetch)
4622 (uri (git-reference
4623 (url "https://github.com/janestreet/ppx_hash")
4624 (commit (string-append "v" version))))
4625 (file-name (git-file-name name version))
4626 (sha256
4627 (base32
4628 "1p0ic6aijxlrdggpmycj12q3cy9xksbq2vq727215maz4snvlf5p"))))
4629 (build-system dune-build-system)
4630 (propagated-inputs
4631 `(("ocaml-base" ,ocaml4.07-base)
4632 ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare)
4633 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
4634 ("ocaml-migrate-parsetree"
4635 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4636 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4637 (arguments
4638 `(#:ocaml ,ocaml-4.07
4639 #:findlib ,ocaml4.07-findlib
4640 #:dune ,ocaml4.07-dune))
4641 (properties `((upstream-name . "ppx_hash")))
4642 (home-page "https://github.com/janestreet/ppx_hash")
4643 (synopsis "Generation of hash functions from type expressions and definitions")
4644 (description "This package is a collection of ppx rewriters that generate
4645 hash functions from type exrpessions and definitions.")
4646 (license license:asl2.0)))
4647
4648 (define-public ocaml4.07-ppx-enumerate
4649 (package
4650 (name "ocaml4.07-ppx-enumerate")
4651 (version "0.11.1")
4652 (source (origin
4653 (method git-fetch)
4654 (uri (git-reference
4655 (url "https://github.com/janestreet/ppx_enumerate")
4656 (commit (string-append "v" version))))
4657 (file-name (git-file-name name version))
4658 (sha256
4659 (base32
4660 "0spx9k1v7vjjb6sigbfs69yndgq76v114jhxvzjmffw7q989cyhr"))))
4661 (build-system dune-build-system)
4662 (arguments
4663 `(#:tests? #f; no test suite
4664 #:ocaml ,ocaml-4.07
4665 #:findlib ,ocaml4.07-findlib
4666 #:dune ,ocaml4.07-dune))
4667 (propagated-inputs
4668 `(("ocaml-base" ,ocaml4.07-base)
4669 ("ocaml-migrate-parsetree"
4670 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4671 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4672 (properties `((upstream-name . "ppx_enumerate")))
4673 (home-page "https://github.com/janestreet/ppx_enumerate")
4674 (synopsis "Generate a list containing all values of a finite type")
4675 (description "Ppx_enumerate is a ppx rewriter which generates a definition
4676 for the list of all values of a type (for a type which only has finitely
4677 many values).")
4678 (license license:asl2.0)))
4679
4680 (define-public ocaml4.07-ppx-bench
4681 (package
4682 (name "ocaml4.07-ppx-bench")
4683 (version "0.11.0")
4684 (source (origin
4685 (method url-fetch)
4686 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4687 (version-major+minor version)
4688 "/files/ppx_bench-v" version ".tar.gz"))
4689 (sha256
4690 (base32
4691 "0ys4pblbcjbk9dn073rqiwm7r6rc7fah03j7riklkwnb5n44andl"))))
4692 (build-system dune-build-system)
4693 (arguments
4694 ;; No tests
4695 `(#:tests? #f
4696 #:ocaml ,ocaml-4.07
4697 #:findlib ,ocaml4.07-findlib
4698 #:dune ,ocaml4.07-dune))
4699 (propagated-inputs
4700 `(("ocaml-ppx-inline-test" ,ocaml4.07-ppx-inline-test)
4701 ("ocaml-migrate-parsetree"
4702 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4703 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4704 (properties `((upstream-name . "ppx_bench")))
4705 (home-page "https://github.com/janestreet/ppx_bench")
4706 (synopsis "Syntax extension for writing in-line benchmarks in ocaml code")
4707 (description "Syntax extension for writing in-line benchmarks in ocaml code.")
4708 (license license:asl2.0)))
4709
4710 (define-public ocaml4.07-ppx-here
4711 (package
4712 (name "ocaml4.07-ppx-here")
4713 (version "0.11.0")
4714 (source (origin
4715 (method url-fetch)
4716 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4717 (version-major+minor version)
4718 "/files/ppx_here-v" version ".tar.gz"))
4719 (sha256
4720 (base32
4721 "0wxcak3ay4jpigm3pfdcpr65qw4hxfa8whhkryhcd8gy71x056z5"))))
4722 (build-system dune-build-system)
4723 (arguments
4724 ;; broken tests
4725 `(#:tests? #f
4726 #:ocaml ,ocaml-4.07
4727 #:findlib ,ocaml4.07-findlib
4728 #:dune ,ocaml4.07-dune))
4729 (propagated-inputs
4730 `(("ocaml-base" ,ocaml4.07-base)
4731 ("ocaml-migrate-parsetree"
4732 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4733 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4734 (properties `((upstream-name . "ppx_here")))
4735 (home-page "https://github.com/janestreet/ppx_here")
4736 (synopsis "Expands [%here] into its location")
4737 (description
4738 "Part of the Jane Street's PPX rewriters collection.")
4739 (license license:asl2.0)))
4740
4741 (define-public ocaml4.07-typerep
4742 (package
4743 (name "ocaml4.07-typerep")
4744 (version "0.11.0")
4745 (source (origin
4746 (method url-fetch)
4747 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4748 (version-major+minor version)
4749 "/files/typerep-v" version ".tar.gz"))
4750 (sha256
4751 (base32
4752 "1zi7hy0prpgzqhr4lkacr04wvlvbp21jfbdfvffhrm6cd400rb5v"))))
4753 (build-system dune-build-system)
4754 (arguments
4755 `(#:tests? #f
4756 #:ocaml ,ocaml-4.07
4757 #:findlib ,ocaml4.07-findlib
4758 #:dune ,ocaml4.07-dune))
4759 (propagated-inputs `(("ocaml-base" ,ocaml4.07-base)))
4760 (home-page "https://github.com/janestreet/typerep")
4761 (synopsis "Typerep is a library for runtime types")
4762 (description "Typerep is a library for runtime types.")
4763 (license license:asl2.0)))
4764
4765 (define-public ocaml4.07-ppx-sexp-value
4766 (package
4767 (name "ocaml4.07-ppx-sexp-value")
4768 (version "0.11.0")
4769 (source (origin
4770 (method url-fetch)
4771 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4772 (version-major+minor version)
4773 "/files/ppx_sexp_value-v" version ".tar.gz"))
4774 (sha256
4775 (base32
4776 "1xnalfrln6k5khsyxvxkg6v32q8fpr4cqamsjqfih29jdv486xrs"))))
4777 (build-system dune-build-system)
4778 (arguments
4779 `(#:ocaml ,ocaml-4.07
4780 #:findlib ,ocaml4.07-findlib
4781 #:dune ,ocaml4.07-dune))
4782 (propagated-inputs
4783 `(("ocaml-base" ,ocaml4.07-base)
4784 ("ocaml-ppx-here" ,ocaml4.07-ppx-here)
4785 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
4786 ("ocaml-migrate-parsetree"
4787 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4788 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4789 (properties `((upstream-name . "ppx_sexp_value")))
4790 (home-page "https://github.com/janestreet/ppx_sexp_value")
4791 (synopsis "Simplify building s-expressions from ocaml values")
4792 (description "A ppx rewriter that simplifies building s-expressions from
4793 ocaml values.")
4794 (license license:asl2.0)))
4795
4796 (define-public ocaml4.07-ppx-sexp-message
4797 (package
4798 (name "ocaml4.07-ppx-sexp-message")
4799 (version "0.11.0")
4800 (source (origin
4801 (method url-fetch)
4802 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4803 (version-major+minor version)
4804 "/files/ppx_sexp_message-v" version ".tar.gz"))
4805 (sha256
4806 (base32
4807 "1yh440za0w9cvrbxbmqacir8715kdaw6sw24ys9xj80av9nqpiw7"))))
4808 (build-system dune-build-system)
4809 (arguments
4810 `(#:ocaml ,ocaml-4.07
4811 #:findlib ,ocaml4.07-findlib
4812 #:dune ,ocaml4.07-dune))
4813 (propagated-inputs
4814 `(("ocaml-base" ,ocaml4.07-base)
4815 ("ocaml-ppx-here" ,ocaml4.07-ppx-here)
4816 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
4817 ("ocaml-migrate-parsetree"
4818 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4819 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4820 (properties `((upstream-name . "ppx_sexp_message")))
4821 (home-page "https://github.com/janestreet/ppx_sexp_message")
4822 (synopsis "A ppx rewriter for easy construction of s-expressions")
4823 (description "Ppx_sexp_message aims to ease the creation of s-expressions
4824 in OCaml. This is mainly motivated by writing error and debugging messages,
4825 where one needs to construct a s-expression based on various element of the
4826 context such as function arguments.")
4827 (license license:asl2.0)))
4828
4829 (define-public ocaml4.07-ppx-pipebang
4830 (package
4831 (name "ocaml4.07-ppx-pipebang")
4832 (version "0.11.0")
4833 (source (origin
4834 (method url-fetch)
4835 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4836 (version-major+minor version)
4837 "/files/ppx_pipebang-v" version ".tar.gz"))
4838 (sha256
4839 (base32
4840 "1wrrzlb4kdvkkcmzi01fw25jar38r2jlnyn0i6pn4z0lq4gpm9m0"))))
4841 (build-system dune-build-system)
4842 (arguments
4843 ;; No tests
4844 `(#:tests? #f
4845 #:ocaml ,ocaml-4.07
4846 #:findlib ,ocaml4.07-findlib
4847 #:dune ,ocaml4.07-dune))
4848 (propagated-inputs
4849 `(("ocaml-migrate-parsetree"
4850 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4851 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4852 (properties `((upstream-name . "ppx_pipebang")))
4853 (home-page "https://github.com/janestreet/ppx_pipebang")
4854 (synopsis "Inline reverse application operators `|>` and `|!`")
4855 (description "A ppx rewriter that inlines reverse application operators
4856 @code{|>} and @code{|!}.")
4857 (license license:asl2.0)))
4858
4859 (define-public ocaml4.07-ppx-optional
4860 (package
4861 (name "ocaml4.07-ppx-optional")
4862 (version "0.11.0")
4863 (source (origin
4864 (method url-fetch)
4865 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4866 (version-major+minor version)
4867 "/files/ppx_optional-v" version ".tar.gz"))
4868 (sha256
4869 (base32
4870 "1z8z2bga95k2vksljljfglg10vygkjd24kn1b37sk4z3nmp47x0h"))))
4871 (build-system dune-build-system)
4872 (arguments
4873 ;; No tests
4874 `(#:tests? #f
4875 #:ocaml ,ocaml-4.07
4876 #:findlib ,ocaml4.07-findlib
4877 #:dune ,ocaml4.07-dune))
4878 (propagated-inputs
4879 `(("ocaml-base" ,ocaml4.07-base)
4880 ("ocaml-migrate-parsetree"
4881 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4882 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4883 (properties `((upstream-name . "ppx_optional")))
4884 (home-page "https://github.com/janestreet/ppx_optional")
4885 (synopsis "Pattern matching on flat options")
4886 (description
4887 "A ppx rewriter that rewrites simple match statements with an if then
4888 else expression.")
4889 (license license:asl2.0)))
4890
4891 (define-public ocaml4.07-ppx-optcomp
4892 (package
4893 (name "ocaml4.07-ppx-optcomp")
4894 (version "0.11.0")
4895 (source (origin
4896 (method url-fetch)
4897 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4898 (version-major+minor version)
4899 "/files/ppx_optcomp-v" version ".tar.gz"))
4900 (sha256
4901 (base32
4902 "1bb52p2j2h4s9f06vrcpla80rj93jinnzq6jzilapyx9q068929i"))))
4903 (build-system dune-build-system)
4904 (arguments
4905 `(#:ocaml ,ocaml-4.07
4906 #:findlib ,ocaml4.07-findlib
4907 #:dune ,ocaml4.07-dune))
4908 (propagated-inputs
4909 `(("ocaml-base" ,ocaml4.07-base)
4910 ("ocaml-stdio" ,ocaml4.07-stdio)
4911 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4912 (properties `((upstream-name . "ppx_optcomp")))
4913 (home-page "https://github.com/janestreet/ppx_optcomp")
4914 (synopsis "Optional compilation for OCaml")
4915 (description "Ppx_optcomp stands for Optional Compilation. It is a tool
4916 used to handle optional compilations of pieces of code depending of the word
4917 size, the version of the compiler, ...")
4918 (license license:asl2.0)))
4919
4920 (define-public ocaml4.07-ppx-let
4921 (package
4922 (name "ocaml4.07-ppx-let")
4923 (version "0.11.0")
4924 (source (origin
4925 (method url-fetch)
4926 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4927 (version-major+minor version)
4928 "/files/ppx_let-v" version ".tar.gz"))
4929 (sha256
4930 (base32
4931 "1wdfw6w4xbg97a35yg6bif9gggxniy9ddnrjfw1a0inkl2yamxkj"))))
4932 (build-system dune-build-system)
4933 (arguments
4934 `(#:ocaml ,ocaml-4.07
4935 #:findlib ,ocaml4.07-findlib
4936 #:dune ,ocaml4.07-dune))
4937 (propagated-inputs
4938 `(("ocaml-base" ,ocaml4.07-base)
4939 ("ocaml-migrate-parsetree"
4940 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4941 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4942 (properties `((upstream-name . "ppx_let")))
4943 (home-page "https://github.com/janestreet/ppx_let")
4944 (synopsis "Monadic let-bindings")
4945 (description "A ppx rewriter for monadic and applicative let bindings,
4946 match expressions, and if expressions.")
4947 (license license:asl2.0)))
4948
4949 (define-public ocaml4.07-ppx-fail
4950 (package
4951 (name "ocaml4.07-ppx-fail")
4952 (version "0.11.0")
4953 (source (origin
4954 (method url-fetch)
4955 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4956 (version-major+minor version)
4957 "/files/ppx_fail-v" version ".tar.gz"))
4958 (sha256
4959 (base32
4960 "07plqsvljiwvngggfypwq55g46s5my55y45mvlmalrxyppzr03s8"))))
4961 (build-system dune-build-system)
4962 (arguments
4963 `(#:ocaml ,ocaml-4.07
4964 #:findlib ,ocaml4.07-findlib
4965 #:dune ,ocaml4.07-dune))
4966 (propagated-inputs
4967 `(("ocaml-base" ,ocaml4.07-base)
4968 ("ocaml-ppx-here" ,ocaml4.07-ppx-here)
4969 ("ocaml-migrate-parsetree"
4970 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
4971 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
4972 (properties `((upstream-name . "ppx_fail")))
4973 (home-page "https://github.com/janestreet/ppx_fail")
4974 (synopsis "Add location to calls to failwiths")
4975 (description "Syntax extension that makes [failwiths] always include a
4976 position.")
4977 (license license:asl2.0)))
4978
4979 (define-public ocaml4.07-ppx-assert
4980 (package
4981 (name "ocaml4.07-ppx-assert")
4982 (version "0.11.0")
4983 (source (origin
4984 (method url-fetch)
4985 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
4986 (version-major+minor version)
4987 "/files/ppx_assert-v" version ".tar.gz"))
4988 (sha256
4989 (base32
4990 "17kd311n0l9f72gblf9kv8i5rghr106w37x4f0m5qwh6nlgl0j9k"))))
4991 (build-system dune-build-system)
4992 (arguments
4993 `(#:ocaml ,ocaml-4.07
4994 #:findlib ,ocaml4.07-findlib
4995 #:dune ,ocaml4.07-dune))
4996 (propagated-inputs
4997 `(("ocaml-base" ,ocaml4.07-base)
4998 ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare)
4999 ("ocaml-ppx-here" ,ocaml4.07-ppx-here)
5000 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
5001 ("ocaml-migrate-parsetree"
5002 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5003 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
5004 (properties `((upstream-name . "ppx_assert")))
5005 (home-page "https://github.com/janestreet/ppx_assert")
5006 (synopsis "Assert-like extension nodes that raise useful errors on failure")
5007 (description "This package contains assert-like extension nodes that raise
5008 useful errors on failure.")
5009 (license license:asl2.0)))
5010
5011 (define-public ocaml4.07-ppx-expect
5012 (package
5013 (name "ocaml4.07-ppx-expect")
5014 (version "0.12.0")
5015 (source (origin
5016 (method git-fetch)
5017 (uri (git-reference
5018 (url "https://github.com/janestreet/ppx_expect")
5019 (commit (string-append "v" version))))
5020 (file-name (git-file-name name version))
5021 (sha256
5022 (base32
5023 "1wawsbjfkri4sw52n8xqrzihxc3xfpdicv3ahz83a1rsn4lb8j5q"))))
5024 (build-system dune-build-system)
5025 (arguments
5026 `(#:ocaml ,ocaml-4.07
5027 #:findlib ,ocaml4.07-findlib
5028 #:dune ,ocaml4.07-dune))
5029 (propagated-inputs
5030 `(("ocaml-base" ,ocaml4.07-base)
5031 ("ocaml-ppx-assert" ,ocaml4.07-ppx-assert)
5032 ("ocaml-ppx-compare" ,ocaml4.07-ppx-compare)
5033 ("ocaml-ppx-custom-printf" ,ocaml4.07-ppx-custom-printf)
5034 ("ocaml-ppx-fields-conv" ,ocaml4.07-ppx-fields-conv)
5035 ("ocaml-ppx-here" ,ocaml4.07-ppx-here)
5036 ("ocaml-ppx-inline-test" ,ocaml4.07-ppx-inline-test)
5037 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
5038 ("ocaml-ppx-variants-conv" ,ocaml4.07-ppx-variants-conv)
5039 ("ocaml-stdio" ,ocaml4.07-stdio)
5040 ("ocaml-migrate-parsetree"
5041 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5042 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)
5043 ("ocaml-re" ,(package-with-ocaml4.07 ocaml-re))))
5044 (properties `((upstream-name . "ppx_expect")))
5045 (home-page "https://github.com/janestreet/ppx_expect")
5046 (synopsis "Cram like framework for OCaml")
5047 (description "Expect-test is a framework for writing tests in OCaml, similar
5048 to Cram. Expect-tests mimics the existing inline tests framework with the
5049 @code{let%expect_test} construct. The body of an expect-test can contain
5050 output-generating code, interleaved with @code{%expect} extension expressions
5051 to denote the expected output.")
5052 (license license:asl2.0)))
5053
5054 (define-public ocaml4.07-ppx-js-style
5055 (package
5056 (name "ocaml4.07-ppx-js-style")
5057 (version "0.11.0")
5058 (source (origin
5059 (method url-fetch)
5060 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5061 (version-major+minor version)
5062 "/files/ppx_js_style-v" version ".tar.gz"))
5063 (sha256
5064 (base32
5065 "0z3fc55jdjhhsblla6z4fqc13kljpcz29q79rvs5h2vsraqrldr2"))))
5066 (build-system dune-build-system)
5067 (arguments
5068 ;; No tests
5069 `(#:tests? #f
5070 #:ocaml ,ocaml-4.07
5071 #:findlib ,ocaml4.07-findlib
5072 #:dune ,ocaml4.07-dune))
5073 (propagated-inputs
5074 `(("ocaml-base" ,ocaml4.07-base)
5075 ("ocaml-migrate-parsetree"
5076 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5077 ("ocaml-octavius" ,(package-with-ocaml4.07 ocaml-octavius))
5078 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
5079 (properties `((upstream-name . "ppx_js_style")))
5080 (home-page "https://github.com/janestreet/ppx_js_style")
5081 (synopsis "Code style checker for Jane Street Packages")
5082 (description "This package is a no-op ppx rewriter. It is used as a
5083 @code{lint} tool to enforce some coding conventions across all Jane Street
5084 packages.")
5085 (license license:asl2.0)))
5086
5087 (define-public ocaml4.07-ppx-typerep-conv
5088 (package
5089 (name "ocaml4.07-ppx-typerep-conv")
5090 (version "0.11.1")
5091 (source (origin
5092 (method git-fetch)
5093 (uri (git-reference
5094 (url "https://github.com/janestreet/ppx_typerep_conv")
5095 (commit (string-append "v" version))))
5096 (file-name (git-file-name name version))
5097 (sha256
5098 (base32
5099 "0a13dpfrrg0rsm8qni1bh7pqcda30l70z8r6yzi5a64bmwk7g5ah"))))
5100 (build-system dune-build-system)
5101 (arguments
5102 `(#:test-target "."
5103 #:ocaml ,ocaml-4.07
5104 #:findlib ,ocaml4.07-findlib
5105 #:dune ,ocaml4.07-dune))
5106 (propagated-inputs
5107 `(("ocaml-base" ,ocaml4.07-base)
5108 ("ocaml-typerep" ,ocaml4.07-typerep)
5109 ("ocaml-migrate-parsetree"
5110 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5111 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
5112 (properties `((upstream-name . "ppx_typerep_conv")))
5113 (home-page "https://github.com/janestreet/ppx_typerep_conv")
5114 (synopsis "Generation of runtime types from type declarations")
5115 (description "This package can automatically generate runtime types
5116 from type definitions.")
5117 (license license:asl2.0)))
5118
5119 (define-public ocaml4.07-ppx-base
5120 (package
5121 (name "ocaml4.07-ppx-base")
5122 (version "0.11.0")
5123 (source (origin
5124 (method url-fetch)
5125 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5126 (version-major+minor version)
5127 "/files/ppx_base-v" version ".tar.gz"))
5128 (sha256
5129 (base32
5130 "0aq206pg330jmj7lhcagiiwm3a0b3gsqm801m8ajd4ysyw7idkym"))))
5131 (build-system dune-build-system)
5132 (arguments
5133 `(#:test-target "."
5134 #:ocaml ,ocaml-4.07
5135 #:findlib ,ocaml4.07-findlib
5136 #:dune ,ocaml4.07-dune))
5137 (propagated-inputs
5138 `(("ocaml-ppx-compare" ,ocaml4.07-ppx-compare)
5139 ("ocaml-ppx-enumerate" ,ocaml4.07-ppx-enumerate)
5140 ("ocaml-ppx-hash" ,ocaml4.07-ppx-hash)
5141 ("ocaml-ppx-js-style" ,ocaml4.07-ppx-js-style)
5142 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
5143 ("ocaml-migrate-parsetree"
5144 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5145 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
5146 (properties `((upstream-name . "ppx_base")))
5147 (home-page "https://github.com/janestreet/ppx_base")
5148 (synopsis "Base set of ppx rewriters")
5149 (description "Ppx_base is the set of ppx rewriters used for Base.
5150
5151 Note that Base doesn't need ppx to build, it is only used as a
5152 verification tool.")
5153 (license license:asl2.0)))
5154
5155 (define-public ocaml4.07-ppx-bin-prot
5156 (package
5157 (name "ocaml4.07-ppx-bin-prot")
5158 (version "0.11.1")
5159 (source (origin
5160 (method git-fetch)
5161 (uri (git-reference
5162 (url "https://github.com/janestreet/ppx_bin_prot")
5163 (commit (string-append "v" version))))
5164 (file-name (git-file-name name version))
5165 (sha256
5166 (base32
5167 "1h60i75bzvhna1axyn662gyrzhh441l79vl142d235i5x31dmnkz"))))
5168 (build-system dune-build-system)
5169 (arguments
5170 ;; Cyclic dependency with ocaml-ppx-jane
5171 `(#:tests? #f
5172 #:ocaml ,ocaml-4.07
5173 #:findlib ,ocaml4.07-findlib
5174 #:dune ,ocaml4.07-dune))
5175 (propagated-inputs
5176 `(("ocaml-base" ,ocaml4.07-base)
5177 ("ocaml-bin-prot" ,ocaml4.07-bin-prot)
5178 ("ocaml-ppx-here" ,ocaml4.07-ppx-here)
5179 ("ocaml-migrate-parsetree"
5180 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5181 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
5182 (properties `((upstream-name . "ppx_bin_prot")))
5183 (home-page "https://github.com/janestreet/ppx_bin_prot")
5184 (synopsis "Generation of bin_prot readers and writers from types")
5185 (description "Generation of binary serialization and deserialization
5186 functions from type definitions.")
5187 (license license:asl2.0)))
5188
5189 (define-public ocaml4.07-ppx-jane
5190 (package
5191 (name "ocaml4.07-ppx-jane")
5192 (version "0.11.0")
5193 (source (origin
5194 (method url-fetch)
5195 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5196 (version-major+minor version)
5197 "/files/ppx_jane-v" version ".tar.gz"))
5198 (sha256
5199 (base32
5200 "0lgppkw3aixrfnixihrsz2ipafv8fpvkdpy3pw8n0r615gg8x8la"))))
5201 (build-system dune-build-system)
5202 (arguments
5203 `(#:test-target "."
5204 #:ocaml ,ocaml-4.07
5205 #:findlib ,ocaml4.07-findlib
5206 #:dune ,ocaml4.07-dune))
5207 (propagated-inputs
5208 `(("ocaml-ppx-assert" ,ocaml4.07-ppx-assert)
5209 ("ocaml-ppx-base" ,ocaml4.07-ppx-base)
5210 ("ocaml-ppx-bench" ,ocaml4.07-ppx-bench)
5211 ("ocaml-ppx-bin-prot" ,ocaml4.07-ppx-bin-prot)
5212 ("ocaml-ppx-custom-printf" ,ocaml4.07-ppx-custom-printf)
5213 ("ocaml-ppx-expect" ,ocaml4.07-ppx-expect)
5214 ("ocaml-ppx-fail" ,ocaml4.07-ppx-fail)
5215 ("ocaml-ppx-fields-conv" ,ocaml4.07-ppx-fields-conv)
5216 ("ocaml-ppx-here" ,ocaml4.07-ppx-here)
5217 ("ocaml-ppx-inline-test" ,ocaml4.07-ppx-inline-test)
5218 ("ocaml-ppx-let" ,ocaml4.07-ppx-let)
5219 ("ocaml-ppx-optcomp" ,ocaml4.07-ppx-optcomp)
5220 ("ocaml-ppx-optional" ,ocaml4.07-ppx-optional)
5221 ("ocaml-ppx-pipebang" ,ocaml4.07-ppx-pipebang)
5222 ("ocaml-ppx-sexp-message" ,ocaml4.07-ppx-sexp-message)
5223 ("ocaml-ppx-sexp-value" ,ocaml4.07-ppx-sexp-value)
5224 ("ocaml-ppx-typerep-conv" ,ocaml4.07-ppx-typerep-conv)
5225 ("ocaml-ppx-variants-conv" ,ocaml4.07-ppx-variants-conv)
5226 ("ocaml-migrate-parsetree"
5227 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5228 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
5229 (properties `((upstream-name . "ppx_jane")))
5230 (home-page "https://github.com/janestreet/ppx_jane")
5231 (synopsis "Standard Jane Street ppx rewriters")
5232 (description "This package installs a ppx-jane executable, which is a ppx
5233 driver including all standard Jane Street ppx rewriters.")
5234 (license license:asl2.0)))
5235
5236 (define-public ocaml4.07-splittable-random
5237 (package
5238 (name "ocaml4.07-splittable-random")
5239 (version "0.11.0")
5240 (source (origin
5241 (method url-fetch)
5242 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5243 (version-major+minor version)
5244 "/files/splittable_random-v" version ".tar.gz"))
5245 (sha256
5246 (base32
5247 "0l1wbd881mymlnpzlq5q53mmdz3g5d7qjhyc7lfaq1x0iaccn5lc"))))
5248 (build-system dune-build-system)
5249 (arguments
5250 `(#:ocaml ,ocaml-4.07
5251 #:findlib ,ocaml4.07-findlib
5252 #:dune ,ocaml4.07-dune))
5253 (propagated-inputs
5254 `(("ocaml-base" ,ocaml4.07-base)
5255 ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane)
5256 ("ocaml-migrate-parsetree"
5257 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))))
5258 (properties `((upstream-name . "splittable_random")))
5259 (home-page "https://github.com/janestreet/splittable_random")
5260 (synopsis "PRNG that can be split into independent streams")
5261 (description "This package provides a splittable
5262 @acronym{PRNG,pseudo-random number generator} functions like a PRNG that can
5263 be used as a stream of random values; it can also be split to produce a
5264 second, independent stream of random values.
5265
5266 This library implements a splittable pseudo-random number generator that sacrifices
5267 cryptographic-quality randomness in favor of performance.")
5268 (license license:asl2.0)))
5269
5270 (define-public ocaml4.07-jane-street-headers
5271 (package
5272 (name "ocaml4.07-jane-street-headers")
5273 (version "0.11.0")
5274 (source (origin
5275 (method url-fetch)
5276 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5277 (version-major+minor version)
5278 "/files/jane-street-headers-v" version ".tar.gz"))
5279 (sha256
5280 (base32
5281 "0afhzm08l9v883fhpqqh2lmy7az609pxif40bp7x1sk8c0yszqsh"))))
5282 (build-system dune-build-system)
5283 (arguments
5284 `(#:test-target "."
5285 #:ocaml ,ocaml-4.07
5286 #:findlib ,ocaml4.07-findlib
5287 #:dune ,ocaml4.07-dune))
5288 (home-page "https://github.com/janestreet/jane-street-headers")
5289 (synopsis "Jane Street C header files")
5290 (description "This package provides C header files shared between the
5291 various Jane Street packages.")
5292 (license license:asl2.0)))
5293
5294 (define-public ocaml4.07-configurator
5295 (package
5296 (name "ocaml4.07-configurator")
5297 (version "0.11.0")
5298 (source (origin
5299 (method url-fetch)
5300 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5301 (version-major+minor version)
5302 "/files/configurator-v" version ".tar.gz"))
5303 (sha256
5304 (base32
5305 "0kwgi3sh92v4n242dk5hgpwd85zzgnczgbkqi0q0kr6m93zgbf7p"))))
5306 (build-system dune-build-system)
5307 (arguments
5308 ;; No tests
5309 `(#:tests? #f
5310 #:ocaml ,ocaml-4.07
5311 #:findlib ,ocaml4.07-findlib
5312 #:dune ,ocaml4.07-dune))
5313 (propagated-inputs
5314 `(("ocaml-base" ,ocaml4.07-base)
5315 ("ocaml-stdio" ,ocaml4.07-stdio)))
5316 (home-page "https://github.com/janestreet/configurator")
5317 (synopsis "Helper library for gathering system configuration")
5318 (description "Configurator is a small library that helps writing OCaml
5319 scripts that test features available on the system, in order to generate config.h
5320 files for instance.
5321
5322 Configurator allows one to:
5323 @itemize
5324 @item test if a C program compiles
5325 @item query pkg-config
5326 @item import #define from OCaml header files
5327 @item generate config.h file
5328 @end itemize")
5329 (license license:asl2.0)))
5330
5331 (define-public ocaml4.07-spawn
5332 (package
5333 (name "ocaml4.07-spawn")
5334 (version "0.13.0")
5335 (source (origin
5336 (method git-fetch)
5337 (uri (git-reference
5338 (url "https://github.com/janestreet/spawn")
5339 (commit (string-append "v" version))))
5340 (file-name (git-file-name name version))
5341 (sha256
5342 (base32
5343 "1w003k1kw1lmyiqlk58gkxx8rac7dchiqlz6ah7aj7bh49b36ppf"))))
5344 (build-system dune-build-system)
5345 (arguments
5346 `(#:phases
5347 (modify-phases %standard-phases
5348 (add-before 'check 'fix-tests
5349 (lambda _
5350 (substitute* "test/tests.ml"
5351 (("/bin/pwd") (which "pwd"))
5352 (("/bin/echo") (which "echo")))
5353 #t)))
5354 #:ocaml ,ocaml-4.07
5355 #:findlib ,ocaml4.07-findlib
5356 #:dune ,ocaml4.07-dune))
5357 (native-inputs
5358 `(("ocaml-ppx-expect" ,ocaml4.07-ppx-expect)))
5359 (home-page "https://github.com/janestreet/spawn")
5360 (synopsis "Spawning sub-processes")
5361 (description
5362 "Spawn is a small library exposing only one functionality: spawning sub-process.
5363
5364 It has three main goals:
5365
5366 @itemize
5367 @item provide missing features of Unix.create_process such as providing a
5368 working directory,
5369 @item provide better errors when a system call fails in the
5370 sub-process. For instance if a command is not found, you get a proper
5371 @code{Unix.Unix_error} exception,
5372 @item improve performances by using vfork when available. It is often
5373 claimed that nowadays fork is as fast as vfork, however in practice
5374 fork takes time proportional to the process memory while vfork is
5375 constant time. In application using a lot of memory, vfork can be
5376 thousands of times faster than fork.
5377 @end itemize")
5378 (license license:asl2.0)))
5379
5380 (define-public ocaml4.07-core
5381 (package
5382 (name "ocaml4.07-core")
5383 (version "0.11.3")
5384 (source (origin
5385 (method git-fetch)
5386 (uri (git-reference
5387 (url "https://github.com/janestreet/core")
5388 (commit (string-append "v" version))))
5389 (file-name (git-file-name name version))
5390 (sha256
5391 (base32
5392 "0pzl8n09z4f3i7z2wq4cjxfqrr8mj6xcdp7rbg0nxap2zdhjgvrq"))))
5393 (build-system dune-build-system)
5394 (arguments
5395 `(#:package "core"
5396 #:tests? #f; Require a cyclic dependency: core_extended
5397 #:ocaml ,ocaml-4.07
5398 #:findlib ,ocaml4.07-findlib
5399 #:dune ,ocaml4.07-dune))
5400 (propagated-inputs
5401 `(("ocaml-base" ,ocaml4.07-base)
5402 ("ocaml-configurator" ,ocaml4.07-configurator)
5403 ("ocaml-core-kernel" ,ocaml4.07-core-kernel)
5404 ("ocaml-ppx-assert" ,ocaml4.07-ppx-assert)
5405 ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane)
5406 ("ocaml-sexplib" ,ocaml4.07-sexplib)
5407 ("ocaml-spawn" ,ocaml4.07-spawn)
5408 ("ocaml-stdio" ,ocaml4.07-stdio)
5409 ("ocaml-migrate-parsetree"
5410 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))
5411 ("ocaml-ppxlib" ,ocaml4.07-ppxlib)))
5412 (home-page "https://github.com/janestreet/core")
5413 (synopsis "Alternative to OCaml's standard library")
5414 (description "The Core suite of libraries is an alternative to OCaml's
5415 standard library that was developed by Jane Street.")
5416 ;; Also contains parts of OCaml, relicensed to asl2.0, as permitted
5417 ;; by OCaml's license for consortium members (see THIRD-PARTY.txt).
5418 (license license:asl2.0)))
5419
5420 (define-public ocaml4.07-core-kernel
5421 (package
5422 (name "ocaml4.07-core-kernel")
5423 (version "0.11.1")
5424 (source (origin
5425 (method git-fetch)
5426 (uri (git-reference
5427 (url "https://github.com/janestreet/core_kernel")
5428 (commit (string-append "v" version))))
5429 (file-name (git-file-name name version))
5430 (sha256
5431 (base32
5432 "1dg7ygy7i64c5gaakb1cp1b26p9ks81vbxmb8fd7jff2q60j2z2g"))))
5433 (build-system dune-build-system)
5434 (arguments
5435 ;; Cyclic dependency with ocaml-core
5436 `(#:tests? #f
5437 #:ocaml ,ocaml-4.07
5438 #:findlib ,ocaml4.07-findlib
5439 #:dune ,ocaml4.07-dune))
5440 (propagated-inputs
5441 `(("ocaml-base" ,ocaml4.07-base)
5442 ("ocaml-bin-prot" ,ocaml4.07-bin-prot)
5443 ("ocaml-configurator" ,ocaml4.07-configurator)
5444 ("ocaml-fieldslib" ,ocaml4.07-fieldslib)
5445 ("ocaml-jane-street-headers" ,ocaml4.07-jane-street-headers)
5446 ("ocaml-ppx-assert" ,ocaml4.07-ppx-assert)
5447 ("ocaml-ppx-base" ,ocaml4.07-ppx-base)
5448 ("ocaml-ppx-hash" ,ocaml4.07-ppx-hash)
5449 ("ocaml-ppx-inline-test" ,ocaml4.07-ppx-inline-test)
5450 ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane)
5451 ("ocaml-ppx-sexp-conv" ,ocaml4.07-ppx-sexp-conv)
5452 ("ocaml-ppx-sexp-message" ,ocaml4.07-ppx-sexp-message)
5453 ("ocaml-sexplib" ,ocaml4.07-sexplib)
5454 ("ocaml-splittable-random" ,ocaml4.07-splittable-random)
5455 ("ocaml-stdio" ,ocaml4.07-stdio)
5456 ("ocaml-typerep" ,ocaml4.07-typerep)
5457 ("ocaml-variantslib" ,ocaml4.07-variantslib)
5458 ("ocaml-migrate-parsetree"
5459 ,(package-with-ocaml4.07 ocaml-migrate-parsetree))))
5460 (properties `((upstream-name . "core_kernel")))
5461 (home-page "https://github.com/janestreet/core_kernel")
5462 (synopsis "Portable standard library for OCaml")
5463 (description "Core is an alternative to the OCaml standard library.
5464
5465 Core_kernel is the system-independent part of Core. It is aimed for cases when
5466 the full Core is not available, such as in Javascript.")
5467 (license (list
5468 ;; this package and parts of OCaml, relicensed by janestreet
5469 license:asl2.0
5470 ;; MLton and sjs
5471 license:expat))))
5472
5473 (define-public ocaml-markup
5474 (package
5475 (name "ocaml-markup")
5476 (version "0.8.2")
5477 (home-page "https://github.com/aantron/markup.ml")
5478 (source
5479 (origin
5480 (method git-fetch)
5481 (uri (git-reference
5482 (url (string-append home-page ".git"))
5483 (commit version)))
5484 (file-name (git-file-name name version))
5485 (sha256
5486 (base32
5487 "13zcrwzjmifniv3bvjbkd2ah8wwa3ld75bxh1d8hrzdvfxzh9szn"))))
5488 (build-system dune-build-system)
5489 (arguments
5490 `(#:package "markup"))
5491 (inputs
5492 `(("libev" ,libev)))
5493 (propagated-inputs
5494 `(("ocaml-bisect-ppx" ,ocaml-bisect-ppx)
5495 ("ocaml-uchar" ,ocaml-uchar)
5496 ("ocaml-uutf" ,ocaml-uutf)
5497 ("ocaml-lwt" ,ocaml-lwt)))
5498 (native-inputs
5499 `(("ocaml-ounit" ,ocaml-ounit)
5500 ("pkg-config" ,pkg-config)))
5501 (synopsis "Error-recovering functional HTML5 and XML parsers and writers")
5502 (description "Markup.ml provides an HTML parser and an XML parser. The
5503 parsers are wrapped in a simple interface: they are functions that transform
5504 byte streams to parsing signal streams. Streams can be manipulated in various
5505 ways, such as processing by fold, filter, and map, assembly into DOM tree
5506 structures, or serialization back to HTML or XML.
5507
5508 Both parsers are based on their respective standards. The HTML parser, in
5509 particular, is based on the state machines defined in HTML5.
5510
5511 The parsers are error-recovering by default, and accept fragments. This makes
5512 it very easy to get a best-effort parse of some input. The parsers can,
5513 however, be easily configured to be strict, and to accept only full documents.
5514
5515 Apart from this, the parsers are streaming (do not build up a document in
5516 memory), non-blocking (can be used with threading libraries), lazy (do not
5517 consume input unless the signal stream is being read), and process the input in
5518 a single pass. They automatically detect the character encoding of the input
5519 stream, and convert everything to UTF-8.")
5520 (license license:bsd-3)))
5521
5522 (define-public ocaml-tyxml
5523 (package
5524 (name "ocaml-tyxml")
5525 (version "4.3.0")
5526 (source
5527 (origin
5528 (method git-fetch)
5529 (uri (git-reference
5530 (url "https://github.com/ocsigen/tyxml")
5531 (commit version)))
5532 (file-name (git-file-name name version))
5533 (sha256
5534 (base32
5535 "0wv19xipkj8l2sks1h53105ywbjwk7q93fb7b8al4a2g9wr109c0"))))
5536 (build-system dune-build-system)
5537 (inputs
5538 `(("ocaml-re" ,ocaml-re)
5539 ("ocaml-seq" ,ocaml-seq)
5540 ("ocaml-uutf" ,ocaml-uutf)
5541 ("ocaml-ppx-tools-versioned" ,ocaml-ppx-tools-versioned)
5542 ("ocaml-markup" ,ocaml-markup)))
5543 (native-inputs
5544 `(("ocaml-alcotest" ,ocaml-alcotest)))
5545 (arguments `(#:package "tyxml"))
5546 (home-page "https://github.com/ocsigen/tyxml/")
5547 (synopsis "TyXML is a library for building correct HTML and SVG documents")
5548 (description "TyXML provides a set of convenient combinators that uses the
5549 OCaml type system to ensure the validity of the generated documents. TyXML can
5550 be used with any representation of HTML and SVG: the textual one, provided
5551 directly by this package, or DOM trees (@code{js_of_ocaml-tyxml}) virtual DOM
5552 (@code{virtual-dom}) and reactive or replicated trees (@code{eliom}). You can
5553 also create your own representation and use it to instantiate a new set of
5554 combinators.")
5555 (license license:lgpl2.1)))
5556
5557 (define-public ocaml-bisect-ppx
5558 (package
5559 (name "ocaml-bisect-ppx")
5560 (version "1.4.2")
5561 (source
5562 (origin
5563 (method git-fetch)
5564 (uri (git-reference
5565 (url "https://github.com/aantron/bisect_ppx")
5566 (commit version)))
5567 (file-name (git-file-name name version))
5568 (sha256
5569 (base32
5570 "0900vli5kw7s5kdam0n4cqsfsfqb7mdb3azn3i55595gilg1vyn8"))))
5571 (build-system dune-build-system)
5572 (propagated-inputs
5573 `(("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)
5574 ("ocaml-ppx-tools-versioned" ,ocaml-ppx-tools-versioned)
5575 ("ocaml-ounit" ,ocaml-ounit)))
5576 (arguments
5577 `(#:phases
5578 (modify-phases %standard-phases
5579 (add-before 'build 'fix-deprecated
5580 (lambda _
5581 ;; Fixed upstream in 22dd1ad9a0c9629f60599c22d82c6488394d6d32, but
5582 ;; not in a release yet.
5583 (substitute* "src/ppx/instrument.ml"
5584 (("module Ast = Ast_405")
5585 "module Ast = Migrate_parsetree.Ast_405
5586 module Ast_405 = Ast"))
5587 #t)))))
5588 (home-page "https://github.com/aantron/bisect_ppx")
5589 (synopsis "Code coverage for OCaml")
5590 (description "Bisect_ppx helps you test thoroughly. It is a small
5591 preprocessor that inserts instrumentation at places in your code, such as
5592 if-then-else and match expressions. After you run tests, Bisect_ppx gives a
5593 nice HTML report showing which places were visited and which were missed.
5594
5595 Usage is simple - add package bisect_ppx when building tests, run your tests,
5596 then run the Bisect_ppx report tool on the generated visitation files.")
5597 (license license:mpl2.0)))
5598
5599 (define-public ocaml4.07-odoc
5600 (package
5601 (name "ocaml4.07-odoc")
5602 (version "1.4.2")
5603 (source
5604 (origin
5605 (method git-fetch)
5606 (uri (git-reference
5607 (url "https://github.com/ocaml/odoc")
5608 (commit version)))
5609 (file-name (git-file-name name version))
5610 (sha256
5611 (base32 "0rvhx139jx6wmlfz355mja6mk03x4swq1xxvk5ky6jzhalq3cf5i"))))
5612 (build-system dune-build-system)
5613 (arguments
5614 `(#:ocaml ,ocaml-4.07
5615 #:findlib ,ocaml4.07-findlib
5616 #:dune ,ocaml4.07-dune))
5617 (inputs
5618 `(("ocaml-alcotest" ,(package-with-ocaml4.07 ocaml-alcotest))
5619 ("ocaml-markup" ,(package-with-ocaml4.07 ocaml-markup))
5620 ("ocaml-sexplib" ,ocaml4.07-sexplib)
5621 ("ocaml-re" ,(package-with-ocaml4.07 ocaml-re))
5622 ("ocaml-uutf" ,(package-with-ocaml4.07 ocaml-uutf))))
5623 (native-inputs
5624 `(("ocaml-astring" ,(package-with-ocaml4.07 ocaml-astring))
5625 ("ocaml-cmdliner" ,(package-with-ocaml4.07 ocaml-cmdliner))
5626 ("ocaml-cppo" ,(package-with-ocaml4.07 ocaml-cppo))
5627 ("ocaml-fpath" ,(package-with-ocaml4.07 ocaml-fpath))
5628 ("ocaml-result" ,(package-with-ocaml4.07 ocaml-result))
5629 ("ocaml-tyxml" ,(package-with-ocaml4.07 ocaml-tyxml))
5630 ("ocaml-bisect-ppx" ,(package-with-ocaml4.07 ocaml-bisect-ppx))))
5631 (home-page "https://github.com/ocaml/odoc")
5632 (synopsis "OCaml documentation generator")
5633 (description "Odoc is a documentation generator for OCaml. It reads
5634 @emph{doc comments}, delimited with @code{(** ... *)}, and outputs
5635 @acronym{HTML}.
5636
5637 Text inside doc comments is marked up in ocamldoc syntax. Odoc's main
5638 advantage over ocamldoc is an accurate cross-referencer, which handles the
5639 complexity of the OCaml module system.")
5640 (license license:isc)))
5641
5642 (define-public ocaml4.07-fftw3
5643 (package
5644 (name "ocaml4.07-fftw3")
5645 (version "0.8.4")
5646 (source
5647 (origin
5648 (method git-fetch)
5649 (uri (git-reference
5650 (url "https://github.com/Chris00/fftw-ocaml")
5651 (commit version)))
5652 (file-name (git-file-name name version))
5653 (sha256
5654 (base32
5655 "0l66yagjkwdcib6q55wd8wiap50vi23qiahkghlvm28z7nvbclfk"))))
5656 (build-system dune-build-system)
5657 (arguments
5658 `(#:tests? #t
5659 #:test-target "tests"
5660 #:ocaml ,ocaml-4.07
5661 #:findlib ,ocaml4.07-findlib
5662 #:dune ,ocaml4.07-dune))
5663 (propagated-inputs
5664 `(("fftw" ,fftw)
5665 ("fftwf" ,fftwf)))
5666 (native-inputs
5667 `(("ocaml-cppo" ,(package-with-ocaml4.07 ocaml-cppo))
5668 ("ocaml-lacaml" ,ocaml4.07-lacaml)))
5669 (home-page
5670 "https://github.com/Chris00/fftw-ocaml")
5671 (synopsis
5672 "Bindings to FFTW3")
5673 (description
5674 "Bindings providing OCaml support for the seminal Fast Fourier Transform
5675 library FFTW.")
5676 (license license:lgpl2.1))) ; with static linking exception.
5677
5678 (define-public ocaml4.07-lacaml
5679 (package
5680 (name "ocaml4.07-lacaml")
5681 (version "11.0.5")
5682 (source
5683 (origin
5684 (method git-fetch)
5685 (uri (git-reference
5686 (url "https://github.com/mmottl/lacaml")
5687 (commit version)))
5688 (file-name (git-file-name name version))
5689 (sha256
5690 (base32
5691 "180yb79a3qgx067qcpm50q12hrimjygf06rgkzbish9d1zfm670c"))))
5692 (build-system dune-build-system)
5693 (arguments
5694 `(#:tests? #f ; No test target.
5695 #:ocaml ,ocaml-4.07
5696 #:findlib ,ocaml4.07-findlib
5697 #:dune ,ocaml4.07-dune))
5698 (native-inputs
5699 `(("openblas" ,openblas)
5700 ("lapack" ,lapack)
5701 ("ocaml-base" ,ocaml4.07-base)
5702 ("ocaml-stdio" ,ocaml4.07-stdio)))
5703 (home-page "https://mmottl.github.io/lacaml/")
5704 (synopsis
5705 "OCaml-bindings to BLAS and LAPACK")
5706 (description
5707 "Lacaml interfaces the BLAS-library (Basic Linear Algebra Subroutines) and
5708 LAPACK-library (Linear Algebra routines). It also contains many additional
5709 convenience functions for vectors and matrices.")
5710 (license license:lgpl2.1)))
5711
5712 (define-public ocaml-cairo2
5713 (package
5714 (name "ocaml-cairo2")
5715 (version "0.6.1")
5716 (source (origin
5717 (method git-fetch)
5718 (uri (git-reference
5719 (url "https://github.com/Chris00/ocaml-cairo")
5720 (commit version)))
5721 (file-name (git-file-name name version))
5722 (sha256
5723 (base32
5724 "0wzysis9fa850s68qh8vrvqc6svgllhwra3kzll2ibv0wmdqrich"))))
5725 (build-system dune-build-system)
5726 (arguments
5727 `(#:test-target "tests"))
5728 (inputs
5729 `(("cairo" ,cairo)
5730 ("gtk+-2" ,gtk+-2)
5731 ("lablgtk" ,lablgtk)))
5732 (native-inputs
5733 `(("pkg-config" ,pkg-config)))
5734 (home-page "https://github.com/Chris00/ocaml-cairo")
5735 (synopsis "Binding to Cairo, a 2D Vector Graphics Library")
5736 (description "Ocaml-cairo2 is a binding to Cairo, a 2D graphics library
5737 with support for multiple output devices. Currently supported output targets
5738 include the X Window System, Quartz, Win32, image buffers, PostScript, PDF,
5739 and SVG file output.")
5740 (license license:lgpl3+)))
5741
5742 (define-public lablgtk3
5743 (package
5744 (name "lablgtk")
5745 (version "3.0.beta8")
5746 (source (origin
5747 (method git-fetch)
5748 (uri (git-reference
5749 (url "https://github.com/garrigue/lablgtk")
5750 (commit version)))
5751 (file-name (git-file-name name version))
5752 (sha256
5753 (base32
5754 "08pgwnia240i2rw1rbgiahg673kwa7b6bvhsg3z4b47xr5sh9pvz"))))
5755 (build-system dune-build-system)
5756 (arguments
5757 `(#:tests? #t
5758 #:test-target "."
5759 #:phases
5760 (modify-phases %standard-phases
5761 (add-before 'build 'make-writable
5762 (lambda _
5763 (for-each (lambda (file)
5764 (chmod file #o644))
5765 (find-files "." "."))
5766 #t)))))
5767 (propagated-inputs
5768 `(("ocaml-cairo2" ,ocaml-cairo2)))
5769 (inputs
5770 `(("camlp5" ,camlp5)
5771 ("gtk+" ,gtk+)
5772 ("gtksourceview-3" ,gtksourceview-3)
5773 ("gtkspell3" ,gtkspell3)))
5774 (native-inputs
5775 `(("pkg-config" ,pkg-config)))
5776 (home-page "https://github.com/garrigue/lablgtk")
5777 (synopsis "OCaml interface to GTK+3")
5778 (description "LablGtk is an OCaml interface to GTK+ 1.2, 2.x and 3.x. It
5779 provides a strongly-typed object-oriented interface that is compatible with the
5780 dynamic typing of GTK+. Most widgets and methods are available. LablGtk
5781 also provides bindings to gdk-pixbuf, the GLArea widget (in combination with
5782 LablGL), gnomecanvas, gnomeui, gtksourceview, gtkspell, libglade (and it can
5783 generate OCaml code from .glade files), libpanel, librsvg and quartz.")
5784 ;; Version 2 only, with linking exception.
5785 (license license:lgpl2.0)))