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