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