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-2022 Julien Lepiller <julien@lepiller.eu>
10 ;;; Copyright © 2017 Ben Woodcroft <donttrustben@gmail.com>
11 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
12 ;;; Copyright © 2018 Peter Kreye <kreyepr@gmail.com>
13 ;;; Copyright © 2018, 2019 Gabriel Hondet <gabrielhondet@gmail.com>
14 ;;; Copyright © 2018 Kei Kebreau <kkebreau@posteo.net>
15 ;;; Copyright © 2019 Ricardo Wurmus <rekado@elephly.net>
16 ;;; Copyright © 2020 Brett Gilio <brettg@gnu.org>
17 ;;; Copyright © 2020 Marius Bakke <marius@gnu.org>
18 ;;; Copyright © 2020, 2021 Simon Tournier <zimon.toutoune@gmail.com>
19 ;;; Copyright © 2020 divoplade <d@divoplade.fr>
20 ;;; Copyright © 2020, 2021, 2022 pukkamustard <pukkamustard@posteo.net>
21 ;;; Copyright © 2021 aecepoglu <aecepoglu@fastmail.fm>
22 ;;; Copyright © 2021 Sharlatan Hellseher <sharlatanus@gmail.com>
23 ;;; Copyright © 2021 Xinglu Chen <public@yoctocell.xyz>
24 ;;; Copyright © 2021 Ivan Gankevich <i.gankevich@spbu.ru>
25 ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be>
26 ;;; Copyright © 2021 Sarah Morgensen <iskarian@mgsn.dev>
27 ;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
29 ;;; This file is part of GNU Guix.
31 ;;; GNU Guix is free software; you can redistribute it and/or modify it
32 ;;; under the terms of the GNU General Public License as published by
33 ;;; the Free Software Foundation; either version 3 of the License, or (at
34 ;;; your option) any later version.
36 ;;; GNU Guix is distributed in the hope that it will be useful, but
37 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
38 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
39 ;;; GNU General Public License for more details.
41 ;;; You should have received a copy of the GNU General Public License
42 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
44 (define-module (gnu packages ocaml)
45 #:use-module (gnu packages)
46 #:use-module (gnu packages algebra)
47 #:use-module (gnu packages autotools)
48 #:use-module (gnu packages base)
49 #:use-module (gnu packages bash)
50 #:use-module (gnu packages bison)
51 #:use-module (gnu packages boost)
52 #:use-module (gnu packages compression)
53 #:use-module (gnu packages curl)
54 #:use-module (gnu packages emacs)
55 #:use-module (gnu packages emacs-xyz)
56 #:use-module (gnu packages flex)
57 #:use-module (gnu packages gcc)
58 #:use-module (gnu packages ghostscript)
59 #:use-module (gnu packages glib)
60 #:use-module (gnu packages gnome)
61 #:use-module (gnu packages gtk)
62 #:use-module (gnu packages guile)
63 #:use-module (gnu packages libevent)
64 #:use-module (gnu packages libffi)
65 #:use-module (gnu packages llvm)
66 #:use-module (gnu packages m4)
67 #:use-module (gnu packages maths)
68 #:use-module (gnu packages multiprecision)
69 #:use-module (gnu packages ncurses)
70 #:use-module (gnu packages node)
71 #:use-module (gnu packages pcre)
72 #:use-module (gnu packages perl)
73 #:use-module (gnu packages pkg-config)
74 #:use-module (gnu packages protobuf)
75 #:use-module (gnu packages python)
76 #:use-module (gnu packages python-xyz)
77 #:use-module (gnu packages rsync)
78 #:use-module (gnu packages sdl)
79 #:use-module (gnu packages sqlite)
80 #:use-module (gnu packages tex)
81 #:use-module (gnu packages texinfo)
82 #:use-module (gnu packages time)
83 #:use-module (gnu packages tls)
84 #:use-module (gnu packages version-control)
85 #:use-module (gnu packages virtualization)
86 #:use-module (gnu packages web)
87 #:use-module (gnu packages web-browsers)
88 #:use-module (gnu packages xml)
89 #:use-module (gnu packages xorg)
90 #:use-module (guix build-system dune)
91 #:use-module (guix build-system emacs)
92 #:use-module (guix build-system gnu)
93 #:use-module (guix build-system ocaml)
94 #:use-module (guix download)
95 #:use-module (guix gexp)
96 #:use-module (guix git-download)
97 #:use-module ((guix licenses) #:prefix license:)
98 #:use-module (guix packages)
99 #:use-module (guix svn-download)
100 #:use-module (guix utils)
101 #:use-module ((srfi srfi-1) #:hide (zip)))
103 ;; A shortcut for files from ocaml forge. Downloaded files are computed from
104 ;; their number, not their name.
105 (define (ocaml-forge-uri name version file-number)
106 (string-append "https://forge.ocamlcore.org/frs/download.php/"
107 (number->string file-number) "/" name "-" version
110 (define (janestreet-origin name version hash)
111 (origin (method url-fetch)
112 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
113 (version-major+minor version) "/files/"
114 name "-v" (version-major+minor+point version)
116 (sha256 (base32 hash))))
118 (define-public camlboot
119 (let ((commit "45045d0afa82f7e9b7ea07314aab08be2d3cd64b")
123 (version (git-version "0.0.0" revision commit))
127 (url "https://github.com/Ekdohibs/camlboot")
130 (file-name (git-file-name name version))
133 "1f5gl3hzvixbgk0v3kmxiyn432znyy3jh5fa65cfzcaxzgfv1i1c"))
134 (modules '((guix build utils)))
137 ;; Remove bootstrap binaries and pre-generated source files,
138 ;; to ensure we actually bootstrap properly.
139 (for-each delete-file (find-files "ocaml-src" "^.depend$"))
140 (delete-file "ocaml-src/boot/ocamlc")
141 (delete-file "ocaml-src/boot/ocamllex")
145 (chmod file (logior (stat:mode (stat file)) #o200)))
146 (find-files "." "."))))))
147 (build-system gnu-build-system)
149 `(#:make-flags (list "_boot/ocamlc") ; build target
150 #:tests? #f ; no tests
152 (modify-phases %standard-phases
154 (add-before 'build 'no-autocompile
156 ;; prevent a guile warning
157 (setenv "GUILE_AUTO_COMPILE" "0")))
159 (lambda* (#:key outputs #:allow-other-keys)
160 (let* ((out (assoc-ref outputs "out"))
161 (bin (string-append out "/bin")))
163 (install-file "_boot/ocamlc" bin)
164 (rename-file "miniml/interp/lex.byte" "ocamllex")
165 (install-file "ocamllex" bin)))))))
169 ;; 10 hours, mostly for arm, more than 1 expected even on x86_64
170 `((max-silent-time . 36000)))
171 (home-page "https://github.com/Ekdohibs/camlboot")
172 (synopsis "OCaml source bootstrap")
173 (description "OCaml is written in OCaml. Its sources contain a pre-compiled
174 bytecode version of @command{ocamlc} and @command{ocamllex} that are used to
175 build the next version of the compiler. Camlboot implements a bootstrap for
176 the OCaml compiler and provides a bootstrapped equivalent to these files.
178 It contains a compiler for a small subset of OCaml written in Guile Scheme,
179 an interpreter for OCaml written in that subset and a manually-written lexer
180 for OCaml. These elements eliminate the need for the binary bootstrap in
181 OCaml and can effectively bootstrap OCaml 4.07.
183 This package produces a native @command{ocamlc} and a bytecode @command{ocamllex}.")
184 (license license:expat))))
186 (define-public ocaml-4.14
193 "http://caml.inria.fr/pub/distrib/ocaml-"
194 (version-major+minor version)
195 "/ocaml-" version ".tar.xz"))
198 "0axcc7c23pf4qinz4vxgkba6pwziwbp9i2ydwzar7x9zlp6diarn"))))
199 (build-system gnu-build-system)
201 (list (search-path-specification
202 (variable "OCAMLPATH")
203 (files (list "lib/ocaml" "lib/ocaml/site-lib")))
204 (search-path-specification
205 (variable "CAML_LD_LIBRARY_PATH")
206 (files (list "lib/ocaml/site-lib/stubslibs"
207 "lib/ocaml/site-lib/stublibs")))))
209 (list perl pkg-config))
211 (list libx11 libiberty ;needed for objdump support
212 zlib)) ;also needed for objdump support
214 `(#:configure-flags '("--enable-ocamltest")
215 #:test-target "tests"
216 #:make-flags '("world.opt")
218 (modify-phases %standard-phases
219 (add-after 'unpack 'patch-/bin/sh-references
220 (lambda* (#:key inputs #:allow-other-keys)
221 (let* ((sh (search-input-file inputs "/bin/sh"))
222 (quoted-sh (string-append "\"" sh "\"")))
223 (with-fluids ((%default-port-encoding #f))
229 (format (current-error-port) "\
230 patch-/bin/sh-references: ~a: changing `\"/bin/sh\"' to `~a'~%"
233 (find-files "." "\\.ml$")))))))))
234 (home-page "https://ocaml.org/")
235 (synopsis "The OCaml programming language")
237 "OCaml is a general purpose industrial-strength programming language with
238 an emphasis on expressiveness and safety. Developed for more than 20 years at
239 Inria it benefits from one of the most advanced type systems and supports
240 functional, imperative and object-oriented styles of programming.")
241 ;; The compiler is distributed under qpl1.0 with a change to choice of
242 ;; law: the license is governed by the laws of France. The library is
243 ;; distributed under lgpl2.0.
244 (license (list license:qpl license:lgpl2.0))))
246 (define-public ocaml-4.09
253 "http://caml.inria.fr/pub/distrib/ocaml-"
254 (version-major+minor version)
255 "/ocaml-" version ".tar.xz"))
256 (patches (search-patches "ocaml-4.09-multiple-definitions.patch"))
259 "1v3z5ar326f3hzvpfljg4xj8b9lmbrl53fn57yih1bkbx3gr3yzj"))))
262 (modify-phases %standard-phases
263 (add-after 'unpack 'patch-/bin/sh-references
264 (lambda* (#:key inputs #:allow-other-keys)
265 (let* ((sh (search-input-file inputs "/bin/sh"))
266 (quoted-sh (string-append "\"" sh "\"")))
267 (with-fluids ((%default-port-encoding #f))
273 (format (current-error-port) "\
274 patch-/bin/sh-references: ~a: changing `\"/bin/sh\"' to `~a'~%"
277 (find-files "." "\\.ml$"))))))
280 (invoke "make" "-j" (number->string (parallel-job-count))
284 (with-directory-excursion "testsuite"
285 (invoke "make" "all")))))))))
287 ;; This package is a bootstrap package for ocaml-4.07. It builds from camlboot,
288 ;; using the upstream sources for ocaml 4.07. It installs a bytecode ocamllex
289 ;; and ocamlc, the bytecode interpreter ocamlrun, and generated .depend files
290 ;; that we otherwise remove for bootstrap purposes.
291 (define ocaml-4.07-boot
299 "http://caml.inria.fr/pub/distrib/ocaml-"
300 (version-major+minor version)
301 "/ocaml-" version ".tar.xz"))
304 "1f07hgj5k45cylj1q3k5mk8yi02cwzx849b1fwnwia8xlcfqpr6z"))
305 (patches (search-patches "ocaml-multiple-definitions.patch"))
306 (modules '((guix build utils)))
309 ;; Remove bootstrap binaries and pre-generated source files,
310 ;; to ensure we actually bootstrap properly.
311 (for-each delete-file (find-files "." "^.depend$"))
312 (delete-file "boot/ocamlc")
313 (delete-file "boot/ocamllex")))))
317 (modify-phases %standard-phases
318 (add-before 'configure 'copy-bootstrap
319 (lambda* (#:key inputs #:allow-other-keys)
320 (let ((camlboot (assoc-ref inputs "camlboot")))
321 (copy-file (string-append camlboot "/bin/ocamllex") "boot/ocamllex")
322 (copy-file (string-append camlboot "/bin/ocamlc") "boot/ocamlc")
323 (chmod "boot/ocamllex" #o755)
324 (chmod "boot/ocamlc" #o755))))
326 (lambda* (#:key outputs #:allow-other-keys)
327 (let* ((out (assoc-ref outputs "out"))
328 (mandir (string-append out "/share/man")))
329 (invoke "./configure"
331 "--mandir" mandir))))
333 (lambda* (#:key parallel-build? #:allow-other-keys)
334 (define* (make . args)
336 (append (if parallel-build?
337 `("-j" ,(number->string (parallel-job-count)))
340 ;; create empty .depend files because they are included by various
341 ;; Makefiles, and they have no rule to generate them.
342 (invoke "touch" ".depend" "stdlib/.depend" "byterun/.depend"
343 "tools/.depend" "lex/.depend" "asmrun/.depend"
344 "debugger/.depend" "ocamltest/.depend" "ocamldoc/.depend"
345 "ocamldoc/stdlib_non_prefixed/.depend"
346 "otherlibs/bigarray/.depend" "otherlibs/graph/.depend"
347 "otherlibs/raw_spacetime_lib/.depend" "otherlibs/str/.depend"
348 "otherlibs/systhreads/.depend" "otherlibs/threads/.depend"
349 "otherlibs/unix/.depend" "otherlibs/win32unix/.depend")
350 ;; We cannot build ocamldep until we have created all the .depend
351 ;; files, so replace it with ocamlc -depend.
352 (substitute* "tools/Makefile"
353 (("\\$\\(CAMLRUN\\) ./ocamldep") "../boot/ocamlc -depend"))
354 (substitute* '("otherlibs/graph/Makefile"
355 "otherlibs/systhreads/Makefile"
356 "otherlibs/threads/Makefile"
357 "otherlibs/unix/Makefile")
358 (("\\$\\(CAMLRUN\\) ../../tools/ocamldep")
359 "../../boot/ocamlc -depend"))
360 (substitute* '("otherlibs/bigarray/Makefile"
361 "otherlibs/raw_spacetime_lib/Makefile"
362 "otherlibs/str/Makefile"
363 "otherlibs/win32unix/Makefile")
364 (("\\$\\(CAMLRUN\\) \\$\\(ROOTDIR\\)/tools/ocamldep")
365 "../../boot/ocamlc -depend"))
366 ;; Ensure we copy needed file, so we can generate a proper .depend
367 (substitute* "ocamldoc/Makefile"
368 (("include Makefile.unprefix")
369 "include Makefile.unprefix
370 depend: $(STDLIB_MLIS) $(STDLIB_DEPS)"))
371 ;; Generate required tools for `alldepend'
372 (make "-C" "byterun" "depend")
373 (make "-C" "byterun" "all")
374 (copy-file "byterun/ocamlrun" "boot/ocamlrun")
376 (copy-file "yacc/ocamlyacc" "boot/ocamlyacc")
377 (make "-C" "stdlib" "sys.ml")
378 (make "-C" "stdlib" "CAMLDEP=../boot/ocamlc -depend" "depend")
379 ;; Build and copy files later used by `tools'
380 (make "-C" "stdlib" "COMPILER="
381 "CAMLC=../boot/ocamlc -use-prims ../byterun/primitives"
385 (copy-file file (string-append "boot/" (basename file))))
386 (cons* "stdlib/stdlib.cma" "stdlib/std_exit.cmo" "stdlib/camlheader"
387 (find-files "stdlib" ".*.cmi$")))
388 (symlink "../byterun/libcamlrun.a" "boot/libcamlrun.a")
389 ;; required for ocamldoc/stdlib_non_prefixed
390 (make "parsing/parser.mli")
391 ;; required for dependencies
393 "CAMLC=../boot/ocamlc -nostdlib -I ../boot -use-prims ../byterun/primitives -I .."
394 "make_opcodes" "cvt_emit")
395 ;; generate all remaining .depend files
397 (string-append "ocamllex=" (getcwd) "/boot/ocamlrun "
398 (getcwd) "/boot/ocamllex")
399 (string-append "CAMLDEP=" (getcwd) "/boot/ocamlc -depend")
400 (string-append "OCAMLDEP=" (getcwd) "/boot/ocamlc -depend")
401 (string-append "ocamldep=" (getcwd) "/boot/ocamlc -depend"))
403 (make "CAMLC=boot/ocamlc -nostdlib -I boot -use-prims byterun/primitives"
407 "CAMLC=../boot/ocamlc -strict-sequence -nostdlib -I ../boot -use-prims ../byterun/primitives"
410 (lambda* (#:key outputs #:allow-other-keys)
411 (let* ((out (assoc-ref outputs "out"))
412 (bin (string-append out "/bin"))
413 (depends (string-append out "/share/depends")))
416 (install-file "ocamlc" bin)
417 (install-file "lex/ocamllex" bin)
420 (let ((dir (string-append depends "/" (dirname file))))
422 (install-file file dir)))
423 (find-files "." "^\\.depend$"))))))))
425 `(("camlboot" ,camlboot)
427 ("pkg-config" ,pkg-config)))))
429 (define-public ocaml-4.07
431 (inherit ocaml-4.07-boot)
434 (substitute-keyword-arguments (package-arguments ocaml-4.09)
436 `(modify-phases ,phases
437 (add-before 'configure 'copy-bootstrap
438 (lambda* (#:key inputs #:allow-other-keys)
439 (let ((ocaml (assoc-ref inputs "ocaml")))
440 (copy-file (string-append ocaml "/bin/ocamllex") "boot/ocamllex")
441 (copy-file (string-append ocaml "/bin/ocamlc") "boot/ocamlc")
442 (chmod "boot/ocamllex" #o755)
443 (chmod "boot/ocamlc" #o755)
444 (let ((rootdir (getcwd)))
445 (with-directory-excursion (string-append ocaml "/share/depends")
448 (copy-file file (string-append rootdir "/" file)))
449 (find-files "." ".")))))))
451 (lambda* (#:key outputs #:allow-other-keys)
452 (let* ((out (assoc-ref outputs "out"))
453 (mandir (string-append out "/share/man")))
454 ;; Custom configure script doesn't recognize
455 ;; --prefix=<PREFIX> syntax (with equals sign).
456 (invoke "./configure"
458 "--mandir" mandir))))))))
460 `(("ocaml" ,ocaml-4.07-boot)
462 ("pkg-config" ,pkg-config)))))
464 (define-public ocaml ocaml-4.14)
466 (define-public ocamlbuild
474 (url "https://github.com/ocaml/ocamlbuild")
476 (file-name (git-file-name name version))
478 (base32 "00ma0g6ajll9awp2bp303bawac8ync4k9w2a6vix0k4nw3003gb4"))))
479 (build-system ocaml-build-system)
482 ,#~(list (string-append "OCAMLBUILD_PREFIX=" #$output)
483 (string-append "OCAMLBUILD_BINDIR=" #$output "/bin")
484 (string-append "OCAMLBUILD_LIBDIR=" #$output
485 "/lib/ocaml/site-lib")
486 (string-append "OCAMLBUILD_MANDIR=" #$output "/share/man"))
488 (modify-phases %standard-phases
490 ; some failures because of changes in OCaml's error message formating
492 (home-page "https://github.com/ocaml/ocamlbuild")
493 (synopsis "OCaml build tool")
494 (description "OCamlbuild is a generic build tool, that has built-in rules
495 for building OCaml library and programs.")
496 (license license:lgpl2.1+)))
498 (define-public camlidl
506 (url "https://github.com/xavierleroy/camlidl")
507 (commit "camlidl109")))
509 (base32 "0zrkaq7fk23b2b9vg6jwdjx7l0hdqp4synbbrw1zcg8gjf6n3c80"))
510 (file-name (git-file-name name version))))
511 (build-system gnu-build-system)
513 `(#:tests? #f ;; No test suite
517 "BINDIR=" (assoc-ref %outputs "out") "/bin")
519 "OCAMLLIB=" (assoc-ref %outputs "out") "/lib/ocaml/site-lib/camlidl"))
521 (modify-phases %standard-phases
525 (copy-file "config/Makefile.unix" "config/Makefile")
526 ;; Note: do not pass '-jN' as this appears to not be
527 ;; parallel-safe (race condition related to libcamlidl.a).
528 (invoke "make" "all")
530 (add-before 'install 'create-target-directories
531 (lambda* (#:key outputs #:allow-other-keys)
532 (let ((out (string-append (assoc-ref outputs "out"))))
534 (string-append out "/bin"))
536 (string-append out "/lib/ocaml/site-lib/camlidl/stublibs"))
538 (string-append out "/lib/ocaml/site-lib/camlidl/caml")))
540 (add-after 'install 'install-meta
541 (lambda* (#:key outputs #:allow-other-keys)
542 (let ((out (assoc-ref outputs "out")))
544 (string-append out "/lib/ocaml/site-lib/camlidl/META")
548 "description = \"Stub code generator for OCaml/C interface\"
549 version = \"" ,version "\"
551 archive(byte) = \"com.cma\"
552 archive(native) = \"com.cmxa\"")))))
556 (home-page "https://github.com/xavierleroy/camlidl")
557 (synopsis "Stub code generator for OCaml/C interface")
559 "Camlidl is a stub code generator for Objective Caml. It generates stub
560 code for interfacing Caml with C from an IDL description of the C functions.")
561 (license license:lgpl2.1)))
563 (define-public ocaml-extlib
565 (name "ocaml-extlib")
569 (uri (string-append "https://ygrek.org/p/release/ocaml-extlib/"
570 "extlib-" version ".tar.gz"))
573 "0npq4hq3zym8nmlyji7l5cqk6drx2rkcx73d60rxqh5g8dla8p4k"))))
574 (build-system ocaml-build-system)
577 (modify-phases %standard-phases
578 (delete 'configure))))
581 (home-page "https://github.com/ygrek/ocaml-extlib")
582 (synopsis "Complete and small extension for OCaml standard library")
583 (description "This library adds new functions to OCaml standard library
584 modules, modifies some functions in order to get better performances or
585 safety (tail-recursive) and also provides new modules which should be useful
586 for day to day programming.")
587 ;; With static-linking exception
588 (license license:lgpl2.1+)))
590 (define-public ocaml-cudf
597 (uri "https://gforge.inria.fr/frs/download.php/36602/cudf-0.9.tar.gz")
600 "0771lwljqwwn3cryl0plny5a5dyyrj4z6bw66ha5n8yfbpcy8clr"))))
601 (build-system ocaml-build-system)
602 (propagated-inputs (list ocaml-extlib))
604 (list perl ocamlbuild ocaml-ounit))
609 (string-append "BINDIR=" #$output "/bin"))
611 (modify-phases %standard-phases
612 (delete 'configure))))
613 (home-page "https://www.mancoosi.org/cudf/")
614 (synopsis "CUDF library (part of the Mancoosi tools)")
615 (description "CUDF (for Common Upgradeability Description Format) is a
616 format for describing upgrade scenarios in package-based Free and Open Source
617 Software distribution.")
618 ;; With static-linking exception
619 (license license:lgpl2.1+)))
621 (define-public ocaml-mccs
628 (url "https://github.com/AltGr/ocaml-mccs")
630 (file-name (git-file-name name version))
633 "17bvm0jhhs8h3p5sbb65asj53a8sxl634cc0kvcivpams74837zq"))))
634 (build-system dune-build-system)
635 (propagated-inputs (list ocaml-cudf))
636 (home-page "https://www.i3s.unice.fr/~cpjm/misc/")
637 (synopsis "Upgrade path problem solver")
638 (description "Mccs (Multi Criteria CUDF Solver) is a CUDF problem solver.
639 Mccs take as input a CUDF problem and computes the best solution according to
640 a set of criteria. It relies on a Integer Programming solver or a
641 Pseudo Boolean solver to achieve its task. Mccs can use a wide set of
642 underlying solvers like Cplex, Gurobi, Lpsolver, Glpk, CbC, SCIP or WBO.")
646 ;; With static-linking exception
649 (define-public ocaml-dose3
655 (uri "https://gforge.inria.fr/frs/download.php/file/36063/dose3-5.0.1.tar.gz")
658 "00yvyfm4j423zqndvgc1ycnmiffaa2l9ab40cyg23pf51qmzk2jm"))
661 "ocaml-dose3-add-unix-dependency.patch"
662 "ocaml-dose3-Fix-for-ocaml-4.06.patch"
663 "ocaml-dose3-dont-make-printconf.patch"
664 "ocaml-dose3-Install-mli-cmx-etc.patch"))))
665 (build-system ocaml-build-system)
667 `(#:tests? #f ;the test suite requires python 2
669 ,#~(list (string-append "SHELL="
670 #+(file-append (canonical-package bash-minimal)
673 ,#~(list (string-append "LIBDIR=" #$output "/lib/ocaml/site-lib"))))
675 (list ocaml-graph ocaml-cudf ocaml-extlib ocaml-re))
681 (home-page "https://www.mancoosi.org/software/")
682 (synopsis "Package distribution management framework")
683 (description "Dose3 is a framework made of several OCaml libraries for
684 managing distribution packages and their dependencies. Though not tied to
685 any particular distribution, dose3 constitutes a pool of libraries which
686 enable analyzing packages coming from various distributions. Besides basic
687 functionalities for querying and setting package properties, dose3 also
688 implements algorithms for solving more complex problems such as monitoring
689 package evolutions, correct and complete dependency resolution and
690 repository-wide uninstallability checks.")
691 ;; with static-linking exception
692 (license license:lgpl2.1+)))
694 (define-public ocaml-down
701 (uri (string-append "https://erratique.ch/software/down/releases/down-"
705 "1q467y6qz96ndiybpmggdcnrcip49kxw2i93pb54j1xjzkv1vnl1"))))
706 (build-system ocaml-build-system)
708 `(#:tests? #f ;no tests
710 (modify-phases %standard-phases
713 ,#~(list "build" "--lib-dir"
714 (string-append #$output "/lib/ocaml/site-lib"))))
716 (list ocaml-findlib ocamlbuild ocaml-topkg opam))
717 (home-page "https://erratique.ch/software/down")
718 (synopsis "OCaml toplevel (REPL) upgrade")
719 (description "Down is an unintrusive user experience upgrade for the
720 @command{ocaml} toplevel (REPL).
722 Simply load the zero dependency @code{down} library in the @command{ocaml}
723 toplevel and you get line edition, history, session support and identifier
724 completion and documentation with @command{ocp-index}.
726 Add this to your @file{~/.ocamlinit}:
732 You may also need to add this to your @file{~/.ocamlinit} and declare
733 the environment variable @code{OCAML_TOPLEVEL_PATH}:
737 try Topdirs.dir_directory (Sys.getenv \"OCAML_TOPLEVEL_PATH\")
744 let () = String.split_on_char ':' (Sys.getenv \"OCAMLPATH\")
745 |> List.filter (fun x -> Filename.check_suffix x \"/site-lib\")
746 |> List.map (fun x -> x ^ \"/toplevel\")
747 (* remove the line below if you don't want to see the text
748 every time you start the toplevel *)
749 |> List.map (fun x -> Printf.printf \"adding directory %s\\n\" x; x)
750 |> List.iter Topdirs.dir_directory;;
752 (license license:isc)))
754 (define-public ocaml-opam-file-format
756 (name "ocaml-opam-file-format")
761 (url "https://github.com/ocaml/opam-file-format")
763 (file-name (git-file-name name version))
766 "0dmnb1mqdy4913f9ma446hi5m99q7hfibj6j0m8x2wsfnfy2fw62"))))
767 (build-system ocaml-build-system)
769 `(#:tests? #f; No tests
770 #:make-flags ,#~(list (string-append "LIBDIR=" #$output
771 "/lib/ocaml/site-lib"))
773 (modify-phases %standard-phases
774 (delete 'configure))))
775 (home-page "https://opam.ocaml.org")
776 (synopsis "Parser and printer for the opam file syntax")
777 (description "This package contains a parser and a pretty-printer for
778 the opam file format.")
779 ;; With static-linking exception
780 (license license:lgpl2.1+)))
789 (url "https://github.com/ocaml/opam")
791 (file-name (git-file-name name version))
794 "0mdr32mg63yaw89p44zx8b9dxp1167ckmlxkp8svd6fwgb3z49yx"))))
795 (build-system dune-build-system)
799 (modify-phases %standard-phases
800 (add-before 'build 'pre-build
801 (lambda* (#:key inputs make-flags #:allow-other-keys)
802 (let ((bash (assoc-ref inputs "bash"))
803 (bwrap (search-input-file inputs "/bin/bwrap")))
804 (substitute* "src/core/opamSystem.ml"
806 (string-append "\"" bash "/bin/sh\""))
809 ;; Use bwrap from the store directly.
810 (substitute* "src/state/shellscripts/bwrap.sh"
811 (("-v bwrap") (string-append "-v " bwrap))
812 (("exec bwrap") (string-append "exec " bwrap))
813 ;; Mount /gnu and /run/current-system in the
814 ;; isolated environment when building with opam.
815 ;; This is necessary for packages to find external
816 ;; dependencies, such as a C compiler, make, etc...
817 (("^add_sys_mounts /usr")
818 (string-append "add_sys_mounts "
820 " /run/current-system /usr")))
821 (substitute* "src/client/opamInitDefaults.ml"
822 (("\"bwrap\"") (string-append "\"" bwrap "\""))))))
823 (add-before 'check 'prepare-checks
824 (lambda* (#:key inputs #:allow-other-keys)
825 ;; Opam tests need to run an isolated environment from a writable
827 (mkdir-p "test-home")
828 (setenv "HOME" (string-append (getcwd) "/test-home"))
830 ;; Opam tests require data from opam-repository. Instead of
831 ;; downloading them with wget from the guix environment, copy the
832 ;; content to the expected directory.
833 (substitute* "tests/reftests/dune.inc"
834 (("tar -C.*opam-archive-([0-9a-f]*)[^)]*" _ commit)
835 (string-append "rmdir %{targets}) (run cp -r "
836 (assoc-ref inputs (string-append "opam-repo-" commit))
837 "/ %{targets}) (run chmod +w -R %{targets}"))
838 (("wget[^)]*") "touch %{targets}")
839 ;; Disable a failing test because of different line wrapping
840 (("diff cli-versioning.test cli-versioning.out") "run true")
841 ;; Disable a failing test because it tries to clone a git
842 ;; repository from inside bwrap
843 (("diff upgrade-format.test upgrade-format.out") "run true"))
844 (substitute* "tests/reftests/dune"
845 ;; Because of our changes to the previous file, we cannot check
846 ;; it can be regenerated
847 (("diff dune.inc dune.inc.gen") "run true"))
848 ;; Ensure we can run the generated build.sh (no /bin/sh)
849 (substitute* '("tests/reftests/legacy-local.test"
850 "tests/reftests/legacy-git.test")
853 (search-input-file inputs "/bin/sh"))))
854 (substitute* "tests/reftests/testing-env"
856 (string-append "OPAMSTRICT=1\nLIBRARY_PATH="
857 (assoc-ref inputs "libc") "/lib"))))))))
859 (let ((opam-repo (lambda (commit hash)
863 (url "https://github.com/ocaml/opam-repository")
865 (file-name (git-file-name "opam-repo" commit))
866 (sha256 (base32 hash))))))
868 ("ocaml-cppo" ,ocaml-cppo)
873 ("python" ,python-wrapper)
879 ("opam-repo-009e00fa" ,(opam-repo "009e00fa86300d11c311309a2544e5c6c3eb8de2"
880 "1wwy0rwrsjf4q10j1rh1dazk32fbzhzy6f7zl6qmndidx9b1bq7w"))
881 ("opam-repo-ad4dd344" ,(opam-repo "ad4dd344fe5cd1cab49ced49d6758a9844549fb4"
882 "1a1qj47kj8xjdnc4zc50ijrix1kym1n7k20n3viki80a7518baw8"))
883 ("opam-repo-c1d23f0e" ,(opam-repo "c1d23f0e17ec83a036ebfbad1c78311b898a2ca0"
884 "0j9abisx3ifzm66ci3p45mngmz4f0fx7yd9jjxrz3f8w5jffc9ii"))
885 ("opam-repo-f372039d" ,(opam-repo "f372039db86a970ef3e662adbfe0d4f5cd980701"
886 "0ld7fcry6ss6fmrpswvr6bikgx299w97h0gwrjjh7kd7rydsjdws")))))
888 (list ocaml ncurses curl bubblewrap))
890 (list ocaml-cmdliner ocaml-dose3 ocaml-mccs ocaml-opam-file-format
892 (home-page "http://opam.ocamlpro.com/")
893 (synopsis "Package manager for OCaml")
895 "OPAM is a tool to manage OCaml packages. It supports multiple
896 simultaneous compiler installations, flexible package constraints, and a
897 Git-friendly development workflow.")
899 ;; The 'LICENSE' file waives some requirements compared to LGPLv3.
900 (license license:lgpl3)))
902 (define-public ocaml-camlp-streams
904 (name "ocaml-camlp-streams")
910 (url "https://github.com/ocaml/camlp-streams")
911 (commit (string-append "v" version))))
912 (file-name (git-file-name name version))
914 (base32 "1wd5k0irzwi841b27pbx0n5fdybbgx97184zm8cjajizd2j8w0g5"))))
915 (build-system dune-build-system)
919 (home-page "https://github.com/ocaml/camlp-streams")
920 (synopsis "Stream and Genlex libraries for use with Camlp4 and Camlp5")
922 "This package provides two library modules:
925 @item Stream: imperative streams, with in-place update and memoization of
926 the latest element produced.
927 @item Genlex: a small parameterized lexical analyzer producing streams of
928 tokens from streams of characters.
931 The two modules are designed for use with Camlp4 and Camlp5: The stream
932 patterns and stream expressions of Camlp4/Camlp5 consume and produce data of
933 type 'a Stream.t. The Genlex tokenizer can be used as a simple lexical
934 analyzer for Camlp4/Camlp5-generated parsers.
936 The Stream module can also be used by hand-written recursive-descent parsers,
937 but is not very convenient for this purpose.
939 The Stream and Genlex modules have been part of the OCaml standard library for a
940 long time, and have been distributed as part of the core OCaml system. They
941 will be removed from the OCaml standard library at some future point, but will
942 be maintained and distributed separately in the camlpstreams package.")
943 (license license:lgpl2.1)))
945 (define-public camlp5
953 (url "https://github.com/camlp5/camlp5")
954 (commit (string-append "rel" version))))
955 (file-name (git-file-name name version))
957 (base32 "1fnvmaw9cland09pjx5h6w3f6fz9s23l4nbl4m9fcaa2i4dpraz6"))))
958 (build-system gnu-build-system)
960 `(#:tests? #f ; XXX TODO figure out how to run the tests
962 (modify-phases %standard-phases
964 (lambda* (#:key outputs #:allow-other-keys)
965 (let* ((out (assoc-ref outputs "out"))
966 (mandir (string-append out "/share/man")))
967 ;; Custom configure script doesn't recognize
968 ;; --prefix=<PREFIX> syntax (with equals sign).
969 (invoke "./configure"
971 "--mandir" mandir))))
972 (add-before 'build 'fix-/bin-references
974 (substitute* "config/Makefile"
979 (invoke "make" "-j" (number->string
980 (parallel-job-count))
982 ;; Required for findlib to find camlp5's libraries
983 (add-after 'install 'install-meta
984 (lambda* (#:key outputs #:allow-other-keys)
985 (install-file "etc/META" (string-append (assoc-ref outputs "out")
986 "/lib/ocaml/camlp5/"))
989 (list ocaml ocaml-camlp-streams))
991 (list perl ocaml-findlib))
992 (home-page "https://camlp5.github.io/")
993 (synopsis "Pre-processor Pretty Printer for OCaml")
995 "Camlp5 is a Pre-Processor-Pretty-Printer for Objective Caml. It offers
996 tools for syntax (Stream Parsers and Grammars) and the ability to modify the
997 concrete syntax of the language (Quotations, Syntax Extensions).")
998 ;; Most files are distributed under bsd-3, but ocaml_stuff/* is under qpl.
999 (license (list license:bsd-3 license:qpl))))
1001 (define-public hevea
1007 (uri (string-append "http://hevea.inria.fr/old/"
1008 "hevea-" version ".tar.gz"))
1011 "1jwydkb9ldb1sx815c364dxgr569f2rbbzgxbn2kanrybpdbm2gi"))))
1012 (build-system gnu-build-system)
1018 `(#:tests? #f ; no test suite
1019 #:make-flags (list (string-append "PREFIX=" %output))
1020 #:phases (modify-phases %standard-phases
1022 (add-before 'build 'patch-/bin/sh
1024 (substitute* "_tags"
1025 (("/bin/sh") (which "sh")))
1027 (home-page "http://hevea.inria.fr/")
1028 (synopsis "LaTeX to HTML translator")
1030 "HeVeA is a LaTeX to HTML translator that generates modern HTML 5. It is
1031 written in Objective Caml.")
1032 (license license:qpl)))
1034 (define-public ocaml-num
1042 (url "https://github.com/ocaml/num")
1043 (commit (string-append "v" version))))
1044 (file-name (git-file-name name version))
1046 (base32 "1vzdnvpj5dbj3ifx03v25pj2jj1ccav072v4d29pk1czdba2lzfc"))))
1047 (build-system dune-build-system)
1050 (modify-phases %standard-phases
1051 (add-after 'unpack 'fix-race
1053 ;; There's a race between bng.o and bng_generic.c. Both depend on
1054 ;; the architecture specific bng.c, but only the latter declares
1056 (mkdir-p "_build/default/src")
1059 (copy-file f (string-append "_build/default/" f)))
1060 (find-files "src" "bng_.*\\.c")))))))
1061 (home-page "https://github.com/ocaml/num")
1062 (synopsis "Arbitrary-precision integer and rational arithmetic")
1063 (description "OCaml-Num contains the legacy Num library for
1064 arbitrary-precision integer and rational arithmetic that used to be part of
1065 the OCaml core distribution.")
1066 (license license:lgpl2.1+))); with linking exception
1068 (define-public emacs-tuareg
1069 ;; Last upstream release on Sept., 14th, 2018, since then "Package cl
1070 ;; deprecated" or 'lexical-binding' and others had been fixed.
1071 (let ((commit "ccde45bbc292123ec20617f1af7f7e19f7481545")
1074 (name "emacs-tuareg")
1075 (version (git-version "2.2.0" revision commit))
1080 (url "https://github.com/ocaml/tuareg")
1082 (file-name (git-file-name name version))
1084 (base32 "1yxv4bnqarilnpg5j7wywall8170hwvm0q4xx06yqjgcn8pq1lac"))))
1085 (build-system gnu-build-system)
1087 `(("emacs" ,emacs-minimal)
1091 (modify-phases %standard-phases
1092 (add-after 'unpack 'make-git-checkout-writable
1094 (for-each make-file-writable (find-files "."))
1097 (add-before 'install 'fix-install-path
1098 (lambda* (#:key outputs #:allow-other-keys)
1099 (substitute* "Makefile"
1100 (("/emacs/site-lisp")
1101 (string-append (assoc-ref %outputs "out")
1102 "/share/emacs/site-lisp/")))
1104 (add-after 'install 'post-install
1105 (lambda* (#:key outputs #:allow-other-keys)
1106 (symlink "tuareg.el"
1107 (string-append (assoc-ref outputs "out")
1108 "/share/emacs/site-lisp/"
1109 "tuareg-autoloads.el"))
1111 (home-page "https://github.com/ocaml/tuareg")
1112 (synopsis "OCaml programming mode, REPL, debugger for Emacs")
1113 (description "Tuareg helps editing OCaml code, to highlight important
1114 parts of the code, to run an OCaml REPL, and to run the OCaml debugger within
1116 (license license:gpl2+))))
1118 (define-public ocaml-menhir
1120 (name "ocaml-menhir")
1121 (version "20220210")
1126 (url "https://gitlab.inria.fr/fpottier/menhir.git")
1128 (file-name (git-file-name name version))
1130 (base32 "0f31isr3cyiishflz6qr4xc3gp9xwf32r3vxdvm5wnr2my1fnn1n"))))
1131 (build-system dune-build-system)
1135 `(#:tests? #f)) ; No check target
1136 (properties `((ocaml4.07-variant . ,(delay (strip-ocaml4.07-variant ocaml-menhir)))))
1137 (home-page "http://gallium.inria.fr/~fpottier/menhir/")
1138 (synopsis "Parser generator")
1139 (description "Menhir is a parser generator. It turns high-level grammar
1140 specifications, decorated with semantic actions expressed in the OCaml
1141 programming language into parsers, again expressed in OCaml. It is based on
1142 Knuth’s LR(1) parser construction technique.")
1143 ;; The file src/standard.mly and all files listed in src/mnehirLib.mlpack
1144 ;; that have an *.ml or *.mli extension are GPL licensed. All other files
1145 ;; are QPL licensed.
1146 (license (list license:gpl2+ license:qpl))))
1148 (define-public ocaml-bigarray-compat
1150 (name "ocaml-bigarray-compat")
1155 (url "https://github.com/mirage/bigarray-compat")
1156 (commit (string-append "v" version))))
1157 (file-name (git-file-name name version))
1160 "0hif5baiwswdblymyfbxh9066pfqynlz5vj3b2brpn0a12k6i5fq"))))
1161 (build-system dune-build-system)
1163 `(#:tests? #f)); no tests
1164 (home-page "https://github.com/mirage/bigarray-compat")
1165 (synopsis "OCaml compatibility library")
1166 (description "This package contains a compatibility library for
1167 @code{Stdlib.Bigarray} in OCaml.")
1168 (license license:isc)))
1170 (define-public lablgtk
1177 (url "https://github.com/garrigue/lablgtk")
1179 (file-name (git-file-name name version))
1182 "179ipx0c6bpxm4gz0syxgqy09dp5p4x9qsdil7s9jlx8ffg1mm0w"))))
1183 (build-system gnu-build-system)
1186 ("findlib" ,ocaml-findlib)
1187 ("pkg-config" ,pkg-config)))
1188 ;; FIXME: Add inputs gtkgl-2.0, libpanelapplet-2.0, gtkspell-2.0,
1189 ;; and gtk+-quartz-2.0 once available.
1198 `(#:tests? #f ; no check target
1200 ;; opt: also install cmxa files
1201 #:make-flags (list "all" "opt"
1202 (string-append "FINDLIBDIR="
1203 (assoc-ref %outputs "out")
1205 ;; Occasionally we would get "Error: Unbound module GtkThread" when
1206 ;; compiling 'gtkThInit.ml', with 'make -j'. So build sequentially.
1207 #:parallel-build? #f
1210 (modify-phases %standard-phases
1211 (add-before 'install 'prepare-install
1212 (lambda* (#:key inputs outputs #:allow-other-keys)
1213 (let ((out (assoc-ref outputs "out"))
1214 (ocaml (assoc-ref inputs "ocaml")))
1215 ;; Install into the output and not the ocaml directory.
1216 (mkdir-p (string-append out "/lib/ocaml"))
1217 (substitute* "config.make"
1220 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-lablgtk))))
1221 (home-page "http://lablgtk.forge.ocamlcore.org/")
1222 (synopsis "GTK+ bindings for OCaml")
1224 "LablGtk is an OCaml interface to GTK+ 1.2 and 2.x. It provides
1225 a strongly-typed object-oriented interface that is compatible with the
1226 dynamic typing of GTK+. Most widgets and methods are available. LablGtk
1227 also provides bindings to
1228 gdk-pixbuf, the GLArea widget (in combination with LablGL), gnomecanvas,
1229 gnomeui, gtksourceview, gtkspell,
1230 libglade (and it an generate OCaml code from .glade files),
1231 libpanel, librsvg and quartz.")
1232 (license license:lgpl2.1)))
1234 (define-public ocaml4.07-lablgtk
1237 (name "ocaml4.07-lablgtk")
1239 `(("ocaml" ,ocaml-4.07)
1240 ("findlib" ,ocaml4.07-findlib)
1241 ("pkg-config" ,pkg-config)))
1244 (define-public unison
1251 (url "https://github.com/bcpierce00/unison")
1252 (commit (string-append "v" version))))
1253 (file-name (git-file-name name version))
1256 "1bykiyc0dc5pkw8x370qkg2kygq9pq7yqzsgczd3y13b6ivm4sdq"))
1257 (patches (search-patches "unison-fix-ocaml-4.08.patch"))))
1258 (build-system gnu-build-system)
1260 "doc")) ; 1.9 MiB of documentation
1262 `(("ocaml" ,ocaml-4.09)
1263 ;; For documentation
1264 ("ghostscript" ,ghostscript)
1265 ("texlive" ,(texlive-updmap.cfg
1266 (list texlive-fonts-ec texlive-dvips-l3backend)))
1271 `(#:parallel-build? #f
1272 #:parallel-tests? #f
1273 #:test-target "selftest"
1274 #:tests? #f ; Tests require writing to $HOME.
1275 ; If some $HOME is provided, they fail with the message
1276 ; "Fatal error: Skipping some tests -- remove me!"
1278 (modify-phases %standard-phases
1280 (add-before 'install 'prepare-install
1281 (lambda* (#:key outputs #:allow-other-keys)
1282 (let* ((out (assoc-ref outputs "out"))
1283 (bin (string-append out "/bin")))
1285 (setenv "HOME" out) ; forces correct INSTALLDIR in Makefile
1287 (add-after 'install 'install-fsmonitor
1288 (lambda* (#:key outputs #:allow-other-keys)
1289 (let* ((out (assoc-ref outputs "out"))
1290 (bin (string-append out "/bin")))
1291 ;; 'unison-fsmonitor' is used in "unison -repeat watch" mode.
1292 (install-file "src/unison-fsmonitor" bin)
1294 (add-after 'install 'install-doc
1295 (lambda* (#:key outputs #:allow-other-keys)
1296 (let ((doc (string-append (assoc-ref outputs "doc")
1297 "/share/doc/unison")))
1299 ;; Remove an '\n' that prevents the doc to be generated
1300 ;; correctly with newer hevea.
1301 (substitute* "doc/local.tex"
1302 (("----SNIP----.*") "----SNIP----"))
1303 ;; This file needs write-permissions, because it's
1304 ;; overwritten by 'docs' during documentation generation.
1305 (chmod "src/strings.ml" #o600)
1306 (invoke "make" "docs"
1307 "TEXDIRECTIVES=\\\\draftfalse")
1308 (for-each (lambda (f)
1309 (install-file f doc))
1311 (string-append "doc/unison-manual." ext))
1312 ;; Install only html documentation,
1313 ;; since the build is currently
1314 ;; non-reproducible with the ps, pdf,
1316 '(;; "ps" "pdf" "dvi"
1319 (home-page "https://www.cis.upenn.edu/~bcpierce/unison/")
1320 (synopsis "File synchronizer")
1322 "Unison is a file-synchronization tool. It allows two replicas of
1323 a collection of files and directories to be stored on different hosts
1324 (or different disks on the same host), modified separately, and then
1325 brought up to date by propagating the changes in each replica
1327 (license license:gpl3+)))
1329 (define-public ocaml-findlib
1331 (name "ocaml-findlib")
1335 (uri (string-append "http://download.camlcity.org/download/"
1336 "findlib" "-" version ".tar.gz"))
1339 "0hfcwamcvinmww59b5i4yxbf0kxyzkp5qv3d1c7ybn9q52vgq463"))))
1340 (build-system gnu-build-system)
1344 `(#:tests? #f ; no test suite
1345 #:parallel-build? #f
1346 #:make-flags (list "all" "opt")
1347 #:phases (modify-phases %standard-phases
1350 (lambda* (#:key inputs outputs #:allow-other-keys)
1351 (let ((out (assoc-ref outputs "out")))
1354 "-bindir" (string-append out "/bin")
1355 "-config" (string-append out "/etc/ocamfind.conf")
1356 "-mandir" (string-append out "/share/man")
1357 "-sitelib" (string-append out "/lib/ocaml/site-lib")
1360 (lambda* (#:key outputs #:allow-other-keys)
1361 (let ((out (assoc-ref outputs "out")))
1362 (invoke "make" "install"
1363 (string-append "OCAML_CORE_STDLIB="
1364 out "/lib/ocaml/site-lib"))))))))
1365 (home-page "http://projects.camlcity.org/projects/findlib.html")
1366 (synopsis "Management tool for OCaml libraries")
1368 "The \"findlib\" library provides a scheme to manage reusable software
1369 components (packages), and includes tools that support this scheme. Packages
1370 are collections of OCaml modules for which metainformation can be stored. The
1371 packages are kept in the file system hierarchy, but with strict directory
1372 structure. The library contains functions to look the directory up that
1373 stores a package, to query metainformation about a package, and to retrieve
1374 dependency information about multiple packages. There is also a tool that
1375 allows the user to enter queries on the command-line. In order to simplify
1376 compilation and linkage, there are new frontends of the various OCaml
1377 compilers that can directly deal with packages.")
1378 (license license:x11)))
1380 (define-public ocaml4.07-findlib
1382 (inherit ocaml-findlib)
1383 (name "ocaml4.07-findlib")
1385 (list m4 ocaml-4.07))))
1387 (define-public ocaml4.09-findlib
1389 (inherit ocaml-findlib)
1390 (name "ocaml4.09-findlib")
1392 (list m4 ocaml-4.09))))
1394 (define-public ocaml-ounit2
1396 (name "ocaml-ounit2")
1401 (url "https://github.com/gildor478/ounit.git")
1402 (commit (string-append "v" version))))
1403 (file-name (git-file-name name version))
1406 "04c841hpk2yij370w30w3pis8nibnr28v74mpq2qz7z5gb8l07p1"))))
1407 (build-system dune-build-system)
1409 (list ocaml-lwt ocaml-stdlib-shims))
1410 (home-page "https://github.com/gildor478/ounit")
1411 (synopsis "Unit testing framework for OCaml")
1412 (description "OUnit2 is a unit testing framework for OCaml. It is similar
1413 to JUnit and other XUnit testing frameworks.")
1414 (license license:expat)))
1416 ;; note that some tests may hang for no obvious reason.
1417 (define-public ocaml-ounit
1419 (inherit ocaml-ounit2)
1420 (name "ocaml-ounit")
1423 (modify-phases %standard-phases
1426 (invoke "make" "install-ounit" ,(string-append "version="
1427 (package-version ocaml-ounit2))))))))
1429 (list ocaml-ounit2))
1430 (home-page "http://ounit.forge.ocamlcore.org")
1431 (synopsis "Unit testing framework for OCaml")
1432 (description "Unit testing framework for OCaml. It is similar to JUnit and
1433 other XUnit testing frameworks.")
1434 (license license:expat)))
1436 (define-public camlzip
1443 (url "https://github.com/xavierleroy/camlzip")
1444 (commit (string-append
1446 (string-join (string-split version #\.) "")))))
1447 (file-name (git-file-name name version))
1450 "16jnn3czxnvyjngnz167x5kw097k7izdqvkix8qvgvhdmgvqm89b"))))
1451 (build-system ocaml-build-system)
1456 (modify-phases %standard-phases
1457 (delete 'configure))
1458 #:install-target "install-findlib"
1460 ,#~(list "all" "allopt"
1461 (string-append "INSTALLDIR=" #$output "/lib/ocaml"))))
1462 (home-page "https://github.com/xavierleroy/camlzip")
1463 (synopsis "Provides easy access to compressed files")
1464 (description "Provides easy access to compressed files in ZIP, GZIP and
1465 JAR format. It provides functions for reading from and writing to compressed
1466 files in these formats.")
1467 (license license:lgpl2.1+)))
1469 (define-public ocamlmod
1475 (uri (ocaml-forge-uri name version 1702))
1478 "0cgp9qqrq7ayyhddrmqmq1affvfqcn722qiakjq4dkywvp67h4aa"))))
1479 (build-system ocaml-build-system)
1481 `(("ounit" ,ocaml-ounit)
1482 ("ocamlbuild" ,ocamlbuild)))
1485 (modify-phases %standard-phases
1486 ;; Tests are done during build.
1488 (home-page "https://forge.ocamlcore.org/projects/ocamlmod")
1489 (synopsis "Generate modules from OCaml source files")
1490 (description "Generate modules from OCaml source files.")
1491 (license license:lgpl2.1+))) ; with an exception
1493 (define-public ocaml-zarith
1495 (name "ocaml-zarith")
1500 (url "https://github.com/ocaml/Zarith")
1501 (commit (string-append "release-" version))))
1502 (file-name (git-file-name name version))
1505 "1jslm1rv1j0ya818yh23wf3bb6hz7qqj9pn5fwl45y9mqyqa01s9"))))
1506 (build-system ocaml-build-system)
1512 `(#:tests? #f ; no test target
1514 (modify-phases %standard-phases
1516 (lambda _ (invoke "./configure")))
1517 (add-after 'install 'move-sublibs
1518 (lambda* (#:key outputs #:allow-other-keys)
1519 (let* ((out (assoc-ref outputs "out"))
1520 (lib (string-append out "/lib/ocaml/site-lib")))
1521 (mkdir-p (string-append lib "/stublibs"))
1522 (rename-file (string-append lib "/zarith/dllzarith.so")
1523 (string-append lib "/stublibs/dllzarith.so"))))))))
1524 (home-page "https://forge.ocamlcore.org/projects/zarith/")
1525 (synopsis "Implements arbitrary-precision integers")
1526 (description "Implements arithmetic and logical operations over
1527 arbitrary-precision integers. It uses GMP to efficiently implement arithmetic
1528 over big integers. Small integers are represented as Caml unboxed integers,
1529 for speed and space economy.")
1530 (license license:lgpl2.1+))) ; with an exception
1532 (define-public ocaml-frontc
1534 (name "ocaml-frontc")
1539 (url "https://github.com/BinaryAnalysisPlatform/FrontC")
1540 (commit (string-append "v" version))))
1541 (file-name (git-file-name name version))
1544 "1mi1vh4qgscnb470qwidccaqd068j1bqlz6pf6wddk21paliwnqb"))))
1545 (build-system dune-build-system)
1547 `(#:test-target "test.t"
1549 (modify-phases %standard-phases
1550 (add-after 'unpack 'make-writable
1552 (for-each make-file-writable (find-files "." ".")))))))
1554 (list ocaml-menhir ocaml-odoc))
1555 (properties `((upstream-name . "FrontC")
1556 (ocaml4.07-variant . ,(delay ocaml4.07-frontc))))
1557 (home-page "https://www.irit.fr/FrontC")
1558 (synopsis "C parser and lexer library")
1559 (description "FrontC is an OCAML library providing a C parser and lexer.
1560 The result is a syntactic tree easy to process with usual OCAML tree management.
1561 It provides support for ANSI C syntax, old-C K&R style syntax and the standard
1562 GNU CC attributes. It provides also a C pretty printer as an example of use.")
1563 (license license:lgpl2.1)))
1565 (define-public ocaml4.07-frontc
1566 (package-with-ocaml4.07
1568 (inherit ocaml-frontc)
1573 (url "https://github.com/mirage/ocaml-base64")
1574 (commit (string-append
1575 "V_" (string-join (string-split version #\.) "_")))))
1576 (file-name (git-file-name "ocaml-frontc" version))
1579 "0k7jk9hkglnkk27s62xl493jyqc017gyvwqb1lyc0ywbb001s102"))))
1580 (build-system ocaml-build-system)
1583 (modify-phases %standard-phases
1585 (add-after 'install 'install-meta
1586 (lambda* (#:key outputs #:allow-other-keys)
1587 (let ((out (assoc-ref outputs "out")))
1588 (with-output-to-file
1589 (string-append out "/lib/ocaml/frontc/META")
1593 "description = \"Parser for the C language\"
1594 version = \"" ,version "\"
1596 archive(byte) = \"frontc.cma\"
1597 archive(native) = \"frontc.cmxa\""))))
1598 (symlink (string-append out "/lib/ocaml/frontc")
1599 (string-append out "/lib/ocaml/FrontC"))))))
1600 #:make-flags ,#~(list (string-append "PREFIX=" #$output)
1601 "OCAML_SITE=$(LIB_DIR)/ocaml/")))
1604 (define-public ocaml-qcheck
1606 (name "ocaml-qcheck")
1612 (url "https://github.com/c-cube/qcheck")
1613 (commit (string-append "v" version))))
1614 (file-name (git-file-name name version))
1616 (base32 "0g3r8lrw6fsdphgpnp08saxyxk1vd3chpmb564ir2qnsp716vz6z"))))
1617 (build-system dune-build-system)
1619 `(#:test-target "."))
1621 (list ocaml-alcotest ocaml-ounit))
1624 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-qcheck))))
1625 (home-page "https://github.com/c-cube/qcheck")
1626 (synopsis "QuickCheck inspired property-based testing for OCaml")
1627 (description "QuickCheck inspired property-based testing for OCaml. This
1628 module checks invariants (properties of some types) over randomly
1629 generated instances of the type. It provides combinators for generating
1630 instances and printing them.")
1631 (license license:lgpl3+)))
1633 (define-public ocaml4.07-qcheck
1634 (package-with-ocaml4.07
1636 (inherit ocaml-qcheck)
1641 (url "https://github.com/c-cube/qcheck")
1643 (file-name (git-file-name "ocaml-qcheck" version))
1646 "1llnfynhlndwyjig7wrayjnds2b3mggp5lw20dwxhn2i2lkkb22m"))))
1649 (define-public ocaml-qtest
1651 (name "ocaml-qtest")
1656 (url "https://github.com/vincent-hugot/qtest/")
1657 (commit (string-append "v" version))))
1658 (file-name (git-file-name name version))
1661 "04ghjshh6104xyglm0db9kv90m62qla5f4bfrlndv6dsvgw3rdjl"))))
1662 (build-system dune-build-system)
1664 `(#:test-target "tests"))
1666 `(("ounit" ,ocaml-ounit)
1667 ("qcheck" ,ocaml-qcheck)))
1668 (home-page "https://github.com/vincent-hugot/qtest")
1669 (synopsis "Inline (Unit) Tests for OCaml")
1670 (description "Qtest extracts inline unit tests written using a special
1671 syntax in comments. Those tests are then run using the oUnit framework and the
1672 qcheck library. The possibilities range from trivial tests -- extremely simple
1673 to use -- to sophisticated random generation of test cases.")
1674 (license license:lgpl3+)))
1676 (define-public ocaml-stringext
1678 (name "ocaml-stringext")
1683 (url "https://github.com/rgrinberg/stringext")
1685 (file-name (git-file-name name version))
1688 "1m09cmn3vrk3gdm60fb730qsygcfyxsyv7gl9xfzck08q1x2x9qx"))))
1689 (build-system dune-build-system)
1691 `(#:test-target "."))
1693 `(("ocamlbuild" ,ocamlbuild)
1694 ("qtest" ,ocaml-qtest)))
1695 (home-page "https://github.com/rgrinberg/stringext")
1696 (synopsis "Extra string functions for OCaml")
1697 (description "Provides a single module named Stringext that provides a grab
1698 bag of often used but missing string functions from the stdlib. E.g, split,
1699 full_split, cut, rcut, etc..")
1700 ;; the only mention of a license in this project is in its `opam' file
1701 ;; where it says `mit'.
1702 (license license:expat)))
1704 (define dune-bootstrap
1711 (url "https://github.com/ocaml/dune")
1713 (file-name (git-file-name name version))
1716 "0fa8fkj2piis8b56phl6p77pl1na81krdnmmvyw16hq45zbmm9rk"))))
1717 (build-system ocaml-build-system)
1719 `(#:tests? #f; require odoc
1720 #:make-flags ,#~(list "release"
1721 (string-append "PREFIX=" #$output)
1722 (string-append "LIBDIR=" #$output
1723 "/lib/ocaml/site-lib"))
1725 (modify-phases %standard-phases
1727 (lambda* (#:key outputs #:allow-other-keys)
1728 (mkdir-p "src/dune")
1729 (invoke "./configure")
1731 (home-page "https://github.com/ocaml/dune")
1732 (synopsis "OCaml build system")
1733 (description "Dune is a build system that was designed to simplify the
1734 release of Jane Street packages. It reads metadata from @file{dune} files
1735 following a very simple s-expression syntax.")
1736 (license license:expat)))
1738 (define ocaml4.09-dune-bootstrap
1739 (package-with-ocaml4.09 dune-bootstrap))
1741 (define-public dune-configurator
1743 (inherit dune-bootstrap)
1744 (name "dune-configurator")
1745 (build-system dune-build-system)
1747 `(#:package "dune-configurator"
1748 #:dune ,dune-bootstrap
1749 ; require ppx_expect
1752 (modify-phases %standard-phases
1753 ;; When building dune, these directories are normally removed after
1755 (add-before 'build 'remove-vendor
1757 (delete-file-recursively "vendor/csexp")
1758 (delete-file-recursively "vendor/pp"))))))
1761 (properties `((ocaml4.09-variant . ,(delay ocaml4.09-dune-configurator))))
1762 (synopsis "Dune helper library for gathering system configuration")
1763 (description "Dune-configurator is a small library that helps writing
1764 OCaml scripts that test features available on the system, in order to generate
1765 config.h files for instance. Among other things, dune-configurator allows one to:
1768 @item test if a C program compiles
1769 @item query pkg-config
1770 @item import #define from OCaml header files
1771 @item generate config.h file
1774 (define-public ocaml4.09-dune-configurator
1776 (inherit dune-configurator)
1777 (name "ocaml4.09-dune-configurator")
1779 `(,@(package-arguments dune-configurator)
1780 #:dune ,ocaml4.09-dune-bootstrap
1782 #:findlib ,ocaml4.09-findlib))
1784 `(("ocaml-csexp" ,ocaml4.09-csexp)))))
1788 (inherit dune-bootstrap)
1790 (list dune-configurator))
1791 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-dune))
1792 (ocaml4.09-variant . ,(delay ocaml4.09-dune))))))
1794 (define-public ocaml4.09-dune
1796 (inherit ocaml4.09-dune-bootstrap)
1798 (list dune-configurator))))
1800 (define-public ocaml4.07-dune
1802 (inherit (package-with-ocaml4.07 dune-bootstrap))
1807 (url "https://github.com/ocaml/dune")
1809 (file-name (git-file-name "dune" version))
1812 "0l4x0x2fz135pljv88zj8y6w1ninsqw0gn1mdxzprd6wbxbyn8wr"))))))
1814 (define-public ocaml-csexp
1816 (name "ocaml-csexp")
1821 (url "https://github.com/ocaml-dune/csexp")
1823 (file-name (git-file-name name version))
1826 "1v5y4x1a21193h8q536c0s0d8hv3hyyky4pgzm2dw9807v36s2x4"))))
1827 (build-system dune-build-system)
1829 `(#:tests? #f; FIXME: needs ppx_expect, but which version?
1830 #:dune ,dune-bootstrap
1832 (modify-phases %standard-phases
1833 (add-before 'build 'chmod
1835 (for-each (lambda (file) (chmod file #o644)) (find-files "." ".*"))
1838 (list ocaml-result))
1839 (properties `((ocaml4.09-variant . ,(delay ocaml4.09-csexp))))
1840 (home-page "https://github.com/ocaml-dune/csexp")
1841 (synopsis "Parsing and printing of S-expressions in Canonical form")
1842 (description "This library provides minimal support for Canonical
1843 S-expressions. Canonical S-expressions are a binary encoding of
1844 S-expressions that is super simple and well suited for communication
1847 This library only provides a few helpers for simple applications. If
1848 you need more advanced support, such as parsing from more fancy input
1849 sources, you should consider copying the code of this library given
1850 how simple parsing S-expressions in canonical form is.
1852 To avoid a dependency on a particular S-expression library, the only
1853 module of this library is parameterised by the type of S-expressions.")
1854 (license license:expat)))
1856 (define-public ocaml4.09-csexp
1858 (inherit ocaml-csexp)
1859 (name "ocaml4.09-csexp")
1861 `(#:ocaml ,ocaml-4.09
1862 #:findlib ,ocaml4.09-findlib
1863 ,@(substitute-keyword-arguments (package-arguments ocaml-csexp)
1864 ((#:dune _) ocaml4.09-dune-bootstrap))))
1866 `(("ocaml-result" ,ocaml4.09-result)))))
1868 (define-public ocaml-migrate-parsetree
1870 (name "ocaml-migrate-parsetree")
1872 (home-page "https://github.com/ocaml-ppx/ocaml-migrate-parsetree")
1878 (commit (string-append "v" version))))
1879 (file-name (git-file-name name version))
1882 "1nqmhsc72xmgm865nn8q0hngklhvqav281hgnx1gf5ns49a0n3ig"))))
1883 (build-system dune-build-system)
1884 (arguments `(#:tests? #f))
1886 (list ocaml-ppx-derivers ocamlbuild ocaml-result))
1887 (properties `((upstream-name . "ocaml-migrate-parsetree")
1888 (ocaml4.07-variant . ,(delay ocaml4.07-migrate-parsetree))))
1889 (synopsis "OCaml parsetree converter")
1890 (description "This library converts between parsetrees of different OCaml
1891 versions. For each version, there is a snapshot of the parsetree and conversion
1892 functions to the next and/or previous version.")
1893 (license license:lgpl2.1+)))
1895 ;; OCaml 4.07 packages require version 1.*
1896 (define-public ocaml4.07-migrate-parsetree
1897 (package-with-ocaml4.07
1899 (inherit ocaml-migrate-parsetree)
1900 (name "ocaml-migrate-parsetree")
1902 (home-page "https://github.com/ocaml-ppx/ocaml-migrate-parsetree")
1908 (commit (string-append "v" version))))
1909 (file-name (git-file-name name version))
1912 "16x8sxc4ygxrr1868qpzfqyrvjf3hfxvjzmxmf6ibgglq7ixa2nq"))))
1913 (properties '((upstream-name . "ocaml-migrate-parsetree"))))))
1915 (define-public ocaml4.07-ppx-tools-versioned
1916 (package-with-ocaml4.07
1918 (name "ocaml-ppx-tools-versioned")
1923 (url "https://github.com/ocaml-ppx/ppx_tools_versioned")
1925 (file-name (git-file-name name version))
1928 "07lnj4yzwvwyh5fhpp1dxrys4ddih15jhgqjn59pmgxinbnddi66"))))
1929 (build-system dune-build-system)
1932 #:package "ppx_tools_versioned"))
1934 (list ocaml-migrate-parsetree))
1935 (properties `((upstream-name . "ppx_tools_versioned")))
1936 (home-page "https://github.com/let-def/ppx_tools_versioned")
1937 (synopsis "Variant of ppx_tools")
1938 (description "This package is a variant of ppx_tools based on
1939 ocaml-migrate-parsetree")
1940 (license license:expat))))
1942 (define-public ocaml-bitstring
1944 (name "ocaml-bitstring")
1949 (url "https://github.com/xguerin/bitstring")
1950 (commit (string-append "v" version))))
1951 (file-name (git-file-name name version))
1954 "0mghsl8b2zd2676mh1r9142hymhvzy9cw8kgkjmirxkn56wbf56b"))))
1955 (build-system dune-build-system)
1957 (list time autoconf automake))
1959 (list ocaml-stdlib-shims))
1961 `(#:package "bitstring"
1962 #:tests? #f; Tests fail to build
1964 (modify-phases %standard-phases
1965 (add-before 'build 'upgrade
1967 (invoke "dune" "upgrade")
1969 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-bitstring))))
1970 (home-page "https://github.com/xguerin/bitstring")
1971 (synopsis "Bitstrings and bitstring matching for OCaml")
1972 (description "Adds Erlang-style bitstrings and matching over bitstrings as
1973 a syntax extension and library for OCaml. You can use this module to both parse
1974 and generate binary formats, files and protocols. Bitstring handling is added
1975 as primitives to the language, making it exceptionally simple to use and very
1977 (license license:isc)))
1979 (define-public ocaml4.07-bitstring
1980 (package-with-ocaml4.07
1982 (inherit ocaml-bitstring)
1986 (uri (string-append "https://bitbucket.org/thanatonauts/bitstring/"
1987 "get/v" version ".tar.gz"))
1988 (file-name (string-append "ocaml-bitsring-" version ".tar.gz"))
1991 "15jjk2pq1vx311gl49s5ag6x5y0654x35w75z07g7kr2q334hqps"))))
1993 `(("ocaml-ppx-tools-versioned" ,ocaml4.07-ppx-tools-versioned)))
1996 (define-public ocaml-result
1998 (name "ocaml-result")
2003 (url "https://github.com/janestreet/result")
2005 (file-name (git-file-name name version))
2008 "166laj8qk7466sdl037c6cjs4ac571hglw4l5qpyll6df07h6a7q"))))
2009 (build-system dune-build-system)
2012 #:dune ,dune-bootstrap))
2013 (properties `((ocaml4.09-variant . ,(delay ocaml4.09-result))))
2014 (home-page "https://github.com/janestreet/result")
2015 (synopsis "Compatibility Result module")
2016 (description "Uses the new result type defined in OCaml >= 4.03 while
2017 staying compatible with older version of OCaml should use the Result module
2018 defined in this library.")
2019 (license license:bsd-3)))
2021 (define-public ocaml4.09-result
2023 (inherit ocaml-result)
2024 (name "ocaml4.09-result")
2027 #:dune ,ocaml4.09-dune-bootstrap
2029 #:findlib ,ocaml4.09-findlib))))
2031 (define-public ocaml-topkg
2033 (name "ocaml-topkg")
2037 (uri (string-append "http://erratique.ch/software/topkg/releases/"
2038 "topkg-" version ".tbz"))
2041 "1iyinmcfqpprk7k4cc51nqgypayprbj4larwcfqw86k5dri84825"))))
2042 (build-system ocaml-build-system)
2044 (list opam ocamlbuild))
2046 `(("result" ,ocaml-result)))
2049 #:build-flags '("build")
2051 (modify-phases %standard-phases
2052 (delete 'configure))))
2053 (home-page "https://erratique.ch/software/topkg")
2054 (synopsis "Transitory OCaml software packager")
2055 (description "Topkg is a packager for distributing OCaml software. It
2056 provides an API to describe the files a package installs in a given build
2057 configuration and to specify information about the package's distribution,
2058 creation and publication procedures.")
2059 (license license:isc)))
2061 (define-public ocaml-rresult
2063 (name "ocaml-rresult")
2067 (uri (string-append "http://erratique.ch/software/rresult/releases/"
2068 "rresult-" version ".tbz"))
2071 "0h2mjyzhay1p4k7n0mzaa7hlc7875kiy6m1i3r1n03j6hddpzahi"))))
2072 (build-system ocaml-build-system)
2074 (list opam ocamlbuild))
2076 `(("topkg" ,ocaml-topkg)))
2079 #:build-flags '("build")
2081 (modify-phases %standard-phases
2082 (delete 'configure))))
2083 (home-page "https://erratique.ch/software/rresult")
2084 (synopsis "Result value combinators for OCaml")
2085 (description "Handle computation results and errors in an explicit and
2086 declarative manner, without resorting to exceptions. It defines combinators
2087 to operate on the result type available from OCaml 4.03 in the standard
2089 (license license:isc)))
2091 (define-public ocaml-sqlite3
2093 (name "ocaml-sqlite3")
2099 (url "https://github.com/mmottl/sqlite3-ocaml")
2101 (file-name (git-file-name name version))
2104 "1ksm0a490315sf0yy8lmva5f3bgr0jnllffanyq89431grpj6x15"))))
2105 (build-system dune-build-system)
2106 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-sqlite3))))
2108 (list dune-configurator ocaml-odoc))
2110 (list ocaml-ppx-inline-test pkg-config sqlite))
2111 (home-page "https://mmottl.github.io/sqlite3-ocaml")
2112 (synopsis "SQLite3 Bindings for OCaml")
2114 "SQLite3-OCaml is an OCaml library with bindings to the SQLite3 client
2115 API. Sqlite3 is a self-contained, serverless, zero-configuration,
2116 transactional SQL database engine with outstanding performance for many use
2117 cases. These bindings are written in a way that enables a friendly
2118 coexistence with the old (version 2) SQLite and its OCaml wrapper
2119 @code{ocaml-sqlite}.")
2120 (license license:expat)))
2122 (define-public ocaml4.07-sqlite3
2123 (package-with-ocaml4.07
2125 (inherit ocaml-sqlite3)
2131 (url "https://github.com/mmottl/sqlite3-ocaml")
2133 (file-name (git-file-name "ocaml-sqlite3" version))
2136 "15mmq7ak5facpfawfrc6hjz211gli7jab52iqdsihfvh790xm55f"))))
2139 (modify-phases %standard-phases
2140 (add-before 'build 'chmod
2142 (for-each (lambda (file) (chmod file #o644)) (find-files "." ".*"))
2145 `(("ocaml-odoc" ,ocaml-odoc)))
2148 (define-public ocaml-csv
2156 (url "https://github.com/Chris00/ocaml-csv")
2158 (file-name (git-file-name name version))
2161 "0y2hlqlmqs7r4y5mfzc5qdv7gdp3wxbwpz458vf7fj4593vg94cf"))))
2162 (build-system dune-build-system)
2166 (home-page "https://github.com/Chris00/ocaml-csv")
2167 (synopsis "Pure OCaml functions to read and write CSV")
2169 "@dfn{Comma separated values} (CSV) is a simple tabular format supported
2170 by all major spreadsheets. This library implements pure OCaml functions to
2171 read and write files in this format as well as some convenience functions to
2172 manipulate such data.")
2173 ;; This is LGPLv2.1 with an exception that allows packages statically-linked
2174 ;; against the library to be released under any terms.
2175 (license license:lgpl2.1)))
2177 (define-public ocaml-mtime
2179 (name "ocaml-mtime")
2183 (uri (string-append "http://erratique.ch/software/mtime/releases/"
2184 "mtime-" version ".tbz"))
2187 "1xy6lg52n2zynp4p164ym9j0f1b95j5n4bi5y4mbdrry9w99h32m"))))
2188 (build-system ocaml-build-system)
2190 (list ocamlbuild opam))
2192 `(("topkg" ,ocaml-topkg)))
2195 #:build-flags (list "build")
2197 (modify-phases %standard-phases
2198 (delete 'configure))))
2199 (home-page "https://erratique.ch/software/mtime")
2200 (synopsis "Monotonic wall-clock time for OCaml")
2201 (description "Access monotonic wall-clock time. It measures time
2202 spans without being subject to operating system calendar time adjustments.")
2203 (license license:isc)))
2205 (define-public ocaml-calendar
2207 ;; Commit from 2019-02-03.
2208 (let ((commit "a447a88ae3c1e9873e32d2a95d3d3e7c5ed4a7da")
2211 (name "ocaml-calendar")
2212 ;; Makefile.in says 2.04.
2213 (version (git-version "2.04" revision commit))
2218 (url "https://github.com/ocaml-community/calendar")
2220 (file-name (git-file-name name version))
2223 "09d9gyqm3zkf3z2m9fx87clqihx6brf8rnzm4yq7c8kf1p572hmc"))))
2224 (build-system gnu-build-system)
2226 '(#:test-target "tests"
2228 (modify-phases %standard-phases
2229 (add-after 'unpack 'make-deterministic
2231 (substitute* "Makefile.in"
2232 (("`date`") "no date for reproducibility"))))
2233 (add-before 'install 'set-environment-variables
2234 (lambda* (#:key outputs #:allow-other-keys)
2235 (let ((out (assoc-ref outputs "out")))
2236 (setenv "OCAMLFIND_DESTDIR"
2237 (string-append out "/lib/ocaml/site-lib"))
2238 (setenv "OCAMLFIND_LDCONF" "ignore")
2239 (mkdir-p (string-append
2240 out "/lib/ocaml/site-lib/calendar"))))))))
2242 (list autoconf automake))
2245 ("ocamlfind" ,ocaml-findlib)))
2246 (home-page "https://github.com/ocaml-community/calendar")
2247 (synopsis "OCaml library for handling dates and times")
2248 (description "This package provides types and operations over
2250 ;; With linking exception.
2251 (license license:lgpl2.1+))))
2253 (define-public ocaml-cmdliner
2255 (name "ocaml-cmdliner")
2259 (uri (string-append "https://erratique.ch/software/cmdliner/releases/"
2260 "cmdliner-" version ".tbz"))
2263 "1yxm4x34cbi06bfld601ds9drlbnyx0797ym3n6yyh4rlz1qgbm1"))))
2264 (build-system ocaml-build-system)
2266 (list ocaml-result))
2271 #:make-flags ,#~(list (string-append "LIBDIR=" #$output
2272 "/lib/ocaml/site-lib/cmdliner"))
2274 (modify-phases %standard-phases
2276 (add-before 'build 'fix-source-file-order
2278 (substitute* "build.ml"
2279 (("Sys.readdir dir")
2280 "let a = Sys.readdir dir in Array.sort String.compare a; a"))
2282 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-cmdliner))))
2283 (home-page "https://erratique.ch/software/cmdliner")
2284 (synopsis "Declarative definition of command line interfaces for OCaml")
2285 (description "Cmdliner is a module for the declarative definition of command
2286 line interfaces. It provides a simple and compositional mechanism to convert
2287 command line arguments to OCaml values and pass them to your functions. The
2288 module automatically handles syntax errors, help messages and UNIX man page
2289 generation. It supports programs with single or multiple commands and respects
2290 most of the POSIX and GNU conventions.")
2291 (license license:bsd-3)))
2293 (define-public ocaml4.07-cmdliner
2294 (package-with-ocaml4.07
2296 (inherit ocaml-cmdliner)
2300 (uri (string-append "https://erratique.ch/software/cmdliner/releases/"
2301 "cmdliner-" version ".tbz"))
2304 "1h04q0zkasd0mw64ggh4y58lgzkhg6yhzy60lab8k8zq9ba96ajw"))))
2307 (define-public ocaml-fmt
2314 (uri (string-append "http://erratique.ch/software/fmt/releases/fmt-"
2317 "0q8j2in2473xh7k4hfgnppv9qy77f2ih89yp6yhpbp92ba021yzi"))))
2318 (build-system ocaml-build-system)
2320 `(("ocamlbuild" ,ocamlbuild)
2322 ("topkg" ,ocaml-topkg)))
2324 `(("cmdliner" ,ocaml-cmdliner)
2325 ("ocaml-stdlib-shims" ,ocaml-stdlib-shims)
2326 ("ocaml-uchar" ,ocaml-uchar)))
2327 (arguments `(#:tests? #f
2328 #:build-flags (list "build" "--with-base-unix" "true"
2329 "--with-cmdliner" "true")
2331 (modify-phases %standard-phases
2332 (delete 'configure))))
2333 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-fmt))))
2334 (home-page "https://erratique.ch/software/fmt")
2335 (synopsis "OCaml Format pretty-printer combinators")
2336 (description "Fmt exposes combinators to devise Format pretty-printing
2338 (license license:isc)))
2340 (define-public ocaml4.07-fmt
2341 (package-with-ocaml4.07
2347 (uri (string-append "http://erratique.ch/software/fmt/releases/fmt-"
2351 "0gkkkj4x678vxdda4xaw2dd44qjacavsvn5nx8gydfwah6pjbkxk"))))
2354 (define-public ocaml-astring
2356 (name "ocaml-astring")
2361 (uri (string-append "http://erratique.ch/software/astring/releases/astring-"
2364 "1ykhg9gd3iy7zsgyiy2p9b1wkpqg9irw5pvcqs3sphq71iir4ml6"))))
2365 (build-system ocaml-build-system)
2367 `(("ocamlbuild" ,ocamlbuild)
2369 ("topkg" ,ocaml-topkg)))
2372 #:build-flags (list "build")
2374 (modify-phases %standard-phases
2375 (delete 'configure))))
2376 (home-page "https://erratique.ch/software/astring")
2377 (synopsis "Alternative String module for OCaml")
2378 (description "Astring exposes an alternative String module for OCaml. This
2379 module balances minimality and expressiveness for basic, index-free, string
2380 processing and provides types and functions for substrings, string sets and
2381 string maps. The String module exposed by Astring has exception safe functions,
2382 removes deprecated and rarely used functions, alters some signatures and names,
2383 adds a few missing functions and fully exploits OCaml's newfound string
2385 (license license:isc)))
2387 (define-public ocaml-alcotest
2389 (name "ocaml-alcotest")
2394 (url "https://github.com/mirage/alcotest")
2396 (file-name (git-file-name name version))
2399 "1lgadc7p56677fi5gwl7r9bml4z87rzh50khhqaij7bwp37zrmpi"))))
2400 (build-system dune-build-system)
2402 `(#:package "alcotest"
2405 (modify-phases %standard-phases
2406 (add-after 'unpack 'fix-test-format
2408 ;; cmdliner changed the format and the tests fail
2409 (substitute* "test/e2e/alcotest/failing/unknown_option.expected"
2411 (("COMMAND") "[COMMAND]")
2412 (("\\.\\.\\.") "…")))))))
2423 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-alcotest))))
2424 (home-page "https://github.com/mirage/alcotest")
2425 (synopsis "Lightweight OCaml test framework")
2426 (description "Alcotest exposes simple interface to perform unit tests. It
2427 exposes a simple TESTABLE module type, a check function to assert test
2428 predicates and a run function to perform a list of unit -> unit test callbacks.
2429 Alcotest provides a quiet and colorful output where only faulty runs are fully
2430 displayed at the end of the run (with the full logs ready to inspect), with a
2431 simple (yet expressive) query language to select the tests to run.")
2432 (license license:isc)))
2434 (define-public ocaml4.07-alcotest
2435 (package-with-ocaml4.07
2437 (inherit ocaml-alcotest)
2442 (url "https://github.com/mirage/alcotest")
2444 (file-name (git-file-name "ocaml-alcotest" version))
2447 "1frwi185z4aadmaf0vp8xk5227nyg7nmh28ijj5l7ncjr5slvhz8"))))
2449 `(#:package "alcotest"
2453 (define-public ocaml-ppx-tools
2455 (name "ocaml-ppx-tools")
2461 (url "https://github.com/alainfrisch/ppx_tools")
2463 (file-name (git-file-name name version))
2466 "0fwibah2hgllrnbdrmfqil5gr5raf6pb5h2zx6zs1h3d4ykvy8k8"))))
2467 (build-system dune-build-system)
2473 (properties `((upstream-name . "ppx_tools")))
2474 (home-page "https://github.com/alainfrisch/ppx_tools")
2475 (synopsis "Tools for authors of ppx rewriters and other syntactic tools")
2477 "Ppx_tools provides tools for authors of ppx rewriters and other
2479 (license license:expat)))
2481 (define-public ocaml-react
2483 (name "ocaml-react")
2488 (uri (string-append "http://erratique.ch/software/react/releases/react-"
2491 "16cg4byj8lfbbw96dhh8sks5y9n1c3fshz7f2p8m7wgisqax7bf4"))))
2492 (build-system ocaml-build-system)
2494 (list ocamlbuild opam ocaml-topkg))
2497 #:build-flags (list "build")
2499 (modify-phases %standard-phases
2500 (delete 'configure))))
2501 (home-page "https://erratique.ch/software/react")
2502 (synopsis "Declarative events and signals for OCaml")
2503 (description "React is an OCaml module for functional reactive programming
2504 (FRP). It provides support to program with time varying values: declarative
2505 events and signals. React doesn't define any primitive event or signal, it
2506 lets the client choose the concrete timeline.")
2507 (license license:bsd-3)))
2509 (define-public ocaml-ssl
2517 (url "https://github.com/savonet/ocaml-ssl")
2518 (commit (string-append "v" version))))
2519 (file-name (git-file-name name version))
2521 "1rszqiqayh67xlwd5411k8vib47x9kapdr037z1majd2c14z3kcb"))))
2522 (build-system dune-build-system)
2524 `(#:test-target "."))
2526 (list autoconf automake which))
2527 (propagated-inputs (list openssl))
2528 (home-page "https://github.com/savonet/ocaml-ssl/")
2529 (synopsis "OCaml bindings for OpenSSL")
2531 "OCaml-SSL is a set of bindings for OpenSSL, a library for communicating
2532 through Transport Layer Security (@dfn{TLS}) encrypted connections.")
2533 (license license:lgpl2.1)))
2535 (define-public ocaml-mmap
2542 (url "https://github.com/mirage/mmap")
2543 (commit (string-append "v" version))))
2544 (file-name (git-file-name name version))
2547 "1a7w7l682cbksn2zlmz24gb519x7wb65ivr5vndm9x5pi9fw5pfb"))))
2548 (build-system dune-build-system)
2549 (propagated-inputs (list ocaml-bigarray-compat))
2550 (home-page "https://github.com/mirage/mmap")
2551 (synopsis "File mapping for OCaml")
2552 (description "This project provides a @command{Mmap.map_file} function
2553 for mapping files in memory. This function is the same as the
2554 @command{Unix.map_file} function added in OCaml >= 4.06.")
2555 (license (list license:qpl license:lgpl2.0))))
2557 (define-public ocaml-lwt
2565 (url "https://github.com/ocsigen/lwt")
2567 (file-name (git-file-name name version))
2569 "1jbjz2rsz3j56k8vh5qlmm87hhkr250bs2m3dvpy9vsri8rkzj9z"))))
2570 (build-system dune-build-system)
2574 (list ocaml-cppo pkg-config))
2578 (list ocaml-mmap ocaml-ocplib-endian ocaml-result ocaml-seq libev))
2579 (home-page "https://github.com/ocsigen/lwt")
2580 (synopsis "Cooperative threads and I/O in monadic style")
2581 (description "Lwt provides typed, composable cooperative threads. These
2582 make it easy to run normally-blocking I/O operations concurrently in a single
2583 process. Also, in many cases, Lwt threads can interact without the need for
2584 locks or other synchronization primitives.")
2585 (license license:lgpl2.1)))
2587 (define-public ocaml-lwt-react
2590 (name "ocaml-lwt-react")
2595 (url "https://github.com/ocsigen/lwt")
2596 ;; Version from opam
2598 (file-name (git-file-name name version))
2601 "1jbjz2rsz3j56k8vh5qlmm87hhkr250bs2m3dvpy9vsri8rkzj9z"))))
2603 `(#:package "lwt_react"))
2604 (properties `((upstream-name . "lwt_react")))
2606 (list ocaml-lwt ocaml-react))))
2608 (define-public ocaml-lwt-log
2610 (name "ocaml-lwt-log")
2615 (url "https://github.com/aantron/lwt_log")
2617 (file-name (git-file-name name version))
2620 "1n12i1rmn9cjn6p8yr6qn5dwbrwvym7ckr7bla04a1xnq8qlcyj7"))))
2621 (build-system dune-build-system)
2623 `(#:tests? #f)); require lwt_ppx
2625 `(("lwt" ,ocaml-lwt)))
2626 (properties `((upstream-name . "lwt_log")))
2627 (home-page "https://github.com/aantron/lwt_log")
2628 (synopsis "Logging library")
2629 (description "This package provides a deprecated logging component for
2631 (license license:lgpl2.1)))
2633 (define-public ocaml-logs
2639 (uri (string-append "http://erratique.ch/software/logs/releases/"
2640 "logs-" version ".tbz"))
2643 "1jnmd675wmsmdwyb5mx5b0ac66g4c6gpv5s4mrx2j6pb0wla1x46"))))
2644 (build-system ocaml-build-system)
2647 #:build-flags (list "build" "--with-js_of_ocaml" "false")
2649 (modify-phases %standard-phases
2650 (delete 'configure))))
2652 (list ocamlbuild opam))
2654 `(("fmt" ,ocaml-fmt)
2656 ("mtime" ,ocaml-mtime)
2657 ("result" ,ocaml-result)
2658 ("cmdliner" ,ocaml-cmdliner)
2659 ("topkg" ,ocaml-topkg)))
2660 (home-page "https://erratique.ch/software/logs")
2661 (synopsis "Logging infrastructure for OCaml")
2662 (description "Logs provides a logging infrastructure for OCaml. Logging is
2663 performed on sources whose reporting level can be set independently. Log
2664 message report is decoupled from logging and is handled by a reporter.")
2665 (license license:isc)))
2667 (define-public ocaml-fpath
2669 (name "ocaml-fpath")
2673 (uri (string-append "http://erratique.ch/software/fpath/releases/"
2674 "fpath-" version ".tbz"))
2677 "03z7mj0sqdz465rc4drj1gr88l9q3nfs374yssvdjdyhjbqqzc0j"))))
2678 (build-system ocaml-build-system)
2681 #:build-flags (list "build")
2683 (modify-phases %standard-phases
2684 (delete 'configure))))
2686 (list ocamlbuild opam))
2688 `(("topkg" ,ocaml-topkg)
2689 ("astring" ,ocaml-astring)))
2690 (home-page "https://erratique.ch/software/fpath")
2691 (synopsis "File system paths for OCaml")
2692 (description "Fpath is an OCaml module for handling file system paths with
2693 POSIX or Windows conventions. Fpath processes paths without accessing the
2694 file system and is independent from any system library.")
2695 (license license:isc)))
2697 (define-public ocaml-bos
2703 (uri (string-append "http://erratique.ch/software/bos/releases/"
2704 "bos-" version ".tbz"))
2707 "0dwg7lpaq30rvwc5z1gij36fn9xavvpah1bj8ph9gmhhddw2xmnq"))))
2708 (build-system ocaml-build-system)
2711 #:build-flags (list "build")
2713 (modify-phases %standard-phases
2714 (delete 'configure))))
2716 (list ocamlbuild opam))
2718 `(("topkg" ,ocaml-topkg)
2719 ("astring" ,ocaml-astring)
2721 ("fpath" ,ocaml-fpath)
2722 ("logs" ,ocaml-logs)
2723 ("rresult" ,ocaml-rresult)))
2724 (home-page "https://erratique.ch/software/bos")
2725 (synopsis "Basic OS interaction for OCaml")
2726 (description "Bos provides support for basic and robust interaction with
2727 the operating system in OCaml. It has functions to access the process
2728 environment, parse command line arguments, interact with the file system and
2729 run command line programs.")
2730 (license license:isc)))
2732 (define-public ocaml-xmlm
2738 (uri (string-append "http://erratique.ch/software/xmlm/releases/"
2739 "xmlm-" version ".tbz"))
2742 "1ynrjba3wm3axscvggrfijfgsznmphhxnkffqch67l9xiqjm44h9"))))
2743 (build-system ocaml-build-system)
2746 #:build-flags (list "build")
2748 (modify-phases %standard-phases
2749 (delete 'configure))))
2751 (list ocamlbuild ocaml-topkg opam))
2752 (home-page "https://erratique.ch/software/xmlm")
2753 (synopsis "Streaming XML codec for OCaml")
2754 (description "Xmlm is a streaming codec to decode and encode the XML data
2755 format. It can process XML documents without a complete in-memory
2756 representation of the data.")
2757 (license license:isc)))
2759 (define-public ocaml-gen
2766 (url "https://github.com/c-cube/gen")
2767 (commit (string-append "v" version))))
2768 (file-name (git-file-name name version))
2771 "1z5nw5wljvcqp8q07h336bbvf9paynia0jsdh4486hlkbmr1ask1"))))
2772 (build-system dune-build-system)
2777 (list ocaml-odoc ocaml-seq))
2779 (list ocaml-qtest ocaml-qcheck))
2780 (home-page "https://github.com/c-cube/gen/")
2781 (synopsis "Iterators for OCaml, both restartable and consumable")
2782 (description "Gen implements iterators of OCaml, that are both restartable
2784 (license license:bsd-2)))
2786 (define-public ocaml-sedlex
2788 (name "ocaml-sedlex")
2793 (url "https://github.com/ocaml-community/sedlex")
2794 (commit (string-append "v" version))))
2795 (file-name (git-file-name name version))
2798 "062a5dvrzvb81l3a9phljrhxfw9nlb61q341q0a6xn65hll3z2wy"))))
2799 (build-system dune-build-system)
2801 `(#:tests? #f ; no tests
2804 (modify-phases %standard-phases
2805 (add-before 'build 'copy-resources
2806 (lambda* (#:key inputs #:allow-other-keys)
2807 (with-directory-excursion "src/generator/data"
2808 ;; Newer versions of dune emit an error if files it wants to
2809 ;; build already exist. Delete the dune file so dune doesn't
2811 (delete-file "dune")
2814 (copy-file (assoc-ref inputs file) file))
2815 '("DerivedCoreProperties.txt" "DerivedGeneralCategory.txt"
2818 (add-before 'build 'chmod
2820 (for-each (lambda (file) (chmod file #o644)) (find-files "." ".*"))
2823 (list ocaml-gen ocaml-ppxlib ocaml-uchar))
2824 ;; These three files are needed by src/generator/data/dune, but would be
2825 ;; downloaded using curl at build time.
2827 `(("DerivedCoreProperties.txt"
2830 (uri "https://www.unicode.org/Public/12.1.0/ucd/DerivedCoreProperties.txt")
2833 "0s6sn1yr9qmb2i6gf8dir2zpsbjv1frdfzy3i2yjylzvf637msx6"))))
2834 ("DerivedGeneralCategory.txt"
2837 (uri "https://www.unicode.org/Public/12.1.0/ucd/extracted/DerivedGeneralCategory.txt")
2840 "1rifzq9ba6c58dn0lrmcb5l5k4ksx3zsdkira3m5p6h4i2wriy3q"))))
2844 (uri "https://www.unicode.org/Public/12.1.0/ucd/PropList.txt")
2847 "0gsb1jpj3mnqbjgbavi4l95gl6g4agq58j82km22fdfg63j3w3fk"))))))
2848 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-sedlex))))
2849 (home-page "https://www.cduce.org/download.html#side")
2850 (synopsis "Lexer generator for Unicode and OCaml")
2851 (description "Lexer generator for Unicode and OCaml.")
2852 (license license:expat)))
2854 (define-public ocaml4.07-sedlex
2855 (package-with-ocaml4.07
2857 (inherit ocaml-sedlex)
2858 (name "ocaml-sedlex")
2863 (url "https://github.com/ocaml-community/sedlex")
2864 (commit (string-append "v" version))))
2865 (file-name (git-file-name name version))
2868 "05f6qa8x3vhpdz1fcnpqk37fpnyyq13icqsk2gww5idjnh6kng26"))))
2870 `(("ocaml-ppx-tools-versioned" ,ocaml4.07-ppx-tools-versioned)
2871 ,@(package-propagated-inputs ocaml-sedlex)))
2874 (define-public ocaml-uchar
2876 (name "ocaml-uchar")
2881 (uri (string-append "https://github.com/ocaml/uchar/releases/download/v"
2882 version "/uchar-" version ".tbz"))
2884 "1w2saw7zanf9m9ffvz2lvcxvlm118pws2x1wym526xmydhqpyfa7"))))
2885 (build-system ocaml-build-system)
2888 #:build-flags (list "native=true" "native-dynlink=true")
2890 (modify-phases %standard-phases
2891 (delete 'configure))))
2893 (list ocamlbuild opam))
2894 (home-page "https://github.com/ocaml/uchar")
2895 (synopsis "Compatibility library for OCaml's Uchar module")
2896 (description "The uchar package provides a compatibility library for the
2897 `Uchar` module introduced in OCaml 4.03.")
2898 (license license:lgpl2.1)))
2900 (define-public ocaml-uutf
2906 (uri (string-append "http://erratique.ch/software/uutf/releases/"
2907 "uutf-" version ".tbz"))
2910 "0s05r8ggp1g97zq4rnvbxzj22pv8ld0k5wsdw662jw0y7mhsawl7"))))
2911 (build-system ocaml-build-system)
2914 #:build-flags (list "build")
2916 (modify-phases %standard-phases
2917 (delete 'configure))))
2919 `(("ocamlbuild" ,ocamlbuild)
2921 ("topkg" ,ocaml-topkg)))
2923 `(("uchar" ,ocaml-uchar)
2924 ("cmdliner" ,ocaml-cmdliner)))
2925 (home-page "https://erratique.ch/software/uutf")
2926 (synopsis "Non-blocking streaming Unicode codec for OCaml")
2927 (description "Uutf is a non-blocking streaming codec to decode and encode
2928 the UTF-8, UTF-16, UTF-16LE and UTF-16BE encoding schemes. It can efficiently
2929 work character by character without blocking on IO. Decoders perform character
2930 position tracking and support newline normalization.
2932 Functions are also provided to fold over the characters of UTF encoded OCaml
2933 string values and to directly encode characters in OCaml Buffer.t values.")
2934 (license license:isc)))
2936 (define-public ocaml-uunf
2943 (uri (string-append "https://erratique.ch/software/uunf/releases/uunf-"
2947 "17wv0nm3vvwcbzb1b09akw8jblmigyhbfmh1sy9lkb5756ni94a2"))))
2948 (build-system ocaml-build-system)
2950 `(#:build-flags (list "build" "--tests" "true")
2952 (modify-phases %standard-phases
2954 (add-before 'check 'check-data
2955 (lambda* (#:key inputs #:allow-other-keys)
2956 (copy-file (assoc-ref inputs "NormalizationTest.txt")
2957 "test/NormalizationTest.txt")
2960 `(("ocamlbuild" ,ocamlbuild)
2962 ("topkg" ,ocaml-topkg)
2963 ;; Test data is otherwise downloaded with curl
2964 ("NormalizationTest.txt"
2967 (uri (string-append "https://www.unicode.org/Public/"
2969 "/ucd/NormalizationTest.txt"))
2970 (file-name (string-append "NormalizationTest-" version ".txt"))
2972 (base32 "0c93pqdkksf7b7zw8y2w0h9i5kkrsdjmh2cr5clrrhp6mg10rcvw"))))))
2973 (propagated-inputs (list ocaml-uutf))
2974 (home-page "https://erratique.ch/software/uunf")
2975 (synopsis "Unicode text normalization for OCaml")
2977 "Uunf is an OCaml library for normalizing Unicode text. It supports all
2978 Unicode normalization forms. The library is independent from any
2979 IO mechanism or Unicode text data structure and it can process text
2980 without a complete in-memory representation.")
2981 (license license:isc)))
2983 (define-public ocaml-jsonm
2985 (name "ocaml-jsonm")
2989 (uri (string-append "http://erratique.ch/software/jsonm/releases/"
2990 "jsonm-" version ".tbz"))
2993 "1176dcmxb11fnw49b7yysvkjh0kpzx4s48lmdn5psq9vshp5c29w"))))
2994 (build-system ocaml-build-system)
2997 #:build-flags (list "build")
2999 (modify-phases %standard-phases
3000 (delete 'configure))))
3002 `(("ocamlbuild" ,ocamlbuild)
3004 ("topkg" ,ocaml-topkg)))
3006 `(("uutf" ,ocaml-uutf)
3007 ("cmdliner" ,ocaml-cmdliner)))
3008 (home-page "https://erratique.ch/software/jsonm")
3009 (synopsis "Non-blocking streaming JSON codec for OCaml")
3010 (description "Jsonm is a non-blocking streaming codec to decode and encode
3011 the JSON data format. It can process JSON text without blocking on IO and
3012 without a complete in-memory representation of the data.")
3013 (license license:isc)))
3015 (define-public ocaml-ocp-indent
3017 (name "ocaml-ocp-indent")
3023 (url "https://github.com/OCamlPro/ocp-indent")
3025 (file-name (git-file-name name version))
3028 "1dvcl108ir9nqkk4mjm9xhhj4p9dx9bmg8bnms54fizs1x3x8ar3"))))
3029 (build-system dune-build-system)
3031 `(#:test-target "tests"))
3033 (list ocaml-cmdliner))
3034 (home-page "https://www.typerex.org/ocp-indent.html")
3035 (synopsis "Tool to indent OCaml programs")
3037 "Ocp-indent is based on an approximate, tolerant OCaml parser
3038 and a simple stack machine. Presets and configuration options are available,
3039 with the possibility to set them project-wide. It supports the most common
3040 syntax extensions, and it is extensible for others.
3042 This package includes:
3045 @item An indentor program, callable from the command-line or from within editors,
3046 @item Bindings for popular editors,
3047 @item A library that can be directly used by editor writers, or just for
3048 fault-tolerant and approximate parsing.
3050 (license license:lgpl2.1)))
3052 (define-public ocaml-ocp-index
3054 (name "ocaml-ocp-index")
3060 (url "https://github.com/OCamlPro/ocp-index")
3062 (file-name (git-file-name name version))
3065 "1gbigw5s2cafkr82n9vkxbb892qfkykj0adj0hrdkrkw8j6rfl0j"))))
3066 (build-system dune-build-system)
3068 `(#:package "ocp-index"))
3070 (list ocaml-ocp-indent ocaml-re ocaml-cmdliner))
3073 (home-page "https://www.typerex.org/ocp-index.html")
3074 (synopsis "Lightweight completion and documentation browsing for OCaml libraries")
3075 (description "This package includes only the @code{ocp-index} library
3076 and command-line tool.")
3077 ;; All files in libs/ are GNU lgpl2.1
3078 ;; For static linking, clause 6 of LGPL is lifted
3079 ;; All other files under GNU gpl3
3080 (license (list license:gpl3+
3081 license:lgpl2.1+))))
3083 (define-public ocaml-ocurl
3085 (name "ocaml-ocurl")
3089 (uri (string-append "http://ygrek.org.ua/p/release/ocurl/ocurl-"
3093 "0qvpsqbq4qbd397n0nlv9cwlqfyjw7gfb5mmq1awvnklr0c9fdg0"))))
3094 (build-system ocaml-build-system)
3097 (modify-phases %standard-phases
3098 (add-before 'configure 'fix-/bin/sh
3099 (lambda* (#:key inputs #:allow-other-keys)
3100 (substitute* "configure"
3101 (("-/bin/sh") (string-append "-" (which "bash")))))))))
3104 (inputs (list curl))
3105 (home-page "http://ocurl.forge.ocamlcore.org/")
3106 (synopsis "OCaml bindings for libcurl")
3107 (description "Client-side URL transfer library, supporting HTTP and a
3108 multitude of other network protocols (FTP/SMTP/RTSP/etc).")
3109 (license license:isc)))
3111 (define-public ocaml-base64
3113 (name "ocaml-base64")
3118 (url "https://github.com/mirage/ocaml-base64")
3119 (commit (string-append "v" version))))
3120 (file-name (git-file-name name version))
3123 "068hwdbpl7vx9jjpxdc6a10zqd8xa55j3xx7ga6fnwrlfsbs2pjj"))))
3124 (build-system dune-build-system)
3126 (list ocaml-alcotest ocaml-bos ocaml-rresult))
3127 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-base64))))
3128 (home-page "https://github.com/mirage/ocaml-base64")
3129 (synopsis "Base64 encoding for OCaml")
3130 (description "Base64 is a group of similar binary-to-text encoding schemes
3131 that represent binary data in an ASCII string format by translating it into a
3132 radix-64 representation. It is specified in RFC 4648.")
3133 (license license:isc)))
3135 (define-public ocaml4.07-base64
3136 (package-with-ocaml4.07
3138 (inherit ocaml-base64)
3143 (url "https://github.com/mirage/ocaml-base64")
3144 (commit (string-append "v" version))))
3145 (file-name (git-file-name "ocaml-base64" version))
3148 "1ilw3zj0w6cq7i4pvr8m2kv5l5f2y9aldmv72drlwwns013b1gwy"))))
3150 ;; Tests are likely incompatible with our recent alcotest
3154 (define-public ocamlify
3161 (uri (string-append "https://download.ocamlcore.org/ocamlify/ocamlify/"
3162 version "/ocamlify-" version ".tar.gz"))
3164 (base32 "1f0fghvlbfryf5h3j4as7vcqrgfjb4c8abl5y0y5h069vs4kp5ii"))))
3165 (build-system ocaml-build-system)
3167 `(#:tests? #f; no tests
3169 (modify-phases %standard-phases
3172 ;; This package uses pre-generated setup.ml by oasis, but is
3173 ;; a dependency of oasis. the pre-generated setup.ml is broken
3174 ;; with recent versions of OCaml, so we perform a bootstrap instead.
3176 (substitute* "src/OCamlifyConfig.ml.ab"
3177 (("$pkg_version") ,version))
3178 (rename-file "src/OCamlifyConfig.ml.ab" "src/OCamlifyConfig.ml")
3179 (with-directory-excursion "src"
3180 (invoke "ocamlc" "OCamlifyConfig.ml" "ocamlify.ml" "-o"
3184 (lambda* (#:key outputs #:allow-other-keys)
3185 (let ((bin (string-append (assoc-ref outputs "out") "/bin")))
3187 (install-file "src/ocamlify" bin)
3189 (home-page "https://forge.ocamlcore.org/projects/ocamlify")
3190 (synopsis "Include files in OCaml code")
3191 (description "OCamlify creates OCaml source code by including
3192 whole files into OCaml string or string list. The code generated can be
3193 compiled as a standard OCaml file. It allows embedding external resources as
3195 (license license:lgpl2.1+))); with the OCaml static compilation exception
3197 (define-public omake
3203 (uri (string-append "http://download.camlcity.org/download/"
3204 "omake-" version ".tar.gz"))
3207 "1i7pcv53kqplrbdx9mllrhbv4j57zf87xwq18r16cvn1lbc6mqal"))
3208 (patches (search-patches "omake-fix-non-determinism.patch"))))
3209 (build-system ocaml-build-system)
3212 ,#~(list (string-append "PREFIX=" #$output))
3213 #:tests? #f ; no test target
3215 (modify-phases %standard-phases
3216 (add-before 'configure 'fix-makefile
3217 (lambda* (#:key outputs #:allow-other-keys)
3218 (substitute* "mk/osconfig_unix.mk"
3219 (("CC = cc") "CC = gcc")))))))
3220 (native-inputs (list hevea))
3221 (home-page "http://projects.camlcity.org/projects/omake.html")
3222 (synopsis "Build system designed for scalability and portability")
3223 (description "Similar to make utilities you may have used, but it features
3224 many additional enhancements, including:
3227 @item Support for projects spanning several directories or directory hierarchies.
3228 @item Fast, reliable, automated, scriptable dependency analysis using MD5 digests,
3229 with full support for incremental builds.
3230 @item Dependency analysis takes the command lines into account — whenever the
3231 command line used to build a target changes, the target is considered
3233 @item Fully scriptable, includes a library that providing support for standard
3234 tasks in C, C++, OCaml, and LaTeX projects, or a mixture thereof.
3236 (license (list license:lgpl2.1 ; libmojave
3237 license:expat ; OMake scripts
3238 license:gpl2)))) ; OMake itself, with ocaml linking exception
3241 (define-public ocaml-benchmark
3243 (name "ocaml-benchmark")
3249 (url "https://github.com/Chris00/ocaml-benchmark")
3251 (file-name (git-file-name name version))
3253 (base32 "0d0vdfjgjzf1y6wkd714d8b0piv1z9qav5ahsapynqzk4b4ahhnp"))))
3254 (build-system dune-build-system)
3255 (arguments `(#:test-target "tests"))
3256 (home-page "https://github.com/Chris00/ocaml-benchmark")
3257 (synopsis "Benchmark running times of code")
3259 "This module provides a set of tools to measure the running times of
3260 your functions and to easily compare the results. A statistical test
3261 is used to determine whether the results truly differ.")
3262 (license license:lgpl3+)))
3264 (define-public ocaml-batteries
3266 (name "ocaml-batteries")
3271 (url "https://github.com/ocaml-batteries-team/batteries-included")
3272 (commit (string-append "v" version))))
3273 (file-name (git-file-name name version))
3276 "07387jp93civ9p1q2ixmq8qkzzyssp94ssxd4w2ndvkg1nr6kfcl"))))
3277 (build-system ocaml-build-system)
3278 (propagated-inputs (list ocaml-num))
3280 (list ocamlbuild ocaml-benchmark ocaml-qcheck ocaml-qtest))
3283 (modify-phases %standard-phases
3284 (add-after 'unpack 'make-writable
3286 (for-each make-file-writable (find-files "." "."))))
3287 (add-before 'build 'fix-nondeterminism
3289 (substitute* "setup.ml"
3290 (("Sys.readdir dirname")
3291 "let a = Sys.readdir dirname in Array.sort String.compare a; a"))
3293 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-batteries))))
3294 (home-page "http://batteries.forge.ocamlcore.org/")
3295 (synopsis "Development platform for the OCaml programming language")
3296 (description "Define a standard set of libraries which may be expected on
3297 every compliant installation of OCaml and organize these libraries into a
3298 hierarchy of modules.")
3299 (license license:lgpl2.1+)))
3301 (define-public ocaml4.07-batteries
3302 (package-with-ocaml4.07
3304 (inherit ocaml-batteries)
3309 (url "https://github.com/ocaml-batteries-team/batteries-included")
3310 (commit (string-append "v" version))))
3311 (file-name (git-file-name "ocaml-batteries" version))
3314 "02fxa1nkp7rpiwfp04n0sagdp9lad4dh9bvljp95xfshm1cx7y4q"))))
3317 (modify-phases %standard-phases
3318 (delete 'check) ; tests are run by the build phase
3319 (add-before 'build 'fix-nondeterminism
3321 (substitute* "setup.ml"
3322 (("Sys.readdir dirname")
3323 "let a = Sys.readdir dirname in Array.sort String.compare a; a"))
3326 (lambda* (#:key inputs outputs #:allow-other-keys)
3329 (substring str 0 (- (string-length str) 1)))
3331 (find-files "src" ".*.mliv")
3332 (find-files "src" ".*.mlv")
3333 (find-files "src" ".*.mlp")))))
3334 (apply invoke "ocamlbuild" "-no-links" "-use-ocamlfind" "-I" "num"
3335 "-lflag" "-dllpath-all" files)
3336 (for-each (lambda (file)
3337 (copy-file (string-append "_build/" file) file))
3339 (invoke "ocamlbuild" "-no-links" "-use-ocamlfind" "-I" "num"
3340 "-lflag" "-dllpath-all" "build/mkconf.byte")
3341 (copy-file "_build/build/mkconf.byte" "build/mkconf.byte")
3342 (invoke "make" "all")
3345 `(("ocamlbuild" ,ocamlbuild)
3346 ("qtest" ,ocaml-qtest)))
3349 (define-public ocaml-pcre
3357 (url "https://github.com/mmottl/pcre-ocaml")
3359 (file-name (git-file-name name version))
3362 "048k1rl17fcml000yh8fnghk1a06h14lbyrnk9nbigxsymrz6cq2"))))
3363 (build-system dune-build-system)
3368 (list dune-configurator pcre))
3370 `(("pcre:bin" ,pcre "bin")))
3371 (home-page "https://mmottl.github.io/pcre-ocaml")
3373 "Bindings to the Perl Compatibility Regular Expressions library")
3374 (description "Pcre-ocaml offers library functions for string
3375 pattern matching and substitution, similar to the functionality
3376 offered by the Perl language.")
3377 ;; With static linking exception
3378 (license license:lgpl2.1+)))
3380 (define-public ocaml-expect
3382 (name "ocaml-expect")
3386 (uri (ocaml-forge-uri name version 1736))
3389 "098qvg9d4yrqzr5ax291y3whrpax0m3sx4gi6is0mblc96r9yqk0"))))
3392 (build-system ocaml-build-system)
3394 `(("ocamlbuild" ,ocamlbuild)
3395 ("ocaml-num" ,ocaml-num)
3396 ("ocaml-pcre" ,ocaml-pcre)
3397 ("ounit" ,ocaml-ounit)))
3399 `(("batteries" ,ocaml-batteries)))
3400 (home-page "https://forge.ocamlcore.org/projects/ocaml-expect/")
3401 (synopsis "Simple implementation of expect")
3402 (description "This package provides utilities for building unitary testing
3403 of interactive program. You can match the question using a regular expression
3405 (license license:lgpl2.1+))) ; with the OCaml static compilation exception
3407 (define-public ocaml-stdlib-shims
3409 (name "ocaml-stdlib-shims")
3414 (url "https://github.com/ocaml/stdlib-shims")
3416 (file-name (git-file-name name version))
3419 "0gmg8w67j3ww17llk7hl4dx0vq7p50rn5s4ib9sy984k543rz59h"))))
3420 (build-system dune-build-system)
3421 (home-page "https://github.com/ocaml/stdlib-shims")
3422 (synopsis "OCaml stdlib features backport to older OCaml compilers")
3423 (description "This package backports some of the new stdlib features to
3424 older compilers, such as the Stdlib module. This allows projects that require
3425 compatibility with older compiler to use these new features in their code.")
3426 ;; with ocaml-linking exception
3427 (license license:lgpl2.1+)))
3429 (define-public ocaml-fileutils
3431 (name "ocaml-fileutils")
3436 (url "https://github.com/gildor478/ocaml-fileutils")
3437 (commit (string-append "v" version))))
3438 (file-name (git-file-name name version))
3441 "0aa7p5qymi8p7iqym42yk2akjd1ff81fvaks82nhjc533zl01pnf"))))
3442 (build-system dune-build-system)
3444 (list ocaml-stdlib-shims))
3447 (home-page "http://ocaml-fileutils.forge.ocamlcore.org")
3448 (synopsis "Pure OCaml functions to manipulate real file and filename")
3449 (description "Library to provide pure OCaml functions to manipulate real
3450 file (POSIX like) and filename.")
3451 (license license:lgpl2.1+))) ; with the OCaml static compilation exception
3453 (define-public ocaml-oasis
3455 (name "ocaml-oasis")
3459 (uri (ocaml-forge-uri name version 1757))
3462 "0bn13mzfa98dq3y0jwzzndl55mnywaxv693z6f1rlvpdykp3vdqq"))
3463 (modules '((guix build utils)))
3466 (substitute* "test/test-main/Test.ml"
3467 ;; most of these tests fail because ld cannot find crti.o, but according
3468 ;; to the log file, the environment variables {LD_,}LIBRARY_PATH
3469 ;; are set correctly when LD_LIBRARY_PATH is defined beforhand.
3470 (("TestBaseCompat.tests;") "")
3471 (("TestExamples.tests;") "")
3472 (("TestFull.tests;") "")
3473 (("TestPluginDevFiles.tests;") "")
3474 (("TestPluginInternal.tests;") "")
3475 (("TestPluginOCamlbuild.tests;") "")
3476 (("TestPluginOMake.tests;") ""))
3478 (build-system ocaml-build-system)
3482 (list ocamlbuild ocamlify ocamlmod))
3483 (home-page "https://oasis.forge.ocamlcore.org")
3484 (synopsis "Integrates a configure, build, install system in OCaml projects")
3485 (description "OASIS is a tool to integrate a configure, build and install
3486 system in your OCaml projects. It helps to create standard entry points in your
3487 build system and allows external tools to analyse your project easily.")
3488 (license license:lgpl2.1+))) ; with ocaml static compilation exception
3490 (define-public ocaml-cppo
3498 (url "https://github.com/mjambon/cppo")
3499 (commit (string-append "v" version))))
3500 (file-name (git-file-name name version))
3502 "1c8jlr2s0allw1h6czz5q24vn5jsnrrh44j7hjyilzaifm17dlrm"))))
3503 (build-system dune-build-system)
3508 (home-page "https://github.com/mjambon/cppo")
3509 (synopsis "Equivalent of the C preprocessor for OCaml programs")
3510 (description "Cppo is an equivalent of the C preprocessor for OCaml
3511 programs. It allows the definition of simple macros and file inclusion. Cppo is:
3513 @item more OCaml-friendly than @command{cpp}
3514 @item easy to learn without consulting a manual
3515 @item reasonably fast
3516 @item simple to install and to maintain.
3518 (license license:bsd-3)))
3520 (define-public ocaml-seq
3528 (url "https://github.com/c-cube/seq")
3530 (file-name (git-file-name name version))
3532 (base32 "1cjpsc7q76yfgq9iyvswxgic4kfq2vcqdlmxjdjgd4lx87zvcwrv"))))
3533 (build-system ocaml-build-system)
3537 (modify-phases %standard-phases
3541 (lambda* (#:key outputs #:allow-other-keys)
3542 (let ((install-dir (string-append (assoc-ref outputs "out")
3543 "/lib/ocaml/site-lib/seq")))
3544 (mkdir-p install-dir)
3545 (with-output-to-file (string-append install-dir "/META")
3547 (display "name=\"seq\"
3548 version=\"[distributed with ocaml]\"
3549 description=\"dummy package for compatibility\"
3552 (home-page "https://github.com/c-cube/seq")
3553 (synopsis "OCaml's standard iterator type")
3554 (description "This package is a compatibility package for OCaml's
3555 standard iterator type starting from 4.07.")
3556 (license license:lgpl2.1+)))
3558 (define-public ocaml-re
3566 (url "https://github.com/ocaml/ocaml-re")
3568 (file-name (git-file-name name version))
3570 (base32 "1g0vmpx6ylv8m0w77zarn215pgb4czc6gcpb2fi5da1s307zwr0w"))))
3571 (build-system dune-build-system)
3573 `(#:test-target "."))
3577 `(("ounit" ,ocaml-ounit)))
3578 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-re))))
3579 (home-page "https://github.com/ocaml/ocaml-re/")
3580 (synopsis "Regular expression library for OCaml")
3581 (description "Pure OCaml regular expressions with:
3583 @item Perl-style regular expressions (module Re_perl)
3584 @item Posix extended regular expressions (module Re_posix)
3585 @item Emacs-style regular expressions (module Re_emacs)
3586 @item Shell-style file globbing (module Re_glob)
3587 @item Compatibility layer for OCaml's built-in Str module (module Re_str)
3589 (license license:expat)))
3591 (define-public ocaml4.07-re
3592 (package-with-ocaml4.07
3598 (modify-phases %standard-phases
3599 (add-after 'unpack 'fix-dune-version
3601 (delete-file "dune-project"))))))
3604 (define-public ocaml-ocplib-endian
3606 (name "ocaml-ocplib-endian")
3611 (url "https://github.com/OCamlPro/ocplib-endian/")
3615 "1klj4g451s7m5r8bxmwc1rpvngpqdm40csnx9smgc06pwy2fax2c"))
3616 (file-name (git-file-name name version))))
3617 (build-system dune-build-system)
3619 `(#:test-target "tests"))
3621 `(("cppo" ,ocaml-cppo)))
3622 (home-page "https://github.com/OCamlPro/ocplib-endian")
3623 (synopsis "Optimised functions to read and write int16/32/64 from strings
3625 (description "Optimised functions to read and write int16/32/64 from strings
3626 and bigarrays, based on new primitives added in version 4.01. It works on
3627 strings, bytes and bigstring (Bigarrys of chars), and provides submodules for
3628 big- and little-endian, with their unsafe counter-parts.")
3629 (license license:lgpl2.1)))
3631 (define-public ocaml-cstruct
3633 (name "ocaml-cstruct")
3638 (url "https://github.com/mirage/ocaml-cstruct")
3639 (commit (string-append "v" version))))
3640 (file-name (git-file-name name version))
3643 "1pwfkfs8zzr88slnvl5b28lx6w2k149ybgvrs6diay3qvwcmkhx5"))))
3644 (build-system dune-build-system)
3646 `(#:package "cstruct"
3649 (list ocaml-bigarray-compat))
3651 (list ocaml-alcotest))
3652 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-cstruct))))
3653 (home-page "https://github.com/mirage/ocaml-cstruct")
3654 (synopsis "Access C structures via a camlp4 extension")
3655 (description "Cstruct is a library and syntax extension to make it easier
3656 to access C-like structures directly from OCaml. It supports both reading and
3657 writing to these structures, and they are accessed via the Bigarray module.")
3658 (license license:isc)))
3660 (define-public ocaml4.07-cstruct
3661 (package-with-ocaml4.07
3663 (inherit ocaml-cstruct)
3668 (url "https://github.com/mirage/ocaml-cstruct")
3669 (commit (string-append "v" version))))
3670 (file-name (git-file-name "ocaml-cstruct" version))
3673 "0jj3whs8r3jc524i9bb67rffh7y7r157hjgvws0bkxijxpjzwkbk"))))
3676 (define-public ocaml-hex
3683 (url "https://github.com/mirage/ocaml-hex")
3684 (commit (string-append "v" version))))
3685 (file-name (git-file-name name version))
3688 "0xnl5wxd2qrba7phm3mdrjwd2kk26kb17dv94ciwp49ljcj28qc1"))))
3689 (build-system dune-build-system)
3691 `(#:test-target "."))
3693 `(("ocaml-bigarray-compat" ,ocaml-bigarray-compat)
3694 ("cstruct" ,ocaml-cstruct)))
3695 (home-page "https://github.com/mirage/ocaml-hex/")
3696 (synopsis "Minimal library providing hexadecimal converters")
3697 (description "Hex is a minimal library providing hexadecimal converters.")
3698 (license license:isc)))
3700 (define-public ocaml-ezjsonm
3702 (name "ocaml-ezjsonm")
3708 (url "https://github.com/mirage/ezjsonm")
3709 (commit (string-append "v" version))))
3710 (file-name (git-file-name name version))
3712 (base32 "064j9pzy01p3dv947khqyn7fkjbs3jmrqsg8limb4abnlaqxxs2s"))))
3713 (build-system dune-build-system)
3715 `(#:package "ezjsonm"
3717 (native-inputs (list ocaml-alcotest))
3718 (propagated-inputs (list ocaml-hex ocaml-jsonm ocaml-sexplib))
3719 (home-page "https://github.com/mirage/ezjsonm/")
3720 (synopsis "Read and write JSON data")
3721 (description "Ezjsonm provides more convenient (but far less flexible) input
3722 and output functions that go to and from [string] values than jsonm. This avoids
3723 the need to write signal code, which is useful for quick scripts that manipulate
3725 (license license:isc)))
3727 (define-public ocaml-uri
3731 (home-page "https://github.com/mirage/ocaml-uri")
3737 (commit (string-append "v" version))))
3738 (file-name (git-file-name name version))
3741 "1bgkc66cq00mgnkz3i535srwzwc4cpdsv0mly5dzvvq33451xwf0"))))
3742 (build-system dune-build-system)
3743 (arguments '(#:package "uri"
3746 (list ocaml-stringext ocaml-angstrom))
3748 (list ocaml-ounit ocaml-ppx-sexp-conv))
3749 (properties `((upstream-name . "uri")
3750 (ocaml4.07-variant ,(delay ocaml4.07-uri))))
3751 (synopsis "RFC3986 URI/URL parsing library")
3752 (description "OCaml-uri is a library for parsing URI/URL in the RFC3986 format.")
3753 (license license:isc)))
3755 (define-public ocaml4.07-uri
3757 (name "ocaml4.07-uri")
3763 (url "https://github.com/mirage/ocaml-uri")
3764 (commit (string-append "v" version))))
3765 (file-name (git-file-name name version))
3767 (base32 "1ppbav41mszpjcl0zi3fyg958cxyfs57i7kvha4ds9ydn89bjmrh"))))
3768 (build-system dune-build-system)
3772 (modify-phases %standard-phases
3773 (add-before 'build 'update-deprecated
3775 (substitute* "lib/uri.ml"
3776 (("Re.get") "Re.Group.get")))))
3778 #:findlib ,ocaml4.07-findlib
3779 #:dune ,ocaml4.07-dune))
3781 `(("ocaml-ounit" ,(package-with-ocaml4.07 ocaml-ounit))
3782 ("ocaml-ppx-sexp-conv" ,(package-with-ocaml4.07 ocaml-ppx-sexp-conv))))
3784 `(("ocaml-re" ,(package-with-ocaml4.07 ocaml-re))
3785 ("ocaml-sexplib0" ,(package-with-ocaml4.07 ocaml-sexplib0))
3786 ("ocaml-stringext" ,(package-with-ocaml4.07 ocaml-stringext))))
3787 (properties `((upstream-name . "uri")))
3788 (home-page "https://github.com/mirage/ocaml-uri")
3789 (synopsis "RFC3986 URI/URL parsing library")
3790 (description "OCaml-uri is a library for parsing URI/URL in the RFC3986 format.")
3791 (license license:isc)))
3793 (define-public ocaml-easy-format
3795 (name "ocaml-easy-format")
3800 (url "https://github.com/mjambon/easy-format")
3802 (file-name (git-file-name name version))
3805 "0xap6az4yyb60vb1jfs640wl3cf4njv78p538x9ihhf9f6ij3nh8"))))
3806 (build-system dune-build-system)
3808 `(#:package "easy-format"
3810 (modify-phases %standard-phases
3811 (add-before 'build 'make-writable
3816 (find-files "." "."))
3818 (home-page "https://github.com/mjambon/easy-format")
3819 (synopsis "Interface to the Format module")
3820 (description "Easy-format is a high-level and functional interface to the
3821 Format module of the OCaml standard library.")
3822 (license license:bsd-3)))
3824 (define-public ocaml-piqilib
3826 (name "ocaml-piqilib")
3832 (url "https://github.com/alavrik/piqi")
3833 (commit (string-append "v" version))))
3834 (file-name (git-file-name name version))
3836 (base32 "0v04hs85xv6d4ysqxyv1dik34dx49yab9shpi4x7iv19qlzl7csb"))))
3837 (build-system ocaml-build-system)
3840 (modify-phases %standard-phases
3841 (add-before 'configure 'fix-ocamlpath
3843 (substitute* '("Makefile" "make/Makefile.ocaml")
3844 (("OCAMLPATH := ") "OCAMLPATH := $(OCAMLPATH):"))))
3846 (lambda* (#:key outputs #:allow-other-keys)
3847 (let ((out (assoc-ref outputs "out")))
3848 (substitute* "make/OCamlMakefile"
3849 (("/bin/sh") (which "bash")))
3850 (invoke "./configure" "--prefix" out "--ocaml-libdir"
3851 (string-append out "/lib/ocaml/site-lib")))))
3852 (add-after 'build 'build-ocaml
3853 (lambda* (#:key outputs #:allow-other-keys)
3854 (invoke "make" "ocaml")))
3855 (add-after 'install 'install-ocaml
3856 (lambda* (#:key outputs #:allow-other-keys)
3857 (invoke "make" "ocaml-install")))
3858 (add-after 'install-ocaml 'link-stubs
3859 (lambda* (#:key outputs #:allow-other-keys)
3860 (let* ((out (assoc-ref outputs "out"))
3861 (stubs (string-append out "/lib/ocaml/site-lib/stubslibs"))
3862 (lib (string-append out "/lib/ocaml/site-lib/piqilib")))
3864 (symlink (string-append lib "/dllpiqilib_stubs.so")
3865 (string-append stubs "/dllpiqilib_stubs.so"))))))))
3869 `(("ocaml-xmlm" ,ocaml-xmlm)
3870 ("ocaml-sedlex" ,ocaml-sedlex)
3871 ("ocaml-easy-format" ,ocaml-easy-format)
3872 ("ocaml-base64" ,ocaml-base64)))
3873 (home-page "http://piqi.org")
3874 (synopsis "Data serialization and conversion library")
3875 (description "Piqilib is the common library used by the piqi command-line
3876 tool and piqi-ocaml.")
3877 (license license:asl2.0)))
3879 (define-public ocaml-uuidm
3881 (name "ocaml-uuidm")
3885 (uri (string-append "http://erratique.ch/software/uuidm/"
3886 "releases/uuidm-" version ".tbz"))
3889 "1cr6xlzla9fmd587lfhzac0icifspjnqi9f4cdafshj3jn85nrpw"))))
3890 (build-system ocaml-build-system)
3893 (list "build" "--tests" "true" "--with-cmdliner" "true")
3895 (modify-phases %standard-phases
3896 (delete 'configure))))
3898 (list ocamlbuild opam))
3900 `(("cmdliner" ,ocaml-cmdliner)
3901 ("topkg" ,ocaml-topkg)))
3902 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-uuidm))))
3903 (home-page "https://erratique.ch/software/uuidm")
3904 (synopsis "Universally unique identifiers for OCaml")
3905 (description "Uuidm is an OCaml module implementing 128 bits universally
3906 unique identifiers (UUIDs) version 3, 5 (named based with MD5, SHA-1 hashing)
3907 and 4 (random based) according to RFC 4122.")
3908 (license license:isc)))
3910 (define-public ocaml4.07-uuidm
3911 (package-with-ocaml4.07
3913 (inherit ocaml-uuidm)
3917 (uri (string-append "http://erratique.ch/software/uuidm/"
3918 "releases/uuidm-" version ".tbz"))
3921 "1ivxb3hxn9bk62rmixx6px4fvn52s4yr1bpla7rgkcn8981v45r8"))))
3924 (define-public ocaml-graph
3926 (name "ocaml-graph")
3930 (uri (string-append "http://ocamlgraph.lri.fr/download/"
3931 "ocamlgraph-" version ".tar.gz"))
3934 "0m9g16wrrr86gw4fz2fazrh8nkqms0n863w7ndcvrmyafgxvxsnr"))))
3935 (build-system ocaml-build-system)
3937 `(#:install-target "install-findlib"
3940 (modify-phases %standard-phases
3941 (add-before 'configure 'set-shell
3942 (lambda* (#:key inputs #:allow-other-keys)
3943 (setenv "CONFIG_SHELL"
3944 (search-input-file inputs "/bin/sh")))))))
3945 (inputs (list lablgtk))
3946 (properties `((upstream-name . "ocamlgraph")))
3947 (home-page "http://ocamlgraph.lri.fr/")
3948 (synopsis "Graph library for OCaml")
3949 (description "OCamlgraph is a generic graph library for OCaml.")
3950 (license license:lgpl2.1)))
3952 (define-public ocaml-piqi
3959 (url "https://github.com/alavrik/piqi-ocaml")
3960 (commit (string-append "v" version))))
3961 (file-name (git-file-name name version))
3964 "1913jpsb8mvqi8609j4g4sm5jhg50dq0xqxgy8nmvknfryyc89nm"))))
3965 (build-system ocaml-build-system)
3968 ,#~(list (string-append "DESTDIR=" #$output)
3969 (string-append "SHELL="
3970 #+(file-append (canonical-package bash-minimal)
3973 (modify-phases %standard-phases
3974 (add-after 'unpack 'make-files-writable
3976 (for-each make-file-writable (find-files "."))
3978 (delete 'configure))))
3980 (list which protobuf)) ; for tests
3982 `(("ocaml-num" ,ocaml-num)
3983 ("ocaml-piqilib" ,ocaml-piqilib)
3984 ("ocaml-stdlib-shims" ,ocaml-stdlib-shims)))
3985 (home-page "https://github.com/alavrik/piqi-ocaml")
3986 (synopsis "Protocol serialization system for OCaml")
3987 (description "Piqi is a multi-format data serialization system for OCaml.
3988 It provides a uniform interface for serializing OCaml data structures to JSON,
3989 XML and Protocol Buffers formats.")
3990 (license license:asl2.0)))
3996 (home-page "https://github.com/BinaryAnalysisPlatform/bap")
4001 (commit (string-append "v" version))))
4002 (file-name (git-file-name name version))
4005 "0lb9xkfp67wjjqr75p6krivmjra7l5673236v9ny4gp0xi0755bk"))))
4006 (build-system ocaml-build-system)
4008 `(("ocaml-oasis" ,(package-with-ocaml4.07 ocaml-oasis))
4009 ("clang" ,clang-3.8)
4010 ("ocaml-ounit" ,(package-with-ocaml4.07 ocaml-ounit))))
4012 `(("camlzip" ,(package-with-ocaml4.07 camlzip))
4013 ("ocaml-bitstring" ,(package-with-ocaml4.07 ocaml-bitstring))
4014 ("ocaml-cmdliner" ,(package-with-ocaml4.07 ocaml-cmdliner))
4015 ("ocaml-core-kernel" ,ocaml4.07-core-kernel)
4016 ("ocaml-ezjsonm" ,(package-with-ocaml4.07 ocaml-ezjsonm))
4017 ("ocaml-fileutils" ,(package-with-ocaml4.07 ocaml-fileutils))
4018 ("ocaml-frontc" ,(package-with-ocaml4.07 ocaml-frontc))
4019 ("ocaml-graph" ,(package-with-ocaml4.07 ocaml-graph))
4020 ("ocaml-ocurl" ,(package-with-ocaml4.07 ocaml-ocurl))
4021 ("ocaml-piqi" ,(package-with-ocaml4.07 ocaml-piqi))
4022 ("ocaml-ppx-jane" ,ocaml4.07-ppx-jane)
4023 ("ocaml-utop" ,ocaml4.07-utop)
4024 ("ocaml-uuidm" ,(package-with-ocaml4.07 ocaml-uuidm))
4025 ("ocaml-uri" ,ocaml4.07-uri)
4026 ("ocaml-zarith" ,(package-with-ocaml4.07 ocaml-zarith))))
4028 (list gmp llvm-3.8 ncurses))
4032 (modify-phases %standard-phases
4033 (add-before 'configure 'fix-ncurses
4035 (substitute* "oasis/llvm"
4036 (("-lcurses") "-lncurses"))
4039 (lambda* (#:key outputs inputs #:allow-other-keys)
4040 ;; add write for user, to prevent a failure in the install phase
4043 (let ((stat (stat file)))
4044 (chmod file (+ #o200 (stat:mode stat)))))
4045 (find-files "." "."))
4046 (invoke "./configure" "--prefix"
4047 (assoc-ref outputs "out")
4050 (assoc-ref outputs "out")
4051 "/lib/ocaml/site-lib")
4052 "--with-llvm-version=3.8"
4053 "--with-llvm-config=llvm-config"
4054 "--enable-everything"))))
4056 #:findlib ,ocaml4.07-findlib))
4057 (synopsis "Binary Analysis Platform")
4058 (description "Binary Analysis Platform is a framework for writing program
4059 analysis tools, that target binary files. The framework consists of a plethora
4060 of libraries, plugins, and frontends. The libraries provide code reusability,
4061 the plugins facilitate extensibility, and the frontends serve as entry points.")
4062 (license license:expat)))
4064 (define-public ocaml-camomile
4066 (name "ocaml-camomile")
4068 (home-page "https://github.com/yoriyuki/Camomile")
4071 (uri (string-append home-page "/releases/download/" version
4072 "/camomile-" version ".tbz"))
4075 "0chn7ldqb3wyf95yhmsxxq65cif56smgz1mhhc7m0dpwmyq1k97h"))))
4076 (build-system dune-build-system)
4078 `(#:test-target "camomile-test"
4079 #:tests? #f ; Tests fail, see https://github.com/yoriyuki/Camomile/issues/82
4081 (modify-phases %standard-phases
4082 (add-before 'build 'fix-usr-share
4083 (lambda* (#:key outputs #:allow-other-keys)
4084 (substitute* '("Camomile/dune" "configure.ml")
4085 (("/usr/share") (string-append (assoc-ref outputs "out") "/share")))
4087 (synopsis "Comprehensive Unicode library")
4088 (description "Camomile is a Unicode library for OCaml. Camomile provides
4089 Unicode character type, UTF-8, UTF-16, UTF-32 strings, conversion to/from about
4090 200 encodings, collation and locale-sensitive case mappings, and more. The
4091 library is currently designed for Unicode Standard 3.2.")
4092 ;; with an exception for linked libraries to use a different license
4093 (license license:lgpl2.0+)))
4095 (define-public ocaml-charinfo-width
4096 ;; Add LICENSE file and Dune tests
4097 (let ((commit "20aaaa6dca8f1e0b1ace55b6f2a8ba5e5910b620"))
4099 (name "ocaml-charinfo-width")
4100 (version (git-version "1.1.0" "1" commit))
4101 (home-page "https://github.com/kandu/charinfo_width/")
4107 (file-name (git-file-name name version))
4110 "04gil5hxm2jax9paw3i24d8zyzhyl5cphzfyryvy2lcrm3c485q0"))))
4111 (build-system dune-build-system)
4113 (list ocaml-result ocaml-camomile))
4115 (list ocaml-ppx-expect))
4117 `((upstream-name . "charInfo_width")))
4118 (synopsis "Determine column width for a character")
4119 (description "This module implements purely in OCaml a character width
4120 function that follows the prototype of POSIX's wcwidth.")
4121 (license license:expat))))
4123 (define-public ocaml-zed
4127 (home-page "https://github.com/ocaml-community/zed")
4134 (file-name (git-file-name name version))
4136 (base32 "04vr1a94imsghm98iigc35rhifsz0rh3qz2qm0wam2wvp6vmrx0p"))))
4137 (build-system dune-build-system)
4139 `(#:test-target "."))
4141 `(("ocaml-charInfo-width" ,ocaml-charinfo-width)
4142 ("ocaml-camomile" ,ocaml-camomile)
4143 ("ocaml-react" ,ocaml-react)))
4144 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-zed))))
4145 (synopsis "Abstract engine for text edition in OCaml")
4147 "This module provides an abstract engine for text edition. It can be
4148 used to write text editors, edition widgets, readlines, and more. The module
4149 Zed uses Camomile to fully support the Unicode specification, and implements
4150 an UTF-8 encoded string type with validation, and a rope datastructure to
4151 achieve efficient operations on large Unicode buffers. Zed also features a
4152 regular expression search on ropes. To support efficient text edition
4153 capabilities, Zed provides macro recording and cursor management facilities.")
4154 (license license:bsd-3)))
4156 (define-public ocaml4.07-zed
4157 (package-with-ocaml4.07
4164 (url "https://github.com/ocaml-community/zed")
4166 (file-name (git-file-name "ocaml4.07-zed" version))
4169 "0pa9awinqr0plp4b2az78dwpvh01pwaljnn5ydg8mc6hi7rmir55"))))
4172 (define-public ocaml-lambda-term
4174 (name "ocaml-lambda-term")
4176 (home-page "https://github.com/ocaml-community/lambda-term")
4182 (file-name (git-file-name name version))
4185 "048k26644wq5wlwk0j179dxrxyz9nxqqq4vvhyh6pqpgxdajd44i"))))
4186 (build-system dune-build-system)
4188 `(#:test-target "."))
4197 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-lambda-term))))
4198 (synopsis "Terminal manipulation library for OCaml")
4199 (description "Lambda-Term is a cross-platform library for manipulating the
4200 terminal. It provides an abstraction for keys, mouse events, colors, as well as
4201 a set of widgets to write curses-like applications. The main objective of
4202 Lambda-Term is to provide a higher level functional interface to terminal
4203 manipulation than, for example, ncurses, by providing a native OCaml interface
4204 instead of bindings to a C library.")
4205 (license license:bsd-3)))
4207 (define-public ocaml4.07-lambda-term
4208 (package-with-ocaml4.07
4210 (inherit ocaml-lambda-term)
4216 (url "https://github.com/ocaml-community/lambda-term")
4218 (file-name (git-file-name "ocaml4.07-lambda-term" version))
4220 (base32 "0zcjy6fvf0d3i2ssz96asl889n3r6bplyzk7xvb2s3dkxbgcisyy"))))
4222 `(("ocaml-lwt" ,ocaml-lwt)
4223 ("ocaml-lwt-log" ,ocaml-lwt-log)
4224 ("ocaml-lwt-react" ,ocaml-lwt-react)
4225 ("ocaml-zed" ,ocaml-zed)))
4228 (define-public ocaml-utop
4236 (url "https://github.com/ocaml-community/utop")
4238 (file-name (git-file-name name version))
4240 (base32 "0z5anakgbndhyzbi570pfs2fy69bnmgq9jflgfbly2rhbhwa7wgj"))))
4241 (build-system dune-build-system)
4243 `(#:test-target "."))
4247 (list ocaml-lambda-term ocaml-lwt ocaml-lwt-react ocaml-camomile
4249 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-utop))))
4250 (home-page "https://github.com/ocaml-community/utop")
4251 (synopsis "Improved interface to the OCaml toplevel")
4252 (description "UTop is an improved toplevel for OCaml. It can run in a
4253 terminal or in Emacs. It supports line editing, history, real-time and context
4254 sensitive completion, colors, and more.")
4255 (license license:bsd-3)))
4257 (define-public ocaml4.07-utop
4258 (package-with-ocaml4.07
4260 (inherit ocaml-utop)
4266 (url "https://github.com/ocaml-community/utop")
4268 (file-name (git-file-name "ocaml4.07-utop" version))
4270 (base32 "1bl4943qpi3qy152dbdm5glhx19zsiylmn4rcxi8l66g58hikyjp"))))
4272 `(("ocaml-lambda-term" ,ocaml-lambda-term)
4273 ("ocaml-lwt" ,ocaml-lwt)
4274 ("ocaml-react" ,ocaml-react)
4275 ("ocaml-camomile" ,ocaml-camomile)
4276 ("ocaml-zed" ,ocaml-zed)))
4279 (define-public ocaml-integers
4281 (name "ocaml-integers")
4283 (home-page "https://github.com/ocamllabs/ocaml-integers")
4289 (file-name (git-file-name name version))
4292 "0c0bmy53ag6504kih0cvnp4yf7mbcimb18m1mgs592ffb0zj1rff"))))
4293 (build-system dune-build-system)
4295 `(#:tests? #f)) ; no tests
4297 (list ocaml-stdlib-shims))
4298 (synopsis "Various signed and unsigned integer types for OCaml")
4299 (description "The ocaml-integers library provides a number of 8-, 16-, 32-
4300 and 64-bit signed and unsigned integer types, together with aliases such as
4301 long and size_t whose sizes depend on the host platform.")
4302 (license license:expat)))
4304 (define-public ocaml-ctypes
4306 (name "ocaml-ctypes")
4308 (home-page "https://github.com/ocamllabs/ocaml-ctypes")
4314 (file-name (git-file-name name version))
4317 "0ilzq9qzvwv9rc08cc9wchsx636zp870i7qvqmbigaa2qb812m0z"))))
4318 (build-system ocaml-build-system)
4321 (modify-phases %standard-phases
4322 (add-after 'unpack 'make-writable
4324 (for-each make-file-writable
4326 (delete 'configure))))
4328 `(("pkg-config" ,pkg-config)
4329 ("ounit" ,ocaml-ounit)
4330 ("lwt" ,ocaml-lwt)))
4332 `(("bigarray-compat" ,ocaml-bigarray-compat)
4333 ("integers" ,ocaml-integers)))
4336 (synopsis "Library for binding to C libraries using pure OCaml")
4337 (description "Ctypes is a library for binding to C libraries using pure
4338 OCaml. The primary aim is to make writing C extensions as straightforward as
4339 possible. The core of ctypes is a set of combinators for describing the
4340 structure of C types -- numeric types, arrays, pointers, structs, unions and
4341 functions. You can use these combinators to describe the types of the
4342 functions that you want to call, then bind directly to those functions -- all
4343 without writing or generating any C!")
4344 (license license:expat)))
4346 (define-public ocaml-ocb-stubblr
4348 (name "ocaml-ocb-stubblr")
4350 (home-page "https://github.com/pqwy/ocb-stubblr")
4354 home-page "/releases/download/v0.1.1/ocb-stubblr-"
4356 (file-name (string-append name "-" version ".tbz"))
4359 "167b7x1j21mkviq8dbaa0nmk4rps2ilvzwx02igsc2706784z72f"))))
4360 (build-system ocaml-build-system)
4362 `(#:build-flags (list "build" "--tests" "true")
4364 (modify-phases %standard-phases
4366 (add-before 'build 'fix-for-guix
4368 (substitute* "src/ocb_stubblr.ml"
4369 ;; Do not fail when opam is not present or initialized
4370 (("error_msgf \"error running opam\"") "\"\"")
4371 ;; Guix doesn't have cc, but it has gcc
4372 (("\"cc\"") "\"gcc\""))
4375 `(("topkg" ,ocaml-topkg)
4378 `(("astring" ,ocaml-astring)
4379 ("ocamlbuild" ,ocamlbuild)))
4380 (synopsis "OCamlbuild plugin for C stubs")
4381 (description "Ocb-stubblr is about ten lines of code that you need to
4382 repeat over, over, over and over again if you are using ocamlbuild to build
4383 OCaml projects that contain C stubs.")
4384 (license license:isc)))
4386 (define-public ocaml-tsdl
4390 (home-page "https://erratique.ch/software/tsdl")
4393 (uri (string-append home-page "/releases/tsdl-"
4395 (file-name (string-append name "-" version ".tar.gz"))
4398 "1m565jgfanijjzp64c1rylahkpmrrb03ywj202j49n06nvwp788s"))))
4399 (build-system ocaml-build-system)
4401 `(#:build-flags '("build")
4402 #:tests? #f; tests require a display device
4404 (modify-phases %standard-phases
4405 (delete 'configure))))
4407 (list ocamlbuild ocaml-astring opam pkg-config))
4409 `(("topkg" ,ocaml-topkg)
4411 ("integers" ,ocaml-integers)
4412 ("ctypes" ,ocaml-ctypes)))
4413 (synopsis "Thin bindings to SDL for OCaml")
4414 (description "Tsdl is an OCaml library providing thin bindings to the
4415 cross-platform SDL C library.")
4416 (license license:isc)))
4418 (define-public dedukti
4422 (home-page "https://deducteam.github.io/")
4427 (url "https://github.com/deducteam/dedukti")
4428 (commit (string-append "v" version))))
4429 (file-name (git-file-name name version))
4432 "0frl3diff033i4fmq304b8wbsdnc9mvlhmwd7a3zd699ng2lzbxb"))))
4434 `(("menhir" ,ocaml-menhir)))
4437 (build-system ocaml-build-system)
4440 ,#~(modify-phases %standard-phases
4447 (invoke "make" "tests")))
4448 (add-before 'install 'set-binpath
4449 ;; Change binary path in the makefile
4451 (substitute* "GNUmakefile"
4453 (string-append "BINDIR = " #$output "/bin")))))
4456 (invoke "make" "install"))))))
4457 (synopsis "Proof-checker for the λΠ-calculus modulo theory, an extension of
4459 (description "Dedukti is a proof-checker for the λΠ-calculus modulo
4460 theory. The λΠ-calculus is an extension of the simply typed λ-calculus with
4461 dependent types. The λΠ-calculus modulo theory is itself an extension of the
4462 λΠ-calculus where the context contains variable declaration as well as rewrite
4463 rules. This system is not designed to develop proofs, but to check proofs
4464 developed in other systems. In particular, it enjoys a minimalistic syntax.")
4465 (license license:cecill-c)))
4467 (define-public emacs-dedukti-mode
4468 (let ((commit "d7c3505a1046187de3c3aeb144455078d514594e"))
4470 (name "emacs-dedukti-mode")
4471 (version (git-version "0" "0" commit))
4472 (home-page "https://github.com/rafoo/dedukti-mode")
4480 "1842wikq24c8rg0ac84vb1qby9ng1nssxswyyni4kq85lng5lcrp"))
4481 (file-name (git-file-name name version))))
4484 (build-system emacs-build-system)
4487 (modify-phases %standard-phases
4488 (add-before 'install 'patch-dkpath
4490 (let ((dkcheck-path (which "dkcheck")))
4491 (substitute* "dedukti-mode.el"
4492 (("dedukti-path \"(.*)\"")
4493 (string-append "dedukti-path \"" dkcheck-path "\"")))))))))
4494 (synopsis "Emacs major mode for Dedukti files")
4495 (description "This package provides an Emacs major mode for editing
4497 (license license:cecill-b))))
4499 (define-public emacs-flycheck-dedukti
4500 (let ((commit "3dbff5646355f39d57a3ec514f560a6b0082a1cd"))
4502 (name "emacs-flycheck-dedukti")
4503 (version (git-version "0" "0" commit))
4504 (home-page "https://github.com/rafoo/flycheck-dedukti")
4512 "1ffpxnwl3wx244n44mbw81g00nhnykd0lnid29f4aw1av7w6nw8l"))
4513 (file-name (git-file-name name version))))
4514 (build-system emacs-build-system)
4516 (list emacs-dedukti-mode emacs-flycheck))
4517 (synopsis "Flycheck integration for the dedukti language")
4518 (description "This package provides a frontend for Flycheck to perform
4519 syntax checking on dedukti files.")
4520 (license license:cecill-b))))
4522 (define-public ocaml-jst-config
4524 (name "ocaml-jst-config")
4530 (url "https://github.com/janestreet/jst-config")
4531 (commit (string-append "v" version))))
4532 (file-name (git-file-name name version))
4535 "1yp5p63clvaxmkf7vlasgyapxc31x29c154pyq63n0fvi2fpf4y3"))))
4536 (build-system dune-build-system)
4537 (arguments '(#:tests? #f)) ; no tests
4539 (list ocaml-base ocaml-ppx-assert ocaml-stdio dune-configurator))
4540 (home-page "https://github.com/janestreet/jst-config")
4541 (synopsis "Compile-time configuration for Jane Street libraries")
4542 (description "Defines compile-time constants used in Jane Street libraries
4543 such as Base, Core, and Async. This package has an unstable interface; it is
4544 intended only to share configuration between different packages from Jane
4545 Street. Future updates may not be backward-compatible, and we do not
4546 recommend using this package directly.")
4547 (license license:expat)))
4549 (define-public ocaml-jane-street-headers
4551 (name "ocaml-jane-street-headers")
4555 "jane-street-headers" version
4556 "1r27r0bxxa0iaah5rm84lwhrmh784vfpmb6056hpv0p34rxs7r1l"))
4557 (build-system dune-build-system)
4558 (arguments '(#:tests? #f)) ; no tests
4559 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-jane-street-headers))))
4560 (home-page "https://github.com/janestreet/jane-street-headers")
4561 (synopsis "Jane Street C header files")
4562 (description "C header files shared between the various Jane Street
4564 (license license:expat)))
4566 (define-public ocaml-time-now
4568 (name "ocaml-time-now")
4573 "1a6b1f55mwci1bd8w8vji0qn6wbs60jbwixvwgy4klx2blq57cqk"))
4574 (build-system dune-build-system)
4575 (arguments '(#:tests? #f)) ; no tests
4577 (list ocaml-base ocaml-jane-street-headers ocaml-jst-config
4578 ocaml-ppx-base ocaml-ppx-optcomp))
4579 (properties `((upstream-name . "time_now")))
4581 "https://github.com/janestreet/time_now")
4582 (synopsis "Reports the current time")
4584 "Provides a single function to report the current time in nanoseconds
4585 since the start of the Unix epoch.")
4586 (license license:expat)))
4588 (define-public ocaml-ppx-inline-test
4590 (name "ocaml-ppx-inline-test")
4592 (home-page "https://github.com/janestreet/ppx_inline_test")
4597 (url (string-append home-page ".git"))
4598 (commit (string-append "v" version))))
4599 (file-name (git-file-name name version))
4602 "1a0gaj9p6gbn5j7c258mnzr7yjlq0hqi3aqqgyj1g2dbk1sxdbjz"))))
4603 (build-system dune-build-system)
4605 `(#:tests? #f)) ;see home page README for further information
4608 ocaml-migrate-parsetree
4614 (properties `((upstream-name . "ppx_inline_test")
4615 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-inline-test))))
4616 (synopsis "Syntax extension for writing in-line tests in ocaml code")
4617 (description "This package contains a syntax extension for writing
4618 in-line tests in ocaml code. It is part of Jane Street's PPX rewriters
4620 (license license:expat)))
4622 (define-public ocaml4.07-ppx-inline-test
4623 (package-with-ocaml4.07
4625 (inherit ocaml-ppx-inline-test)
4626 (name "ocaml-ppx-inline-test")
4628 (home-page "https://github.com/janestreet/ppx_inline_test")
4633 (url (string-append home-page ".git"))
4634 (commit (string-append "v" version))))
4635 (file-name (git-file-name name version))
4638 "0nyz411zim94pzbxm2l2v2l9jishcxwvxhh142792g2s18r4vn50"))))
4640 `(("ocaml-base" ,ocaml-base)
4641 ("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)
4642 ("ocaml-compiler-libs" ,ocaml-compiler-libs)
4643 ("ocaml-sexplib0" ,ocaml-sexplib0)
4644 ("ocaml-stdio" ,ocaml-stdio)
4645 ("ocaml-ppxlib" ,ocaml-ppxlib)))
4646 (properties `((upstream-name . "ppx_inline_test"))))))
4648 (define-public ocaml-bindlib
4650 (name "ocaml-bindlib")
4656 (url "https://github.com/rlepigre/ocaml-bindlib")
4658 (file-name (git-file-name name version))
4661 "1viyws3igy49hfaj4jaiwm4iggck9zdn7r3g6kh1n4zxphqk57yk"))))
4662 (build-system dune-build-system)
4664 `(#:test-target "."))
4666 (list ocamlbuild ocaml-findlib))
4667 (home-page "https://rlepigre.github.io/ocaml-bindlib/")
4668 (synopsis "OCaml Bindlib library for bound variables")
4669 (description "Bindlib is a library allowing the manipulation of data
4670 structures with bound variables. It is particularly useful when writing ASTs
4671 for programming languages, but also for manipulating terms of the λ-calculus
4672 or quantified formulas.")
4673 (license license:gpl3+)))
4675 (define-public ocaml-earley
4677 (name "ocaml-earley")
4679 (home-page "https://github.com/rlepigre/ocaml-earley")
4684 (url (string-append home-page ".git"))
4686 (file-name (git-file-name name version))
4689 "1vi58zdxchpw6ai0bz9h2ggcmg8kv57yk6qbx82lh47s5wb3mz5y"))))
4690 (build-system dune-build-system)
4692 `(#:test-target "."))
4694 (list ocaml-stdlib-shims))
4695 (synopsis "Parsing library based on Earley Algorithm")
4696 (description "Earley is a parser combinator library base on Earley's
4697 algorithm. It is intended to be used in conjunction with an OCaml syntax
4698 extension which allows the definition of parsers inside the language. There
4699 is also support for writing OCaml syntax extensions in a camlp4 style.")
4700 (license license:cecill-b)))
4702 (define-public ocaml-timed
4704 (name "ocaml-timed")
4706 (home-page "https://github.com/rlepigre/ocaml-timed")
4710 (url (string-append home-page ".git"))
4711 (commit (string-append name "_" version))))
4714 "0hfxz710faxy5yk97bkfnw87r732jcxxhmjppwrbfdb6pd0wks96"))
4715 (file-name (git-file-name name version))))
4716 (build-system ocaml-build-system)
4719 (modify-phases %standard-phases
4726 (invoke "make" "install")))
4729 (invoke "make" "tests"))))))
4730 (synopsis "Timed references for imperative state")
4731 (description "Timed references for imperative state. This module provides
4732 an alternative type for references (or mutable cells) supporting undo/redo
4733 operations. In particular, an abstract notion of time is used to capture the
4734 state of the references at any given point, so that it can be restored. Note
4735 that usual reference operations only have a constant time / memory overhead
4736 (compared to those of the standard library).
4738 Moreover, we provide an alternative implementation based on the references
4739 of the standard library (Pervasives module). However, it is less efficient
4740 than the first one.")
4741 (license license:expat)))
4743 (define-public ocaml-biniou
4745 (name "ocaml-biniou")
4747 (home-page "https://github.com/mjambon/biniou")
4752 (url (string-append home-page ".git"))
4754 (file-name (git-file-name name version))
4757 "0x2kiy809n1j0yf32l7hj102y628jp5jdrkbi3z7ld8jq04h1790"))))
4758 (build-system dune-build-system)
4761 (modify-phases %standard-phases
4762 (add-before 'build 'make-writable
4763 (lambda _ (for-each make-file-writable (find-files "." ".")))))))
4765 (list ocaml-easy-format))
4768 (synopsis "Data format designed for speed, safety, ease of use and backward
4770 (description "Biniou (pronounced \"be new\" is a binary data format
4771 designed for speed, safety, ease of use and backward compatibility as
4772 protocols evolve. Biniou is vastly equivalent to JSON in terms of
4773 functionality but allows implementations several times faster (4 times faster
4774 than yojson), with 25-35% space savings.")
4775 (license license:bsd-3)))
4777 (define-public ocaml-yojson
4779 (name "ocaml-yojson")
4781 (home-page "https://github.com/ocaml-community/yojson")
4786 (url (string-append home-page ".git"))
4788 (file-name (git-file-name name version))
4791 "0zncsw8bgbkh1pfvfc7nh628hfj84lgx6jwhp9ashj3z1z0w3xjn"))))
4792 (build-system dune-build-system)
4794 `(#:test-target "."))
4796 (list ocaml-biniou ocaml-easy-format))
4798 (list ocaml-alcotest ocaml-cppo))
4799 (synopsis "Low-level JSON library for OCaml")
4800 (description "Yojson is an optimized parsing and printing library for the
4801 JSON format. It addresses a few shortcomings of json-wheel including 2x
4802 speedup, polymorphic variants and optional syntax for tuples and variants.
4803 @code{ydump} is a pretty printing command-line program provided with the
4804 yojson package. The program @code{atdgen} can be used to derive OCaml-JSON
4805 serializers and deserializers from type definitions.")
4806 (license license:bsd-3)))
4808 (define-public ocaml-craml
4810 (name "ocaml-craml")
4812 (home-page "https://github.com/realworldocaml/craml")
4817 (url (string-append home-page ".git"))
4819 (file-name (git-file-name name version))
4822 "197xjp4vmzdymf2ndinw271ihpf45h04mx8gqj8ypspxdr5fj1a5"))))
4823 (build-system dune-build-system)
4826 (modify-phases %standard-phases
4827 (add-before 'build 'upgrade
4829 (invoke "dune" "upgrade")
4832 (list ocaml-fmt ocaml-astring ocaml-logs ocaml-cmdliner))
4834 "CRAM-testing framework for testing command line applications")
4835 (description "CRAM is a is functional testing framework for command line
4836 applications. @code{craml} is freely inspired by the
4837 Mercurial's @code{https://www.selenic.com/blog/?p=663, unified test
4838 format}. @code{craml} is released as a single binary (called @code{craml}).")
4839 (license license:isc)))
4841 (define-public ocaml-dot-merlin-reader
4843 (name "ocaml-dot-merlin-reader")
4849 (url "https://github.com/ocaml/merlin")
4850 (commit (string-append "v" version))))
4851 (file-name (git-file-name name version))
4854 "125gyk63fg9plqkyrkl3wvpr3czjxgvshf4496fc4swldl7z587c"))))
4855 (build-system dune-build-system)
4856 (arguments '(#:package "dot-merlin-reader"
4857 #:tests? #f)) ; no tests
4859 (list ocaml-yojson ocaml-csexp ocaml-result))
4860 (home-page "https://ocaml.github.io/merlin/")
4861 (synopsis "Reads config files for @code{ocaml-merlin}")
4862 (description "@code{ocaml-dot-merlin-reader} is an external reader for
4863 @code{ocaml-merlin} configurations.")
4864 (license license:expat)))
4866 (define-public ocaml-merlin
4868 (inherit ocaml-dot-merlin-reader)
4869 (name "ocaml-merlin")
4871 '(#:package "merlin"
4873 (modify-phases %standard-phases
4875 (lambda* (#:key tests? #:allow-other-keys)
4877 (invoke "dune" "runtest" "-p" "merlin,dot-merlin-reader")))))))
4879 (list ocaml-yojson ocaml-csexp ocaml-result))
4881 (list ocaml-dot-merlin-reader ; required for tests
4883 (synopsis "Context sensitive completion for OCaml in Vim and Emacs")
4884 (description "Merlin is an editor service that provides modern IDE
4885 features for OCaml. Emacs and Vim support is provided out-of-the-box.
4886 External contributors added support for Visual Studio Code, Sublime Text and
4888 (license license:expat)))
4890 (define-public ocaml-gsl
4899 "https://github.com/mmottl/gsl-ocaml/releases/download/"
4900 version "/gsl-" version ".tbz"))
4903 "1l5zkkkg8sglsihrbf10ivq9s8xzl1y6ag89i4jqpnmi4m43fy34"))))
4904 (build-system dune-build-system)
4908 (modify-phases %standard-phases
4909 (add-after 'unpack 'fix-gsl-directory
4910 (lambda* (#:key inputs #:allow-other-keys)
4911 (substitute* "src/config/discover.ml"
4912 (("/usr") (assoc-ref inputs "gsl"))))))))
4916 (list ocaml-base ocaml-stdio))
4917 (home-page "https://mmottl.github.io/gsl-ocaml")
4918 (synopsis "Bindings to the GNU Scientific Library")
4920 "GSL-OCaml is an interface to the @dfn{GNU scientific library} (GSL) for
4921 the OCaml language.")
4922 (license license:gpl3+)))
4924 (define-public ocaml4.07-gsl-1
4925 (package-with-ocaml4.07
4931 (uri (string-append "https://github.com/mmottl/gsl-ocaml"
4932 "/releases/download/v"
4933 version "/gsl-ocaml-" version ".tar.gz"))
4936 "0nzp43hp8pbjqkrxnwp5lgjrabxayf61h18fjaydi0s5faq6f3xh"))))
4937 (build-system ocaml-build-system)
4939 `(("gsl" ,gsl-static)))
4941 `(("ocamlbuild" ,ocamlbuild)))
4943 (propagated-inputs '()))))
4945 (define-public cubicle
4951 (uri (string-append "http://cubicle.lri.fr/cubicle-"
4955 "10kk80jdmpdvql88sdjsh7vqzlpaphd8vip2lp47aarxjkwjlz1q"))))
4956 (build-system gnu-build-system)
4958 (list automake ocaml
4959 (@@ (gnu packages base) which)))
4961 (list ocaml-num z3))
4963 `(#:configure-flags (list "--with-z3")
4964 #:make-flags (list "QUIET=")
4967 (modify-phases %standard-phases
4968 (add-before 'configure 'make-deterministic
4970 (substitute* "Makefile.in"
4971 (("`date`") "no date for reproducibility"))))
4972 (add-before 'configure 'configure-for-release
4974 (substitute* "Makefile.in"
4975 (("SVNREV=") "#SVNREV="))
4977 (add-before 'configure 'fix-/bin/sh
4979 (substitute* "configure"
4980 (("-/bin/sh") (string-append "-" (which "sh"))))
4982 (add-before 'configure 'fix-smt-z3wrapper.ml
4984 (substitute* "Makefile.in"
4987 (add-before 'configure 'fix-ocaml-num
4988 (lambda* (#:key inputs #:allow-other-keys)
4989 (substitute* "Makefile.in"
4990 (("nums.cma") "num.cma num_core.cma")
4991 (("= \\$\\(FUNCTORYLIB\\)")
4992 (string-append "= -I "
4993 (assoc-ref inputs "ocaml-num")
4994 "/lib/ocaml/site-lib/num/core -I "
4995 (assoc-ref inputs "ocaml-num")
4996 "/lib/ocaml/site-lib/num"
4997 " $(FUNCTORYLIB)")))
4999 (home-page "http://cubicle.lri.fr/")
5000 (synopsis "Model checker for array-based systems")
5001 (description "Cubicle is a model checker for verifying safety properties
5002 of array-based systems. This is a syntactically restricted class of
5003 parametrized transition systems with states represented as arrays indexed by
5004 an arbitrary number of processes. Cache coherence protocols and mutual
5005 exclusion algorithms are typical examples of such systems.")
5006 (license license:asl2.0)))
5008 (define-public ocaml-sexplib0
5010 (name "ocaml-sexplib0")
5012 (home-page "https://github.com/janestreet/sexplib0")
5017 (commit (string-append "v" version))))
5018 (file-name (git-file-name name version))
5021 "05m93g4m4jhj1v8pazg3s2ydcfymr3h4476yjhdca5fm4sn35bg8"))))
5022 (build-system dune-build-system)
5023 (arguments `(#:tests? #f)) ;no tests
5024 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-sexplib0))))
5025 (synopsis "Library containing the definition of S-expressions and some
5027 (description "Part of Jane Street's Core library The Core suite of
5028 libraries is an industrial strength alternative to OCaml's standard library
5029 that was developed by Jane Street, the largest industrial user of OCaml.")
5030 (license license:expat)))
5032 (define-public ocaml4.07-sexplib0
5033 (package-with-ocaml4.07
5035 (inherit ocaml-sexplib0)
5036 (name "ocaml-sexplib0")
5039 (janestreet-origin "sexplib0" version
5040 "1p06p2s7p9xsjn0z9qicniv1ai54d8sj11k8j633di2mm7jzxpin"))
5041 (arguments `(#:tests? #f)) ; no tests
5044 (define-public ocaml-parsexp
5046 (name "ocaml-parsexp")
5048 (home-page "https://github.com/janestreet/parsexp")
5053 (commit (string-append "v" version))))
5054 (file-name (git-file-name name version))
5057 "1grzpxi39318vcqhwf723hqh11k68irh59zb3dyg9lw8wjn7752a"))))
5058 (build-system dune-build-system)
5060 (list ocaml-sexplib0 ocaml-base))
5061 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-parsexp))))
5062 (synopsis "S-expression parsing library")
5064 "This library provides generic parsers for parsing S-expressions from
5065 strings or other medium.
5067 The library is focused on performances but still provide full generic
5068 parsers that can be used with strings, bigstrings, lexing buffers,
5069 character streams or any other sources effortlessly.
5071 It provides three different class of parsers:
5074 the normal parsers, producing [Sexp.t] or [Sexp.t list] values
5076 the parsers with positions, building compact position sequences so
5077 that one can recover original positions in order to report properly
5078 located errors at little cost
5080 the Concrete Syntax Tree parsers, produce values of type
5081 @code{Parsexp.Cst.t} which record the concrete layout of the s-expression
5082 syntax, including comments
5085 This library is portable and doesn't provide IO functions. To read
5086 s-expressions from files or other external sources, you should use
5088 (license license:expat)))
5090 (define-public ocaml4.07-parsexp
5091 (package-with-ocaml4.07
5093 (inherit ocaml-parsexp)
5094 (name "ocaml-parsexp")
5097 (janestreet-origin "parsexp" version
5098 "11a30zkfgbi6pb4whq22k1zc8ghdp9bwxl5s5cdlmx1z8s4yxsf0"))
5101 (define-public ocaml-sexplib
5103 (name "ocaml-sexplib")
5105 (home-page "https://github.com/janestreet/sexplib")
5107 (janestreet-origin "sexplib" version
5108 "1xs55f11yhscnfrzpvy1vn05j6xi9kxy097465624l615j7k8qm5"))
5109 (build-system dune-build-system)
5111 (list ocaml-base ocaml-num ocaml-parsexp ocaml-sexplib0))
5112 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-sexplib))))
5114 "Library for serializing OCaml values to and from S-expressions")
5116 "This package is part of Jane Street's Core library. Sexplib contains
5117 functionality for parsing and pretty-printing s-expressions.")
5118 (license license:expat)))
5120 (define-public ocaml4.07-sexplib
5121 (package-with-ocaml4.07
5123 (inherit ocaml-sexplib)
5126 (janestreet-origin "sexplib" version
5127 "0ksx62zsxhz8xmdrsn41n2hbc2qbyh3bxxc6946xisvgwh42h3q3"))
5130 (define-public ocaml-base
5134 (home-page "https://github.com/janestreet/base")
5139 (url "https://github.com/janestreet/base")
5140 (commit (string-append "v" version))))
5141 (file-name (git-file-name name version))
5144 "1qyycqqr4dijvxm4hhy79c964wd91kpsfvb89kna1qwgllg0hrpj"))))
5145 (build-system dune-build-system)
5147 (list ocaml-sexplib0))
5148 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-base))))
5150 "Full standard library replacement for OCaml")
5152 "Base is a complete and portable alternative to the OCaml standard
5153 library. It provides all standard functionalities one would expect
5154 from a language standard library. It uses consistent conventions
5155 across all of its module.
5157 Base aims to be usable in any context. As a result system dependent
5158 features such as I/O are not offered by Base. They are instead
5159 provided by companion libraries such as
5160 @url{https://github.com/janestreet/stdio, ocaml-stdio}.")
5161 (license license:expat)))
5163 (define-public ocaml4.07-base
5164 (package-with-ocaml4.07
5166 (inherit ocaml-base)
5171 ;; version 0.11.1 is not released on ocaml.janestreet.org.
5174 (url "https://github.com/janestreet/base.git")
5175 (commit (string-append "v" version))))
5176 (file-name (git-file-name name version))
5179 "0j6xb4265jr41vw4fjzak6yr8s30qrnzapnc6rl1dxy8bjai0nir"))))
5182 (define-public ocaml-compiler-libs
5184 (name "ocaml-compiler-libs")
5186 (home-page "https://github.com/janestreet/ocaml-compiler-libs")
5192 (commit (string-append "v" version))))
5193 (file-name (git-file-name name version))
5196 "00if2f7j9d8igdkj4rck3p74y17j6b233l91mq02drzrxj199qjv"))))
5197 (build-system dune-build-system)
5198 (arguments `(#:tests? #f)) ;no tests
5199 (properties `((upstream-name . "ocaml-compiler-libs")
5200 (ocaml4.07-variant . ,(delay ocaml4.07-compiler-libs))))
5201 (synopsis "Compiler libraries repackaged")
5202 (description "This package simply repackages the OCaml compiler libraries
5203 so they don't expose everything at toplevel. For instance, @code{Ast_helper}
5204 is now @code{Ocaml_common.Ast_helper}.")
5205 (license license:expat)))
5207 (define-public ocaml4.07-compiler-libs
5208 (package-with-ocaml4.07
5210 (inherit ocaml-compiler-libs)
5211 (name "ocaml-compiler-libs")
5213 (home-page "https://github.com/janestreet/ocaml-compiler-libs")
5219 (commit (string-append "v" version))))
5220 (file-name (git-file-name name version))
5223 "03jds7bszh8wwpfwxb3dg0gyr1j1872wxwx1xqhry5ir0i84bg0s"))))
5224 (properties `((upstream-name . "ocaml-compiler-libs"))))))
5226 (define-public ocaml-stdio
5228 (name "ocaml-stdio")
5230 (home-page "https://github.com/janestreet/stdio")
5232 (janestreet-origin "stdio" version
5233 "0jsyg4jlp76d9gx1fngms6nfs7dcpsysdsvkywjq9a663n994wn3"))
5234 (build-system dune-build-system)
5236 (list ocaml-base ocaml-sexplib0))
5237 (arguments `(#:tests? #f)) ;no tests
5238 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-stdio))))
5239 (synopsis "Standard IO library for OCaml")
5241 "Stdio implements simple input/output functionalities for OCaml. It
5242 re-exports the input/output functions of the OCaml standard libraries using
5243 a more consistent API.")
5244 (license license:expat)))
5246 (define-public ocaml4.07-stdio
5247 (package-with-ocaml4.07
5249 (inherit ocaml-stdio)
5252 (janestreet-origin "stdio" version
5253 "0pqbp2wy5fgmc38irwvmj9nlcvclb1ix1mp4y7l39bgvvlz303h9"))
5256 (define-public ocaml-ppx-deriving
5258 (name "ocaml-ppx-deriving")
5264 (url "https://github.com/ocaml-ppx/ppx_deriving")
5265 (commit (string-append "v" version))))
5266 (file-name (git-file-name name version))
5269 "1wqcnw4wi6pfjjhixpakckm03dpj990259za432804471a6spm2j"))))
5270 (build-system dune-build-system)
5272 `(#:test-target "."))
5274 (list ocaml-ppx-derivers ocaml-ppxlib ocaml-result))
5276 (list ocaml-cppo ocaml-ounit2))
5277 (properties `((upstream-name . "ppx_deriving")))
5278 (home-page "https://github.com/ocaml-ppx/ppx_deriving")
5279 (synopsis "Type-driven code generation for OCaml")
5281 "Ppx_deriving provides common infrastructure for generating code based
5282 on type definitions, and a set of useful plugins for common tasks.")
5283 (license license:expat)))
5285 (define-public ocaml-ppx-derivers
5287 (name "ocaml-ppx-derivers")
5290 "https://github.com/ocaml-ppx/ppx_derivers")
5295 (url (string-append home-page ".git"))
5297 (file-name (git-file-name name version))
5300 "0yqvqw58hbx1a61wcpbnl9j30n495k23qmyy2xwczqs63mn2nkpn"))))
5301 (build-system dune-build-system)
5303 '(#:tests? #f)) ;no tests
5304 (properties `((upstream-name . "ppx_derivers")))
5305 (synopsis "Shared @code{@@deriving} plugin registry")
5307 "Ppx_derivers is a tiny package whose sole purpose is to allow
5308 ppx_deriving and ppx_type_conv to inter-operate gracefully when linked
5309 as part of the same ocaml-migrate-parsetree driver.")
5310 (license license:bsd-3)))
5312 (define-public ocaml-ppxlib
5314 (name "ocaml-ppxlib")
5316 (home-page "https://github.com/ocaml-ppx/ppxlib")
5323 (file-name (git-file-name name version))
5326 "0wlqvyqy9ccp7z981blv42aqwq7zfq93cakbahjyy48hiiir6vp2"))))
5327 (build-system dune-build-system)
5330 (modify-phases %standard-phases
5331 (add-after 'unpack 'fix-test-format
5333 ;; Since sexplib >= 0.15, error formating has changed
5334 (substitute* "test/driver/exception_handling/run.t"
5335 (("\\(Failure ") "Failure("))
5336 (substitute* "test/base/test.ml"
5337 (("Invalid_argument \\((.*)\\)." _ m)
5338 (string-append "Invalid_argument " m "."))
5339 (("\\(Invalid_argument (.*)\\)" _ m)
5340 (string-append "Invalid_argument " m ".")))
5341 (substitute* "test/ppx_import_support/test.ml"
5342 (("\\(Failure") "Failure")
5343 ((" \"(Some ppx-es.*)\")" _ m)
5344 (string-append " \"" m "\"."))))))))
5348 ocaml-migrate-parsetree
5354 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-ppxlib))))
5356 "Base library and tools for ppx rewriters")
5358 "A comprehensive toolbox for ppx development. It features:
5360 @item an OCaml AST / parser / pretty-printer snapshot, to create a full frontend
5361 independent of the version of OCaml;
5362 @item a library for library for ppx rewriters in general, and type-driven code
5363 generators in particular;
5365 a feature-full driver for OCaml AST transformers;
5366 @item a quotation mechanism allowing to write values representing the
5367 OCaml AST in the OCaml syntax;
5368 @item a generator of open recursion classes from type definitions.
5370 (license license:expat)))
5372 (define-public ocaml4.07-ppxlib
5373 (package-with-ocaml4.07
5375 (inherit ocaml-ppxlib)
5376 (name "ocaml-ppxlib")
5378 (home-page "https://github.com/ocaml-ppx/ppxlib")
5385 (file-name (git-file-name name version))
5388 "0my9x7sxb329h0lzshppdaawiyfbaw6g5f41yiy7bhl071rnlvbv"))))
5389 (build-system dune-build-system)
5392 (modify-phases %standard-phases
5393 (add-before 'check 'set-topfind
5394 (lambda* (#:key inputs #:allow-other-keys)
5395 ;; add the line #directory ".." at the top of each file
5396 ;; using #use "topfind";; to be able to find topfind
5397 (let* ((findlib-path (assoc-ref inputs "findlib"))
5399 (string-append findlib-path "/lib/ocaml/site-lib")))
5400 (substitute* '("test/base/test.ml"
5401 "test/code_path/test.ml"
5402 "test/deriving/test.ml"
5403 "test/driver/attributes/test.ml"
5404 "test/driver/non-compressible-suffix/test.ml"
5405 "test/driver/transformations/test.ml")
5406 (("#use \"topfind\";;" all)
5407 (string-append "#directory \"" findlib-libdir "\"\n"
5412 (define-public ocaml-ppx-compare
5414 (name "ocaml-ppx-compare")
5417 (janestreet-origin "ppx_compare" version
5418 "11bkw7fgzfay8ws0piwphqip3y2lk2c9s2gil3zisnbvka92h1va"))
5419 (build-system dune-build-system)
5421 ;; Tests are currenlty failing
5422 ;; (see https://github.com/janestreet/ppx_compare/issues/10)
5425 (list ocaml-base ocaml-migrate-parsetree ocaml-ppxlib))
5426 (properties `((upstream-name . "ppx_compare")
5427 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-compare))))
5428 (home-page "https://github.com/janestreet/ppx_compare")
5429 (synopsis "Generation of comparison functions from types")
5430 (description "Generation of fast comparison functions from type expressions
5431 and definitions. Ppx_compare is a ppx rewriter that derives comparison functions
5432 from type representations. The scaffolded functions are usually much faster
5433 than ocaml's Pervasives.compare. Scaffolding functions also gives you more
5434 flexibility by allowing you to override them for a specific type and more safety
5435 by making sure that you only compare comparable values.")
5436 (license license:asl2.0)))
5438 (define-public ocaml4.07-ppx-compare
5439 (package-with-ocaml4.07
5441 (inherit ocaml-ppx-compare)
5442 (name "ocaml-ppx-compare")
5444 (home-page "https://github.com/janestreet/ppx_compare")
5449 (commit (string-append "v" version))))
5450 (file-name (git-file-name name version))
5453 "06bq4m1bsm4jlx4g7wh5m99qky7xm4c2g52kaz6pv25hdn5agi2m"))))
5454 (properties `((upstream-name . "ppx_compare"))))))
5456 (define-public ocaml-fieldslib
5458 (name "ocaml-fieldslib")
5460 (source (janestreet-origin
5462 "083izf854vzmi5zj63r7ipjf09y1dqf7iy8n6r4663444xrzs2h5"))
5463 (build-system dune-build-system)
5464 (arguments `(#:tests? #f)) ; No tests
5466 (list ocaml-base ocaml-migrate-parsetree ocaml-ppxlib))
5467 (properties `((upstream-name . "fieldslib")
5468 (ocaml4.07-variant . ,(delay ocaml4.07-fieldslib))))
5469 (home-page "https://github.com/janestreet/fieldslib")
5470 (synopsis "Syntax extension to record fields")
5471 (description "Syntax extension to define first class values representing
5472 record fields, to get and set record fields, iterate and fold over all fields
5473 of a record and create new record values.")
5474 (license license:asl2.0)))
5476 (define-public ocaml4.07-fieldslib
5477 (package-with-ocaml4.07
5479 (inherit ocaml-fieldslib)
5481 (source (janestreet-origin
5483 "12948pzxrl360lybm9fzyvplgcl87zjbn4m3sk1aw75zk85p1388"))
5484 (properties `((upstream-name . "fieldslib"))))))
5486 (define-public ocaml-variantslib
5488 (name "ocaml-variantslib")
5491 (janestreet-origin "variantslib" version
5492 "12dssx4by6rgjzfrvksz83hkcpmsq0brn87dh22pv1rrwhw79n75"))
5493 (build-system dune-build-system)
5498 (list ocaml-base ocaml-migrate-parsetree ocaml-ppxlib))
5499 (properties `((upstream-name . "variantslib")
5500 (ocaml4.07-variant . ,(delay ocaml4.07-variantslib))))
5501 (home-page "https://github.com/janestreet/variantslib")
5502 (synopsis "OCaml variants as first class values")
5503 (description "The Core suite of libraries is an alternative to OCaml's
5505 (license license:asl2.0)))
5507 (define-public ocaml4.07-variantslib
5508 (package-with-ocaml4.07
5510 (inherit ocaml-variantslib)
5511 (name "ocaml-variantslib")
5515 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5516 (version-major+minor version)
5517 "/files/variantslib-v" version ".tar.gz"))
5520 "1hsdwmkslvk4cznqr4lyyiy7vvk5spil226k0z2in26fxq6y0hf3"))))
5521 (properties `((upstream-name . "variantslib"))))))
5523 (define-public ocaml-ppx-fields-conv
5525 (name "ocaml-ppx-fields-conv")
5527 (home-page "https://github.com/janestreet/ppx_fields_conv")
5533 (commit (string-append "v" version))))
5534 (file-name (git-file-name name version))
5537 "094wsnw7fcwgl9xg6vkjb0wbgpn9scsp847yhdd184sz9v1amz14"))))
5538 (build-system dune-build-system)
5540 (list ocaml-base ocaml-fieldslib ocaml-migrate-parsetree
5542 (properties `((upstream-name . "ppx_fields_conv")
5543 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-fields-conv))))
5544 (synopsis "Generation of accessor and iteration functions for ocaml records")
5545 (description "Ppx_fields_conv is a ppx rewriter that can be used to define
5546 first class values representing record fields, and additional routines, to get
5547 and set record fields, iterate and fold over all fields of a record and create
5548 new record values.")
5549 (license license:asl2.0)))
5551 (define-public ocaml4.07-ppx-fields-conv
5552 (package-with-ocaml4.07
5554 (inherit ocaml-ppx-fields-conv)
5556 (source (janestreet-origin
5557 "ppx_fields_conv" version
5558 "07zrd3qky2ppbfl55gpm90rvqa5860xgwcsvihrjmkrw6d0jirkc"))
5559 (properties `((upstream-name . "ppx_fields_conv"))))))
5561 (define-public ocaml-ppx-sexp-conv
5563 (name "ocaml-ppx-sexp-conv")
5565 (home-page "https://github.com/janestreet/ppx_sexp_conv")
5571 (commit (string-append "v" version))))
5572 (file-name (git-file-name name version))
5575 "1fyf7hgxprn7pj58rmmrfpv938a0avpzvvk6wzihpmfm6whgbdm8"))))
5576 (build-system dune-build-system)
5578 (list ocaml-base ocaml-ppxlib))
5579 (properties `((upstream-name . "ppx_sexp_conv")
5580 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-sexp-conv))))
5581 (synopsis "Generation of S-expression conversion functions from type definitions")
5582 (description "This package generates S-expression conversion functions from type
5584 (license license:asl2.0)))
5586 (define-public ocaml4.07-ppx-sexp-conv
5587 (package-with-ocaml4.07
5589 (inherit ocaml-ppx-sexp-conv)
5590 (name "ocaml-ppx-sexp-conv")
5595 (url "https://github.com/janestreet/ppx_sexp_conv")
5596 (commit (string-append "v" version))))
5597 (file-name (git-file-name name version))
5600 "0pqwnqy1xp309wvdcaax4lg02yk64lq2w03mbgfvf6ps5ry4gis9"))))
5601 (properties `((upstream-name . "ppx_sexp_conv"))))))
5603 (define-public ocaml-ppx-variants-conv
5605 (name "ocaml-ppx-variants-conv")
5611 (url "https://github.com/janestreet/ppx_variants_conv")
5612 (commit (string-append "v" version))))
5613 (file-name (git-file-name name version))
5616 "1dh0bw9dn246k00pymf59yjkl6x6bxd76lkk9b5xpq2692wwlc3s"))))
5617 (build-system dune-build-system)
5619 (list ocaml-base ocaml-variantslib ocaml-migrate-parsetree
5622 `((upstream-name . "ppx_variants_conv")
5623 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-variants-conv))))
5625 "https://github.com/janestreet/ppx_variants_conv")
5626 (synopsis "Generation of accessor and iteration functions for OCaml variant types")
5628 "This package generates accessors and iteration functions for OCaml
5630 (license license:asl2.0)))
5632 (define-public ocaml4.07-ppx-variants-conv
5633 (package-with-ocaml4.07
5635 (inherit ocaml-ppx-variants-conv)
5636 (name "ocaml-ppx-variants-conv")
5642 (url "https://github.com/janestreet/ppx_variants_conv")
5643 (commit (string-append "v" version))))
5644 (file-name (git-file-name name version))
5647 "1yc0gsds5m2nv39zga8nnrca2n75rkqy5dz4xj1635ybz20hhbjd"))))
5648 (properties `((upstream-name . "ppx_variants_conv"))))))
5650 (define-public ocaml-ppx-custom-printf
5652 (name "ocaml-ppx-custom-printf")
5654 (home-page "https://github.com/janestreet/ppx_custom_printf")
5660 (commit (string-append "v" version))))
5661 (file-name (git-file-name name version))
5664 "1k8nmq6kwqz2wpkm9ymq749dz1vd8lxrjc711knp1wyz5935hnsv"))))
5665 (build-system dune-build-system)
5667 (list ocaml-base ocaml-ppx-sexp-conv ocaml-migrate-parsetree
5669 (properties `((upstream-name . "ppx_custom_printf")
5670 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-custom-printf))))
5671 (synopsis "Printf-style format-strings for user-defined string conversion")
5672 (description "Extensions to printf-style format-strings for user-defined
5673 string conversion.")
5674 (license license:asl2.0)))
5676 (define-public ocaml4.07-ppx-custom-printf
5677 (package-with-ocaml4.07
5679 (inherit ocaml-ppx-custom-printf)
5683 "ppx_custom_printf" version
5684 "11b73smf3g3bpd9lg014pr4rx285nk9mnk6g6464ph51jv0sqzhj"))
5685 (properties `((upstream-name . "ppx_custom_printf"))))))
5687 (define-public ocaml-bin-prot
5689 (name "ocaml-bin-prot")
5695 (url "https://github.com/janestreet/bin_prot")
5696 (commit (string-append "v" version))))
5697 (file-name (git-file-name name version))
5699 (base32 "1qfqglscc25wwnjx7byqmjcnjww1msnr8940gyg8h93wdq43fjnh"))))
5700 (build-system dune-build-system)
5704 ocaml-ppx-custom-printf
5705 ocaml-ppx-fields-conv
5708 ocaml-ppx-variants-conv))
5709 (properties `((upstream-name . "bin_prot")
5710 (ocaml4.07-variant . ,(delay ocaml4.07-bin-prot))))
5711 (home-page "https://github.com/janestreet/bin_prot")
5712 (synopsis "Binary protocol generator")
5713 (description "This library contains functionality for reading and writing
5714 OCaml-values in a type-safe binary protocol. It is extremely efficient,
5715 typically supporting type-safe marshalling and unmarshalling of even highly
5716 structured values at speeds sufficient to saturate a gigabit connection. The
5717 protocol is also heavily optimized for size, making it ideal for long-term
5718 storage of large amounts of data.")
5719 (license license:expat)))
5721 (define-public ocaml4.07-bin-prot
5722 (package-with-ocaml4.07
5724 (inherit ocaml-bin-prot)
5728 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5729 (version-major+minor version)
5730 "/files/bin_prot-v" version ".tar.gz"))
5733 "1rsd91gx36prj4whi76nsiz1bzpgal9nzyw3pxdz1alv4ilk2il6"))))
5734 (propagated-inputs (list ocaml-base
5736 ocaml-ppx-custom-printf
5737 ocaml-ppx-fields-conv
5738 ocaml-ppx-variants-conv
5739 ocaml-migrate-parsetree))
5745 (define-public ocaml-octavius
5747 (name "ocaml-octavius")
5752 (url "https://github.com/ocaml-doc/octavius")
5753 (commit (string-append "v" version))))
5754 (file-name (git-file-name name version))
5757 "1c5m51xcn2jv42kjjpklr6g63sgx1k885wfdp1yr4wrmiaj9cbpx"))))
5758 (build-system dune-build-system)
5761 (modify-phases %standard-phases
5762 (add-before 'build 'make-writable
5764 (for-each (lambda (file)
5766 (find-files "." "."))
5768 (properties `((upstream-name . "octavius")))
5769 (home-page "https://github.com/ocaml-doc/octavius")
5770 (synopsis "Ocamldoc comment syntax parser")
5771 (description "Octavius is a library to parse the `ocamldoc` comment syntax.")
5772 (license license:isc)))
5774 (define-public ocaml-ppx-hash
5776 (name "ocaml-ppx-hash")
5779 (janestreet-origin "ppx_hash" version
5780 "048pim0xicj8j9whd5lnchf62788sk3w89h12aybbalk1xm6dfs5"))
5781 (build-system dune-build-system)
5783 (list ocaml-base ocaml-ppx-compare ocaml-ppx-sexp-conv
5784 ocaml-migrate-parsetree ocaml-ppxlib))
5785 (properties `((upstream-name . "ppx_hash")
5786 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-hash))))
5787 (home-page "https://github.com/janestreet/ppx_hash")
5788 (synopsis "Generation of hash functions from type expressions and definitions")
5789 (description "This package is a collection of ppx rewriters that generate
5790 hash functions from type exrpessions and definitions.")
5791 (license license:asl2.0)))
5793 (define-public ocaml4.07-ppx-hash
5794 (package-with-ocaml4.07
5796 (inherit ocaml-ppx-hash)
5797 (name "ocaml-ppx-hash")
5798 (home-page "https://github.com/janestreet/ppx_hash")
5804 (commit (string-append "v" version))))
5805 (file-name (git-file-name name version))
5808 "1p0ic6aijxlrdggpmycj12q3cy9xksbq2vq727215maz4snvlf5p"))))
5809 (properties `((upstream-name . "ppx_hash"))))))
5811 (define-public ocaml-ppx-enumerate
5813 (name "ocaml-ppx-enumerate")
5817 "ppx_enumerate" version
5818 "16yhk3xk2hskmlspb6mikmdp60qaypyiqgq9p17kxpial6fgpdfy"))
5819 (build-system dune-build-system)
5821 `(#:tests? #f)) ; no test suite
5823 (list ocaml-base ocaml-migrate-parsetree ocaml-ppxlib))
5824 (properties `((upstream-name . "ppx_enumerate")
5825 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-enumerate))))
5826 (home-page "https://github.com/janestreet/ppx_enumerate")
5827 (synopsis "Generate a list containing all values of a finite type")
5828 (description "Ppx_enumerate is a ppx rewriter which generates a definition
5829 for the list of all values of a type (for a type which only has finitely
5831 (license license:asl2.0)))
5833 (define-public ocaml4.07-ppx-enumerate
5834 (package-with-ocaml4.07
5836 (inherit ocaml-ppx-enumerate)
5837 (name "ocaml-ppx-enumerate")
5839 (home-page "https://github.com/janestreet/ppx_enumerate")
5844 (commit (string-append "v" version))))
5845 (file-name (git-file-name name version))
5848 "0spx9k1v7vjjb6sigbfs69yndgq76v114jhxvzjmffw7q989cyhr"))))
5849 (properties `((upstream-name . "ppx_enumerate"))))))
5851 (define-public ocaml-ppx-bench
5853 (name "ocaml-ppx-bench")
5859 (url "https://github.com/janestreet/ppx_bench")
5860 (commit (string-append "v" version))))
5861 (file-name (git-file-name name version))
5863 (base32 "0bc0gbm922417wqisafxh35jslcp7xy1s0h0a1q32rhx0ivxx3g6"))))
5864 (build-system dune-build-system)
5868 (propagated-inputs (list ocaml-ppx-inline-test ocaml-ppxlib))
5869 (properties `((upstream-name . "ppx_bench")
5870 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-bench))))
5871 (home-page "https://github.com/janestreet/ppx_bench")
5872 (synopsis "Syntax extension for writing in-line benchmarks in ocaml code")
5873 (description "Syntax extension for writing in-line benchmarks in ocaml code.")
5874 (license license:expat)))
5876 (define-public ocaml4.07-ppx-bench
5877 (package-with-ocaml4.07
5879 (inherit ocaml-ppx-bench)
5883 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5884 (version-major+minor version)
5885 "/files/ppx_bench-v" version ".tar.gz"))
5888 "0ys4pblbcjbk9dn073rqiwm7r6rc7fah03j7riklkwnb5n44andl"))))
5890 (list ocaml-ppx-inline-test ocaml-migrate-parsetree ocaml-ppxlib))
5892 (license license:asl2.0))))
5894 (define-public ocaml-ppx-here
5896 (name "ocaml-ppx-here")
5899 (janestreet-origin "ppx_here" version
5900 "1pyaw31j9n6r98ar947n3j2qj6rrszbdxr8jghk96j4ajdy05g65"))
5901 (build-system dune-build-system)
5906 (list ocaml-base ocaml-migrate-parsetree ocaml-ppxlib))
5907 (properties `((upstream-name . "ppx_here")
5908 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-here))))
5909 (home-page "https://github.com/janestreet/ppx_here")
5910 (synopsis "Expands [%here] into its location")
5912 "Part of the Jane Street's PPX rewriters collection.")
5913 (license license:asl2.0)))
5915 (define-public ocaml4.07-ppx-here
5916 (package-with-ocaml4.07
5918 (inherit ocaml-ppx-here)
5921 (janestreet-origin "ppx_here" version
5922 "0wxcak3ay4jpigm3pfdcpr65qw4hxfa8whhkryhcd8gy71x056z5"))
5923 (properties `((upstream-name . "ppx_here"))))))
5925 (define-public ocaml-typerep
5927 (name "ocaml-typerep")
5933 (url "https://github.com/janestreet/typerep")
5934 (commit (string-append "v" version))))
5935 (file-name (git-file-name name version))
5937 (base32 "1qxfi01qim0hrgd6d0bgvpxg36i99mmm8cw4wqpr9kxyqvgzv26z"))))
5938 (build-system dune-build-system)
5939 (arguments `(#:tests? #f)); no tests
5940 (propagated-inputs (list ocaml-base))
5941 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-typerep))))
5942 (home-page "https://github.com/janestreet/typerep")
5943 (synopsis "Typerep is a library for runtime types")
5944 (description "Typerep is a library for runtime types.")
5945 (license license:expat)))
5947 (define-public ocaml4.07-typerep
5948 (package-with-ocaml4.07
5950 (inherit ocaml-typerep)
5954 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5955 (version-major+minor version)
5956 "/files/typerep-v" version ".tar.gz"))
5959 "1zi7hy0prpgzqhr4lkacr04wvlvbp21jfbdfvffhrm6cd400rb5v"))))
5961 (license license:asl2.0))))
5963 (define-public ocaml-ppx-sexp-value
5965 (name "ocaml-ppx-sexp-value")
5971 (url "https://github.com/janestreet/ppx_sexp_value")
5972 (commit (string-append "v" version))))
5973 (file-name (git-file-name name version))
5975 (base32 "0kz83j9v6yz3v8c6vr9ilhkcci4hhjd6i6r6afnx72jh6i7d3hnv"))))
5976 (build-system dune-build-system)
5978 (list ocaml-base ocaml-ppx-here ocaml-ppx-sexp-conv ocaml-ppxlib))
5979 (properties `((upstream-name . "ppx_sexp_value")
5980 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-sexp-value))))
5981 (home-page "https://github.com/janestreet/ppx_sexp_value")
5982 (synopsis "Simplify building s-expressions from ocaml values")
5983 (description "@samp{ppx-sexp-value} is a ppx rewriter that simplifies
5984 building s-expressions from ocaml values.")
5985 (license license:expat)))
5987 (define-public ocaml4.07-ppx-sexp-value
5988 (package-with-ocaml4.07
5990 (inherit ocaml-ppx-sexp-value)
5994 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
5995 (version-major+minor version)
5996 "/files/ppx_sexp_value-v" version ".tar.gz"))
5999 "1xnalfrln6k5khsyxvxkg6v32q8fpr4cqamsjqfih29jdv486xrs"))))
6004 ocaml-migrate-parsetree
6007 (license license:asl2.0))))
6009 (define-public ocaml-ppx-sexp-message
6011 (name "ocaml-ppx-sexp-message")
6017 (url "https://github.com/janestreet/ppx_sexp_message")
6018 (commit (string-append "v" version))))
6019 (file-name (git-file-name name version))
6021 (base32 "0a7hx50bkkc5n5msc3zzc4ixnp7674x3mallknb9j31jnd8l90nj"))))
6022 (build-system dune-build-system)
6024 (list ocaml-base ocaml-ppx-here ocaml-ppx-sexp-conv ocaml-ppxlib))
6025 (properties `((upstream-name . "ppx_sexp_message")
6026 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-sexp-message))))
6027 (home-page "https://github.com/janestreet/ppx_sexp_message")
6028 (synopsis "Ppx rewriter for easy construction of s-expressions")
6029 (description "Ppx_sexp_message aims to ease the creation of s-expressions
6030 in OCaml. This is mainly motivated by writing error and debugging messages,
6031 where one needs to construct a s-expression based on various element of the
6032 context such as function arguments.")
6033 (license license:expat)))
6035 (define-public ocaml4.07-ppx-sexp-message
6036 (package-with-ocaml4.07
6038 (inherit ocaml-ppx-sexp-message)
6042 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
6043 (version-major+minor version)
6044 "/files/ppx_sexp_message-v" version ".tar.gz"))
6047 "1yh440za0w9cvrbxbmqacir8715kdaw6sw24ys9xj80av9nqpiw7"))))
6052 ocaml-migrate-parsetree
6055 (license license:asl2.0))))
6057 (define-public ocaml-ppx-pipebang
6059 (name "ocaml-ppx-pipebang")
6065 (url "https://github.com/janestreet/ppx_pipebang")
6066 (commit (string-append "v" version))))
6067 (file-name (git-file-name name version))
6069 (base32 "0sm5dghyalhws3hy1cc2ih36az1k4q02hcgj6l26gwyma3y4irvq"))))
6070 (build-system dune-build-system)
6071 (arguments `(#:tests? #f)); no tests
6072 (propagated-inputs (list ocaml-ppxlib))
6073 (properties `((upstream-name . "ppx_pipebang")
6074 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-pipebang))))
6075 (home-page "https://github.com/janestreet/ppx_pipebang")
6076 (synopsis "Inline reverse application operators `|>` and `|!`")
6077 (description "A ppx rewriter that inlines reverse application operators
6078 @code{|>} and @code{|!}.")
6079 (license license:expat)))
6081 (define-public ocaml4.07-ppx-pipebang
6082 (package-with-ocaml4.07
6084 (inherit ocaml-ppx-pipebang)
6088 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
6089 (version-major+minor version)
6090 "/files/ppx_pipebang-v" version ".tar.gz"))
6093 "1wrrzlb4kdvkkcmzi01fw25jar38r2jlnyn0i6pn4z0lq4gpm9m0"))))
6094 (propagated-inputs (list ocaml-migrate-parsetree ocaml-ppxlib))
6096 (license license:asl2.0))))
6098 (define-public ocaml-ppx-module-timer
6100 (name "ocaml-ppx-module-timer")
6106 (url "https://github.com/janestreet/ppx_module_timer")
6107 (commit (string-append "v" version))))
6108 (file-name (git-file-name name version))
6110 (base32 "0lzi5hxi10p89ddqbrc667267f888kqslal76gfhmszyk60n20av"))))
6111 (build-system dune-build-system)
6113 `(#:tests? #f)); no tests
6115 (list ocaml-base ocaml-ppx-base ocaml-stdio ocaml-time-now ocaml-ppxlib))
6116 (properties `((upstream-name . "ppx_module_timer")))
6117 (home-page "https://github.com/janestreet/ppx_module_timer")
6118 (synopsis "Ppx rewriter that records top-level module startup times")
6119 (description "Modules using @samp{ppx_module_timer} have instrumentation
6120 to record their startup time.")
6121 (license license:expat)))
6123 (define-public ocaml-ppx-fixed-literal
6125 (name "ocaml-ppx-fixed-literal")
6131 (url "https://github.com/janestreet/ppx_fixed_literal")
6132 (commit (string-append "v" version))))
6133 (file-name (git-file-name name version))
6135 (base32 "10siwcqrqa4gh0mg6fkaby0jjskc01r81pcblc67h3vmbjjh08j9"))))
6136 (build-system dune-build-system)
6138 `(#:tests? #f)); no tests
6139 (propagated-inputs (list ocaml-base ocaml-ppxlib))
6140 (properties `((upstream-name . "ppx_fixed_literal")))
6141 (home-page "https://github.com/janestreet/ppx_fixed_literal")
6142 (synopsis "Simpler notation for fixed point literals")
6144 "@samp{ppx-fixed-literal} is a ppx rewriter that rewrites fixed point
6145 literal of the form 1.0v to conversion functions currently in scope.")
6146 (license license:expat)))
6148 (define-public ocaml-ppx-optional
6150 (name "ocaml-ppx-optional")
6154 "ppx_optional" version
6155 "0af7ayhfc1jc01mxs4k253gq49yss2ymkmjsy6fpcz39zhci7fvj"))
6156 (build-system dune-build-system)
6157 (arguments `(#:tests? #f)) ; No tests
6159 (list ocaml-base ocaml-migrate-parsetree ocaml-ppxlib))
6160 (properties `((upstream-name . "ppx_optional")
6161 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-optional))))
6162 (home-page "https://github.com/janestreet/ppx_optional")
6163 (synopsis "Pattern matching on flat options")
6165 "A ppx rewriter that rewrites simple match statements with an if then
6167 (license license:asl2.0)))
6169 (define-public ocaml4.07-ppx-optional
6170 (package-with-ocaml4.07
6172 (inherit ocaml-ppx-optional)
6176 "ppx_optional" version
6177 "1z8z2bga95k2vksljljfglg10vygkjd24kn1b37sk4z3nmp47x0h"))
6178 (properties `((upstream-name . "ppx_optional"))))))
6180 (define-public ocaml-ppx-optcomp
6182 (name "ocaml-ppx-optcomp")
6184 (home-page "https://github.com/janestreet/ppx_optcomp")
6190 (commit (string-append "v" version))))
6191 (file-name (git-file-name name version))
6194 "0ypivfipi8fcr9pqyvl2ajpcivmr1irdwwv248i4x6mggpc2pl0b"))))
6195 (build-system dune-build-system)
6197 (list ocaml-base ocaml-stdio ocaml-ppxlib))
6198 (properties `((upstream-name . "ppx_optcomp")
6199 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-optcomp))))
6200 (synopsis "Optional compilation for OCaml")
6201 (description "Ppx_optcomp stands for Optional Compilation. It is a tool
6202 used to handle optional compilations of pieces of code depending of the word
6203 size, the version of the compiler, ...")
6204 (license license:asl2.0)))
6206 (define-public ocaml4.07-ppx-optcomp
6207 (package-with-ocaml4.07
6209 (inherit ocaml-ppx-optcomp)
6213 "ppx_optcomp" version
6214 "1bb52p2j2h4s9f06vrcpla80rj93jinnzq6jzilapyx9q068929i"))
6215 (properties `((upstream-name . "ppx_optcomp"))))))
6217 (define-public ocaml-ppx-let
6219 (name "ocaml-ppx-let")
6222 (janestreet-origin "ppx_let" version
6223 "0m9niyiiv3qzv5x8hw0ifxjjzshnmx40dchka9d93mmnx88jqx34"))
6224 (build-system dune-build-system)
6226 (list ocaml-base ocaml-migrate-parsetree ocaml-ppxlib ocaml-ppx-here))
6227 (properties `((upstream-name . "ppx_let")
6228 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-let))))
6229 (home-page "https://github.com/janestreet/ppx_let")
6230 (synopsis "Monadic let-bindings")
6231 (description "A ppx rewriter for monadic and applicative let bindings,
6232 match expressions, and if expressions.")
6233 (license license:asl2.0)))
6235 (define-public ocaml4.07-ppx-let
6236 (package-with-ocaml4.07
6238 (inherit ocaml-ppx-let)
6241 (janestreet-origin "ppx_let" version
6242 "1wdfw6w4xbg97a35yg6bif9gggxniy9ddnrjfw1a0inkl2yamxkj"))
6244 (properties `((upstream-name . "ppx_let"))))))
6246 (define-public ocaml-ppx-fail
6248 (name "ocaml-ppx-fail")
6254 (url "https://github.com/janestreet/ppx_fail")
6255 (commit (string-append "v" version))))
6256 (file-name (git-file-name name version))
6258 (base32 "012p9gv7w4sk3b4x0sdmqrmr2856w8xc424waxb6vrybid7qjs95"))))
6259 (build-system dune-build-system)
6260 (propagated-inputs (list ocaml-base ocaml-ppx-here ocaml-ppxlib))
6261 (properties `((upstream-name . "ppx_fail")
6262 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-fail))))
6263 (home-page "https://github.com/janestreet/ppx_fail")
6264 (synopsis "Add location to calls to failwiths")
6265 (description "Syntax extension that makes [failwiths] always include a
6267 (license license:expat)))
6269 (define-public ocaml4.07-ppx-fail
6270 (package-with-ocaml4.07
6272 (inherit ocaml-ppx-fail)
6276 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
6277 (version-major+minor version)
6278 "/files/ppx_fail-v" version ".tar.gz"))
6281 "07plqsvljiwvngggfypwq55g46s5my55y45mvlmalrxyppzr03s8"))))
6283 (list ocaml-base ocaml-ppx-here ocaml-migrate-parsetree ocaml-ppxlib))
6285 (license license:asl2.0))))
6287 (define-public ocaml-ppx-cold
6289 (name "ocaml-ppx-cold")
6291 (home-page "https://github.com/janestreet/ppx_cold")
6293 (janestreet-origin "ppx_cold" version
6294 "13gqmfw2sq80anag9bwpm35600l1fnfn7mh9cbj1291k84rsx7wb"))
6295 (build-system dune-build-system)
6296 (arguments `(#:test-target "tests"))
6298 (list ocaml-base ocaml-ppxlib))
6299 (properties `((upstream-name . "ppx_cold")))
6300 (synopsis "Syntax extension for indicating cold path")
6302 "This package contains an syntax extension to indicate that the code is
6303 on the cold path and should be kept out of the way to avoid polluting the
6304 instruction cache on the hot path. See also
6305 https://github.com/ocaml/ocaml/issues/8563.")
6306 (license license:expat)))
6308 (define-public ocaml-ppx-assert
6310 (name "ocaml-ppx-assert")
6313 (janestreet-origin "ppx_assert" version
6314 "0rsr1yz2rs12w6qw0dz09dg3k2x2pfgd014fgp6nj993hhznapsf"))
6315 (build-system dune-build-system)
6322 ocaml-migrate-parsetree
6324 (properties `((upstream-name . "ppx_assert")
6325 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-assert))))
6326 (home-page "https://github.com/janestreet/ppx_assert")
6327 (synopsis "Assert-like extension nodes that raise useful errors on failure")
6328 (description "This package contains assert-like extension nodes that raise
6329 useful errors on failure.")
6330 (license license:asl2.0)))
6332 (define-public ocaml4.07-ppx-assert
6333 (package-with-ocaml4.07
6335 (inherit ocaml-ppx-assert)
6338 (janestreet-origin "ppx_assert" version
6339 "17kd311n0l9f72gblf9kv8i5rghr106w37x4f0m5qwh6nlgl0j9k"))
6341 `(("ocaml-base" ,ocaml-base)
6342 ("ocaml-ppx-compare" ,ocaml-ppx-compare)
6343 ("ocaml-ppx-here" ,ocaml-ppx-here)
6344 ("ocaml-ppx-sexp-conv" ,ocaml-ppx-sexp-conv)
6345 ("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)
6346 ("ocaml-ppxlib" ,ocaml-ppxlib)))
6347 (properties `((upstream-name . "ppx_assert"))))))
6349 (define-public ocaml-ppx-expect
6351 (name "ocaml-ppx-expect")
6357 (url "https://github.com/janestreet/ppx_expect")
6358 (commit (string-append "v" version))))
6359 (file-name (git-file-name name version))
6362 "134dl5qhjxsj2mcmrx9f3m0iys0n5mjfpz9flj8zn8d2jir43776"))))
6363 (build-system dune-build-system)
6367 ocaml-ppx-inline-test
6370 ocaml-migrate-parsetree
6372 (properties `((upstream-name . "ppx_expect")
6373 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-expect))))
6374 (home-page "https://github.com/janestreet/ppx_expect")
6375 (synopsis "Cram like framework for OCaml")
6376 (description "Expect-test is a framework for writing tests in OCaml, similar
6377 to Cram. Expect-tests mimics the existing inline tests framework with the
6378 @code{let%expect_test} construct. The body of an expect-test can contain
6379 output-generating code, interleaved with @code{%expect} extension expressions
6380 to denote the expected output.")
6381 (license license:asl2.0)))
6383 (define-public ocaml4.07-ppx-expect
6384 (package-with-ocaml4.07
6386 (inherit ocaml-ppx-expect)
6389 (janestreet-origin "ppx_expect" version
6390 "1zpci8c49yn2ixchmwjx1kf9pwybv3dnn4l2dgnd6m36qnkralfk"))
6392 `(("ocaml-base" ,ocaml-base)
6393 ("ocaml-ppx-assert" ,ocaml-ppx-assert)
6394 ("ocaml-ppx-compare" ,ocaml-ppx-compare)
6395 ("ocaml-ppx-custom-printf" ,ocaml-ppx-custom-printf)
6396 ("ocaml-ppx-fields-conv" ,ocaml-ppx-fields-conv)
6397 ("ocaml-ppx-here" ,ocaml-ppx-here)
6398 ("ocaml-ppx-inline-test" ,ocaml-ppx-inline-test)
6399 ("ocaml-ppx-sexp-conv" ,ocaml-ppx-sexp-conv)
6400 ("ocaml-ppx-variants-conv" ,ocaml-ppx-variants-conv)
6401 ("ocaml-stdio" ,ocaml-stdio)
6402 ("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)
6403 ("ocaml-ppxlib" ,ocaml-ppxlib)
6404 ("ocaml-re" ,ocaml-re)))
6405 (properties `((upstream-name . "ppx_expect"))))))
6407 (define-public ocaml-ppx-js-style
6409 (name "ocaml-ppx-js-style")
6415 (url "https://github.com/janestreet/ppx_js_style")
6416 (commit (string-append "v" version))))
6417 (file-name (git-file-name name version))
6420 "0q2p9pvmlncgv0hprph95xiv7s6q44ynvp4yl4dckf1qx68rb3ba"))))
6421 (build-system dune-build-system)
6422 (arguments `(#:tests? #f)) ; No tests
6424 (list ocaml-base ocaml-migrate-parsetree ocaml-octavius ocaml-ppxlib))
6425 (properties `((upstream-name . "ppx_js_style")
6426 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-js-style))))
6427 (home-page "https://github.com/janestreet/ppx_js_style")
6428 (synopsis "Code style checker for Jane Street Packages")
6429 (description "This package is a no-op ppx rewriter. It is used as a
6430 @code{lint} tool to enforce some coding conventions across all Jane Street
6432 (license license:asl2.0)))
6434 (define-public ocaml4.07-ppx-js-style
6435 (package-with-ocaml4.07
6437 (inherit ocaml-ppx-js-style)
6440 (janestreet-origin "ppx_js_style" version
6441 "0z3fc55jdjhhsblla6z4fqc13kljpcz29q79rvs5h2vsraqrldr2"))
6442 (properties `((upstream-name . "ppx_js_style"))))))
6444 (define-public ocaml-ppx-typerep-conv
6446 (name "ocaml-ppx-typerep-conv")
6452 (url "https://github.com/janestreet/ppx_typerep_conv/")
6453 (commit (string-append "v" version))))
6454 (file-name (git-file-name name version))
6456 (base32 "1q1lzykpm83ra4l5jh4rfddhd3c96kx4s4rvx0w4b51z1qk56zam"))))
6457 (build-system dune-build-system)
6459 `(#:test-target "."))
6460 (propagated-inputs (list ocaml-base ocaml-typerep ocaml-ppxlib))
6461 (properties `((upstream-name . "ppx_typerep_conv")
6462 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-typerep-conv))))
6463 (home-page "https://github.com/janestreet/ppx_typerep_conv")
6464 (synopsis "Generation of runtime types from type declarations")
6465 (description "This package can automatically generate runtime types
6466 from type definitions.")
6467 (license license:expat)))
6469 (define-public ocaml4.07-ppx-typerep-conv
6470 (package-with-ocaml4.07
6472 (inherit ocaml-ppx-typerep-conv)
6477 (url "https://github.com/janestreet/ppx_typerep_conv")
6478 (commit (string-append "v" version))))
6479 (file-name (git-file-name "ocaml4.07-ppx-typerep-conv" version))
6482 "0a13dpfrrg0rsm8qni1bh7pqcda30l70z8r6yzi5a64bmwk7g5ah"))))
6485 (list ocaml-base ocaml-typerep ocaml-migrate-parsetree ocaml-ppxlib))
6486 (license license:asl2.0))))
6488 (define-public ocaml-ppx-string
6490 (name "ocaml-ppx-string")
6496 (url "https://github.com/janestreet/ppx_string")
6497 (commit (string-append "v" version))))
6498 (file-name (git-file-name name version))
6500 (base32 "1dp5frk6cig5m3m5rrh2alw63snyf845x7zlkkaljip02pqcbw1s"))))
6501 (build-system dune-build-system)
6502 (arguments `(#:tests? #f)); no tests
6504 (list ocaml-base ocaml-ppx-base ocaml-stdio ocaml-ppxlib))
6505 (properties `((upstream-name . "ppx_string")))
6506 (home-page "https://github.com/janestreet/ppx_string")
6507 (synopsis "Ppx extension for string interpolation")
6508 (description "This extension provides a syntax for string interpolation.")
6509 (license license:expat)))
6511 (define-public ocaml-ppx-stable
6513 (name "ocaml-ppx-stable")
6519 (url "https://github.com/janestreet/ppx_stable")
6520 (commit (string-append "v" version))))
6521 (file-name (git-file-name name version))
6523 (base32 "1as0v0x8c9ilyhngax55lvwyyi4a2wshyan668v0f2s1608cwb1l"))))
6524 (build-system dune-build-system)
6526 `(#:test-target "tests"))
6527 (propagated-inputs (list ocaml-base ocaml-ppxlib))
6528 (properties `((upstream-name . "ppx_stable")))
6529 (home-page "https://github.com/janestreet/ppx_stable")
6530 (synopsis "Stable types conversions generator")
6531 (description "This package is a ppx extension for easier implementation of
6532 conversion functions between almost identical types.")
6533 (license license:expat)))
6535 (define-public ocaml-ppx-base
6537 (name "ocaml-ppx-base")
6542 "181w7y2has8jsrqdsvd08q5nhnkx523vwsk3lg0cjix55qssvfyn"))
6543 (build-system dune-build-system)
6545 `(#:test-target "."))
6547 (list ocaml-ppx-compare
6553 ocaml-migrate-parsetree
6555 (properties `((upstream-name . "ppx_base")
6556 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-base))))
6557 (home-page "https://github.com/janestreet/ppx_base")
6558 (synopsis "Base set of ppx rewriters")
6559 (description "Ppx_base is the set of ppx rewriters used for Base.
6561 Note that Base doesn't need ppx to build, it is only used as a
6562 verification tool.")
6563 (license license:asl2.0)))
6565 (define-public ocaml4.07-ppx-base
6566 (package-with-ocaml4.07
6568 (inherit ocaml-ppx-base)
6573 "0aq206pg330jmj7lhcagiiwm3a0b3gsqm801m8ajd4ysyw7idkym"))
6575 `(("ocaml-ppx-compare" ,ocaml-ppx-compare)
6576 ("ocaml-ppx-enumerate" ,ocaml-ppx-enumerate)
6577 ("ocaml-ppx-hash" ,ocaml-ppx-hash)
6578 ("ocaml-ppx-js-style" ,ocaml-ppx-js-style)
6579 ("ocaml-ppx-sexp-conv" ,ocaml-ppx-sexp-conv)
6580 ("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)
6581 ("ocaml-ppxlib" ,ocaml-ppxlib)))
6582 (properties `((upstream-name . "ppx_base"))))))
6584 (define-public ocaml-ppx-bin-prot
6586 (name "ocaml-ppx-bin-prot")
6592 (url "https://github.com/janestreet/ppx_bin_prot")
6593 (commit (string-append "v" version))))
6594 (file-name (git-file-name name version))
6596 (base32 "1280wsls061fmvmdysjqn3lv4mnkyg400jnjf4jyfr14s33h1ad5"))))
6597 (build-system dune-build-system)
6599 ;; Cyclic dependency with ocaml-ppx-jane
6602 (list ocaml-base ocaml-bin-prot ocaml-ppx-here ocaml-ppxlib))
6603 (properties `((upstream-name . "ppx_bin_prot")
6604 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-bin-prot))))
6605 (home-page "https://github.com/janestreet/ppx_bin_prot")
6606 (synopsis "Generation of bin_prot readers and writers from types")
6607 (description "Generation of binary serialization and deserialization
6608 functions from type definitions.")
6609 (license license:expat)))
6611 (define-public ocaml4.07-ppx-bin-prot
6612 (package-with-ocaml4.07
6614 (inherit ocaml-ppx-bin-prot)
6619 (url "https://github.com/janestreet/ppx_bin_prot")
6620 (commit (string-append "v" version))))
6621 (file-name (git-file-name "ocaml4.07-ppx-bin-prot" version))
6624 "1h60i75bzvhna1axyn662gyrzhh441l79vl142d235i5x31dmnkz"))))
6629 ocaml-migrate-parsetree
6632 (license license:asl2.0))))
6634 (define-public ocaml-ppx-ignore-instrumentation
6636 (name "ocaml-ppx-ignore-instrumentation")
6642 (url "https://github.com/janestreet/ppx_ignore_instrumentation")
6643 (commit (string-append "v" version))))
6644 (file-name (git-file-name name version))
6646 (base32 "16fgig88g3jr0m3i636fr52h29h1yzhi8nhnl4029zn808kcdyj2"))))
6647 (build-system dune-build-system)
6649 `(#:tests? #f)) ;no tests
6650 (propagated-inputs (list ocaml-ppxlib))
6651 (properties `((upstream-name . "ppx_ignore_instrumentation")))
6652 (home-page "https://github.com/janestreet/ppx_ignore_instrumentation")
6653 (synopsis "Ignore Jane Street specific instrumentation extensions")
6655 "Ignore Jane Street specific instrumentation extensions from internal
6656 PPXs or compiler features not yet upstreamed.")
6657 (license license:expat)))
6659 (define-public ocaml-ppx-log
6661 (name "ocaml-ppx-log")
6667 (url "https://github.com/janestreet/ppx_log")
6668 (commit (string-append "v" version))))
6669 (file-name (git-file-name name version))
6671 (base32 "08i9gz3f4w3bmlrfdw7ja9awsfkhhldz03bnnc4hijfmn8sawzi0"))))
6672 (build-system dune-build-system)
6677 ocaml-ppx-sexp-message
6680 (properties `((upstream-name . "ppx_log")))
6681 (home-page "https://github.com/janestreet/ppx_log")
6682 (synopsis "Extension nodes for lazily rendering log messages")
6683 (description "This package provides ppx_sexp_message-like extension
6684 nodes for lazily rendering log messages.")
6685 (license license:expat)))
6687 (define-public ocaml-ppx-disable-unused-warnings
6689 (name "ocaml-ppx-disable-unused-warnings")
6695 (url "https://github.com/janestreet/ppx_disable_unused_warnings")
6696 (commit (string-append "v" version))))
6697 (file-name (git-file-name name version))
6699 (base32 "0sb5i4v7p9df2bxk66rjs30k9fqdrwsq1jgykjv6wyrx2d9bv955"))))
6700 (build-system dune-build-system)
6702 `(#:test-target "tests"))
6703 (propagated-inputs (list ocaml-base ocaml-ppxlib))
6704 (properties `((upstream-name . "ppx_disable_unused_warnings")))
6705 (home-page "https://github.com/janestreet/ppx_disable_unused_warnings")
6706 (synopsis "Simple ppx extension for commonly unused warnings")
6707 (description "This package expands @code{@@disable_unused_warnings} into
6708 @code{@@warning \"-20-26-32-33-34-35-36-37-38-39-60-66-67\"}")
6709 (license license:expat)))
6711 (define-public ocaml-ppx-jane
6713 (name "ocaml-ppx-jane")
6719 (url "https://github.com/janestreet/ppx_jane")
6720 (commit (string-append "v" version))))
6721 (file-name (git-file-name name version))
6723 (base32 "1p6847gdfnnj6qpa4yh57s6wwpsl7rfgy0q7993chz24h9mhz5lk"))))
6724 (build-system dune-build-system)
6726 `(#:test-target "."))
6728 (list ocaml-base-quickcheck
6733 ocaml-ppx-custom-printf
6734 ocaml-ppx-disable-unused-warnings
6736 ocaml-ppx-fields-conv
6737 ocaml-ppx-fixed-literal
6739 ocaml-ppx-ignore-instrumentation
6740 ocaml-ppx-inline-test
6743 ocaml-ppx-module-timer
6747 ocaml-ppx-sexp-message
6748 ocaml-ppx-sexp-value
6751 ocaml-ppx-typerep-conv
6752 ocaml-ppx-variants-conv
6754 (properties `((upstream-name . "ppx_jane")
6755 (ocaml4.07-variant . ,(delay ocaml4.07-ppx-jane))))
6756 (home-page "https://github.com/janestreet/ppx_jane")
6757 (synopsis "Standard Jane Street ppx rewriters")
6758 (description "This package installs a ppx-jane executable, which is a ppx
6759 driver including all standard Jane Street ppx rewriters.")
6760 (license license:expat)))
6762 (define-public ocaml4.07-ppx-jane
6763 (package-with-ocaml4.07
6765 (inherit ocaml-ppx-jane)
6769 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
6770 (version-major+minor version)
6771 "/files/ppx_jane-v" version ".tar.gz"))
6774 "0lgppkw3aixrfnixihrsz2ipafv8fpvkdpy3pw8n0r615gg8x8la"))))
6776 (list ocaml-ppx-assert
6780 ocaml-ppx-custom-printf
6783 ocaml-ppx-fields-conv
6785 ocaml-ppx-inline-test
6790 ocaml-ppx-sexp-message
6791 ocaml-ppx-sexp-value
6792 ocaml-ppx-typerep-conv
6793 ocaml-ppx-variants-conv
6794 ocaml-migrate-parsetree
6797 (license license:asl2.0))))
6799 (define-public ocaml-base-bigstring
6801 (name "ocaml-base-bigstring")
6807 (url "https://github.com/janestreet/base_bigstring")
6808 (commit (string-append "v" version))))
6809 (file-name (git-file-name name version))
6811 (base32 "1hv3hw2fwqmkrxms1g6rw3c18mmla1z5bva3anx45mnff903iv4q"))))
6812 (build-system dune-build-system)
6813 (propagated-inputs (list ocaml-base ocaml-int-repr ocaml-ppx-jane))
6814 (properties `((upstream-name . "base_bigstring")))
6815 (home-page "https://github.com/janestreet/base_bigstring")
6816 (synopsis "String type based on [Bigarray], for use in I/O and C-bindings")
6817 (description "This package provides string type based on [Bigarray], for
6818 use in I/O and C-bindings.")
6819 (license license:expat)))
6821 (define-public ocaml-splittable-random
6823 (name "ocaml-splittable-random")
6829 (url "https://github.com/janestreet/splittable_random")
6830 (commit (string-append "v" version))))
6831 (file-name (git-file-name name version))
6833 (base32 "0ap5z4z1aagz4z02q9642cbl25jzws9lbc2x5xkpyjlc0qcm9v3m"))))
6834 (build-system dune-build-system)
6839 ocaml-ppx-inline-test
6840 ocaml-ppx-sexp-message))
6841 (properties `((upstream-name . "splittable_random")
6842 (ocaml-4.07-variant . ,(delay ocaml4.07-splittable-random))))
6843 (home-page "https://github.com/janestreet/splittable_random")
6844 (synopsis "PRNG that can be split into independent streams")
6845 (description "This package provides a splittable
6846 @acronym{PRNG,pseudo-random number generator} functions like a PRNG that can
6847 be used as a stream of random values; it can also be split to produce a
6848 second, independent stream of random values.
6850 This library implements a splittable pseudo-random number generator that sacrifices
6851 cryptographic-quality randomness in favor of performance.")
6852 (license license:expat)))
6854 (define-public ocaml4.07-splittable-random
6855 (package-with-ocaml4.07
6857 (inherit ocaml-splittable-random)
6861 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
6862 (version-major+minor version)
6863 "/files/splittable_random-v" version ".tar.gz"))
6866 "0l1wbd881mymlnpzlq5q53mmdz3g5d7qjhyc7lfaq1x0iaccn5lc"))))
6868 (list ocaml-base ocaml-ppx-jane ocaml-migrate-parsetree))
6870 (license license:asl2.0))))
6872 (define-public ocaml-base-quickcheck
6874 (name "ocaml-base-quickcheck")
6880 (url "https://github.com/janestreet/base_quickcheck")
6881 (commit (string-append "v" version))))
6882 (file-name (git-file-name name version))
6884 (base32 "0q73kfr67cz5wp4qn4rq3lpa922hqmvwdiinnans0js65fvlgqsi"))))
6885 (build-system dune-build-system)
6889 ocaml-ppx-fields-conv
6891 ocaml-ppx-sexp-message
6892 ocaml-ppx-sexp-value
6893 ocaml-splittable-random
6895 (properties `((upstream-name . "base_quickcheck")))
6896 (home-page "https://github.com/janestreet/base_quickcheck")
6898 "Randomized testing framework, designed for compatibility with Base")
6900 "@samp{base-quickcheck} provides randomized testing in the style of
6901 Haskell's Quickcheck library, with support for built-in types as well as
6902 types provided by Base.")
6903 (license license:expat)))
6905 (define-public ocaml4.07-jane-street-headers
6907 (name "ocaml4.07-jane-street-headers")
6911 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
6912 (version-major+minor version)
6913 "/files/jane-street-headers-v" version ".tar.gz"))
6916 "0afhzm08l9v883fhpqqh2lmy7az609pxif40bp7x1sk8c0yszqsh"))))
6917 (build-system dune-build-system)
6921 #:findlib ,ocaml4.07-findlib
6922 #:dune ,ocaml4.07-dune))
6923 (home-page "https://github.com/janestreet/jane-street-headers")
6924 (synopsis "Jane Street C header files")
6925 (description "This package provides C header files shared between the
6926 various Jane Street packages.")
6927 (license license:asl2.0)))
6929 (define-public ocaml4.07-configurator
6931 (name "ocaml4.07-configurator")
6935 (uri (string-append "https://ocaml.janestreet.com/ocaml-core/v"
6936 (version-major+minor version)
6937 "/files/configurator-v" version ".tar.gz"))
6940 "0kwgi3sh92v4n242dk5hgpwd85zzgnczgbkqi0q0kr6m93zgbf7p"))))
6941 (build-system dune-build-system)
6946 #:findlib ,ocaml4.07-findlib
6947 #:dune ,ocaml4.07-dune))
6949 `(("ocaml-base" ,(package-with-ocaml4.07 ocaml-base))
6950 ("ocaml-stdio" ,(package-with-ocaml4.07 ocaml-stdio))))
6951 (home-page "https://github.com/janestreet/configurator")
6952 (synopsis "Helper library for gathering system configuration")
6953 (description "Configurator is a small library that helps writing OCaml
6954 scripts that test features available on the system, in order to generate config.h
6957 Configurator allows one to:
6959 @item test if a C program compiles
6960 @item query pkg-config
6961 @item import #define from OCaml header files
6962 @item generate config.h file
6964 (license license:asl2.0)))
6966 (define-public ocaml-spawn
6968 (name "ocaml-spawn")
6973 (url "https://github.com/janestreet/spawn")
6974 (commit (string-append "v" version))))
6975 (file-name (git-file-name name version))
6978 "16aq5z3mq5lkpryfs4w0748b2w9v061myml0hn7nhh6r6i329w7a"))))
6979 (build-system dune-build-system)
6980 (propagated-inputs (list ocaml-odoc))
6981 (native-inputs (list ocaml-ppx-expect))
6983 `((ocaml4.07-variant . ,(delay ocaml4.07-spawn))))
6984 (home-page "https://github.com/janestreet/spawn")
6985 (synopsis "Spawning sub-processes")
6987 "Spawn is a small library exposing only one functionality: spawning sub-process.
6989 It has three main goals:
6992 @item provide missing features of Unix.create_process such as providing a
6994 @item provide better errors when a system call fails in the
6995 sub-process. For instance if a command is not found, you get a proper
6996 @code{Unix.Unix_error} exception,
6997 @item improve performances by using vfork when available. It is often
6998 claimed that nowadays fork is as fast as vfork, however in practice
6999 fork takes time proportional to the process memory while vfork is
7000 constant time. In application using a lot of memory, vfork can be
7001 thousands of times faster than fork.
7003 (license license:asl2.0)))
7005 (define-public ocaml4.07-spawn
7006 (package-with-ocaml4.07
7008 (inherit ocaml-spawn)
7013 (url "https://github.com/janestreet/spawn")
7014 (commit (string-append "v" version))))
7015 (file-name (git-file-name "ocaml4.07-spawn" version))
7018 "1w003k1kw1lmyiqlk58gkxx8rac7dchiqlz6ah7aj7bh49b36ppf"))))
7021 (modify-phases %standard-phases
7022 (add-before 'check 'fix-tests
7024 (substitute* "test/tests.ml"
7025 (("/bin/pwd") (which "pwd"))
7026 (("/bin/echo") (which "echo")))
7029 #:findlib ,ocaml4.07-findlib
7030 #:dune ,ocaml4.07-dune))
7031 (propagated-inputs '())
7034 (define-public ocaml-core
7042 (url "https://github.com/janestreet/core")
7043 (commit (string-append "v" version))))
7044 (file-name (git-file-name name version))
7046 (base32 "1m2ybvlz9zlb2d0jc0j7wdgd18mx9sh3ds2ylkv0cfjx1pzi0l25"))))
7047 (build-system dune-build-system)
7050 #:tests? #f)); Require a cyclic dependency: core_extended
7053 ocaml-base-bigstring
7054 ocaml-base-quickcheck
7057 ocaml-jane-street-headers
7062 ocaml-ppx-inline-test
7065 ocaml-ppx-sexp-message
7067 ocaml-splittable-random
7072 (home-page "https://github.com/janestreet/core")
7073 (synopsis "Alternative to OCaml's standard library")
7074 (description "The Core suite of libraries is an alternative to OCaml's
7075 standard library that was developed by Jane Street.")
7076 ;; Also contains parts of OCaml, relicensed to expat, as permitted
7077 ;; by OCaml's license for consortium members (see THIRD-PARTY.txt).
7078 (license license:expat)))
7080 (define-public ocaml4.07-core
7081 (package-with-ocaml4.07
7083 (inherit ocaml-core)
7088 (url "https://github.com/janestreet/core")
7089 (commit (string-append "v" version))))
7090 (file-name (git-file-name "ocaml4.07-core" version))
7093 "0pzl8n09z4f3i7z2wq4cjxfqrr8mj6xcdp7rbg0nxap2zdhjgvrq"))))
7096 ocaml4.07-configurator
7103 ocaml-migrate-parsetree
7105 ;; Also contains parts of OCaml, relicensed to asl2.0, as permitted
7106 ;; by OCaml's license for consortium members (see THIRD-PARTY.txt).
7107 (license license:asl2.0))))
7109 (define-public ocaml-int-repr
7111 (name "ocaml-int-repr")
7117 (url "https://github.com/janestreet/int_repr")
7118 (commit (string-append "v" version))))
7119 (file-name (git-file-name name version))
7121 (base32 "0ph88ym3s9dk30n17si2xam40sp8wv1xffw5cl3bskc2vfya1nvl"))))
7122 (build-system dune-build-system)
7124 `(#:tests? #f)) ;no tests
7125 (propagated-inputs (list ocaml-base ocaml-ppx-jane))
7126 (properties `((upstream-name . "int_repr")))
7127 (home-page "https://github.com/janestreet/int_repr")
7128 (synopsis "Integers of various widths")
7129 (description "Integers of various widths.")
7130 (license license:expat)))
7132 (define-public ocaml-core-kernel
7134 (name "ocaml-core-kernel")
7140 (url "https://github.com/janestreet/core_kernel")
7141 (commit (string-append "v" version))))
7142 (file-name (git-file-name name version))
7144 (base32 "05mb4vbf293iq1xx4acyrmi9cgcw6capwrsa54ils62alby6w6yq"))))
7145 (build-system dune-build-system)
7147 ;; Cyclic dependency with ocaml-core
7150 (list ocaml-base ocaml-core ocaml-int-repr ocaml-ppx-jane))
7151 (properties `((upstream-name . "core_kernel")
7152 (ocaml4.07-variant . ,(delay ocaml4.07-core-kernel))))
7153 (home-page "https://github.com/janestreet/core_kernel")
7154 (synopsis "Portable standard library for OCaml")
7155 (description "Core is an alternative to the OCaml standard library.
7157 Core_kernel is the system-independent part of Core. It is aimed for cases when
7158 the full Core is not available, such as in Javascript.")
7159 (license license:expat)))
7161 (define-public ocaml4.07-core-kernel
7162 (package-with-ocaml4.07
7164 (inherit ocaml-core-kernel)
7169 (url "https://github.com/janestreet/core_kernel")
7170 (commit (string-append "v" version))))
7171 (file-name (git-file-name "ocaml4.07-core-kernel" version))
7174 "1dg7ygy7i64c5gaakb1cp1b26p9ks81vbxmb8fd7jff2q60j2z2g"))))
7178 ocaml4.07-configurator
7180 ocaml-jane-street-headers
7184 ocaml-ppx-inline-test
7187 ocaml-ppx-sexp-message
7189 ocaml-splittable-random
7193 ocaml-migrate-parsetree))
7196 ;; this package and parts of OCaml, relicensed by janestreet
7201 (define-public ocaml-timezone
7203 (name "ocaml-timezone")
7209 (url "https://github.com/janestreet/timezone")
7210 (commit (string-append "v" version))))
7211 (file-name (git-file-name name version))
7213 (base32 "00a007aji5rbz42kgbq1w90py6fm9k9akycs5abkcfll5rd0cbhx"))))
7214 (build-system dune-build-system)
7215 (propagated-inputs (list ocaml-core ocaml-ppx-jane))
7216 (home-page "https://github.com/janestreet/timezone")
7217 (synopsis "Time-zone handling")
7219 "Timezone handles parsing timezone data and create @code{Timezone.t}
7220 that can later be used to manipulate time in core_kernel or core.")
7221 (license license:expat)))
7223 (define-public ocaml-markup
7225 (name "ocaml-markup")
7227 (home-page "https://github.com/aantron/markup.ml")
7232 (url (string-append home-page ".git"))
7234 (file-name (git-file-name name version))
7237 "1acgcbhx4rxx92rf65lsns588d6zzfrin2pnpkx24jw5vbgz7idn"))))
7238 (build-system dune-build-system)
7240 `(#:package "markup"))
7242 (list ocaml-bisect-ppx ocaml-uchar ocaml-uutf ocaml-lwt))
7244 (list ocaml-ounit2 pkg-config))
7246 `((ocaml4.07-variant . ,(delay (package-with-ocaml4.07 ocaml-markup0.8.0)))))
7247 (synopsis "Error-recovering functional HTML5 and XML parsers and writers")
7248 (description "Markup.ml provides an HTML parser and an XML parser. The
7249 parsers are wrapped in a simple interface: they are functions that transform
7250 byte streams to parsing signal streams. Streams can be manipulated in various
7251 ways, such as processing by fold, filter, and map, assembly into DOM tree
7252 structures, or serialization back to HTML or XML.
7254 Both parsers are based on their respective standards. The HTML parser, in
7255 particular, is based on the state machines defined in HTML5.
7257 The parsers are error-recovering by default, and accept fragments. This makes
7258 it very easy to get a best-effort parse of some input. The parsers can,
7259 however, be easily configured to be strict, and to accept only full documents.
7261 Apart from this, the parsers are streaming (do not build up a document in
7262 memory), non-blocking (can be used with threading libraries), lazy (do not
7263 consume input unless the signal stream is being read), and process the input in
7264 a single pass. They automatically detect the character encoding of the input
7265 stream, and convert everything to UTF-8.")
7266 (license license:bsd-3)))
7268 ;; ocaml-markup 1.0.0 can not be built with old version of dune used in
7269 ;; package-with-ocaml4.07
7270 (define-public ocaml-markup0.8.0
7272 (inherit ocaml-markup)
7273 (name "ocaml-markup")
7275 (home-page "https://github.com/aantron/markup.ml")
7280 (url (string-append home-page ".git"))
7282 (file-name (git-file-name name version))
7285 "0aif4abvfmi9xc1pvw5n5rbm6rzkkpsxyvdn0lanr33rjpvkwdlm"))))
7287 (list ocaml-ounit pkg-config))
7290 (define-public ocaml-tyxml
7292 (name "ocaml-tyxml")
7298 (url "https://github.com/ocsigen/tyxml")
7300 (file-name (git-file-name name version))
7303 "0bh66wknc7sx2r63kscp0hg6h73dkv6qpkx0cdz2qp7p28pg2ixz"))))
7304 (build-system dune-build-system)
7306 (list ocaml-re ocaml-seq ocaml-uutf))
7308 (list ocaml-alcotest))
7309 (arguments `(#:package "tyxml"))
7310 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-tyxml))))
7311 (home-page "https://github.com/ocsigen/tyxml/")
7312 (synopsis "TyXML is a library for building correct HTML and SVG documents")
7313 (description "TyXML provides a set of convenient combinators that uses the
7314 OCaml type system to ensure the validity of the generated documents. TyXML can
7315 be used with any representation of HTML and SVG: the textual one, provided
7316 directly by this package, or DOM trees (@code{js_of_ocaml-tyxml}) virtual DOM
7317 (@code{virtual-dom}) and reactive or replicated trees (@code{eliom}). You can
7318 also create your own representation and use it to instantiate a new set of
7320 (license license:lgpl2.1)))
7322 (define-public ocaml4.07-tyxml
7323 (package-with-ocaml4.07
7325 (inherit ocaml-tyxml)
7330 (url "https://github.com/ocsigen/tyxml")
7332 (file-name (git-file-name "ocaml-tyxml" version))
7335 "1hw4phyadcfgywgh5sj87i76gp56qwxzwlcpfdwjbf6ggag9clmd"))))
7338 (define-public ocaml-bisect-ppx
7340 (name "ocaml-bisect-ppx")
7346 (url "https://github.com/aantron/bisect_ppx")
7348 (file-name (git-file-name name version))
7351 "0562rwwnhqlf5alxl1wd1n0xs0k4aamxafrh8bbmh5yl3i5rxrx4"))))
7352 (build-system dune-build-system)
7354 (list ocaml-ppxlib ocaml-cmdliner))
7356 ;; Tests require ocamlformat which would lead to circular dependencies
7358 (properties `((upstream-name . "bisect_ppx")
7359 (ocaml4.07-variant . ,(delay ocaml4.07-bisect-ppx))))
7360 (home-page "https://github.com/aantron/bisect_ppx")
7361 (synopsis "Code coverage for OCaml")
7362 (description "Bisect_ppx helps you test thoroughly. It is a small
7363 preprocessor that inserts instrumentation at places in your code, such as
7364 if-then-else and match expressions. After you run tests, Bisect_ppx gives a
7365 nice HTML report showing which places were visited and which were missed.
7367 Usage is simple - add package bisect_ppx when building tests, run your tests,
7368 then run the Bisect_ppx report tool on the generated visitation files.")
7369 (license license:mpl2.0)))
7371 (define-public ocaml4.07-bisect-ppx
7372 (package-with-ocaml4.07
7374 (inherit ocaml-bisect-ppx)
7380 (url "https://github.com/aantron/bisect_ppx")
7382 (file-name (git-file-name "ocaml-bisect-ppx" version))
7385 "1njs8xc108rrpx5am5zhhcn6vjva7rsphm8034qp5lgyvnhfgh7q"))))
7387 `(("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)
7388 ("ocaml-ppx-tools-versioned" ,ocaml4.07-ppx-tools-versioned)
7389 ,@(package-propagated-inputs ocaml-bisect-ppx)))
7391 `(("ocaml-ounit2" ,ocaml-ounit2)))
7394 ;; tests require git and network
7396 (properties '((upstream-name . "bisect_ppx"))))))
7398 (define-public ocaml-odoc
7401 ;; 2.2.0-alpha contains fixes for Dune 3.0 compatibility
7402 ;; (https://github.com/ocaml/odoc/commit/6ac97f3148f7791ec7451785ef4dbd9ca0daf2d1)
7403 (version "2.2.0-alpha")
7408 (url "https://github.com/ocaml/odoc")
7410 (file-name (git-file-name name version))
7412 (base32 "07zjkk455l51i29lcayzrc1q8j5bvbv97sscv8yhcj7x6h6q2nag"))))
7413 (build-system dune-build-system)
7416 (modify-phases %standard-phases
7417 (add-after 'unpack 'fix-test
7419 ;; test results expects #!/bin/sh but gets a store path instead
7420 (substitute* "test/xref2/with.t/run.t"
7421 (("#!/bin/sh") (string-append "#!" (which "sh")))))))))
7429 ocaml-migrate-parsetree
7435 (list ocaml-alcotest
7445 (properties `((ocaml4.07-variant . ,(delay ocaml4.07-odoc))))
7446 (home-page "https://github.com/ocaml/odoc")
7447 (synopsis "OCaml documentation generator")
7448 (description "Odoc is a documentation generator for OCaml. It reads
7449 @emph{doc comments}, delimited with @code{(** ... *)}, and outputs
7452 Text inside doc comments is marked up in ocamldoc syntax. Odoc's main
7453 advantage over ocamldoc is an accurate cross-referencer, which handles the
7454 complexity of the OCaml module system.")
7455 (license license:isc)))
7457 (define-public ocaml-odoc-parser
7459 (name "ocaml-odoc-parser")
7465 (url "https://github.com/ocaml-doc/odoc-parser")
7467 (file-name (git-file-name name version))
7470 "0mvwbnla0wd29bc7ckwpb494qv7p616cx8hnm0zg36np7v3zwy4w"))))
7471 (build-system dune-build-system)
7473 (list ocaml-astring ocaml-result))
7475 (list ocaml-ppx-expect))
7476 (home-page "https://github.com/ocaml-doc/odoc-parser")
7477 (synopsis "Parser for ocaml documentation comments")
7479 "This package provides a library for parsing the contents of OCaml
7480 documentation comments, formatted using Odoc syntax, an extension of the
7481 language understood by ocamldoc.")
7482 (license license:isc)))
7484 ;; version 1.5.2 requires ocaml-markdown 1.0.0 which does not compile
7485 ;; with old version of dune used in package-with-ocaml4.07
7486 (define-public ocaml4.07-odoc
7487 (package-with-ocaml4.07
7489 (inherit ocaml-odoc)
7496 (url "https://github.com/ocaml/odoc")
7498 (file-name (git-file-name name version))
7500 (base32 "0z2nisg1vb5xlk41hqw8drvj90v52wli7zvnih6a844cg6xsvvj2"))))
7503 `(("ocaml-alcotest" ,ocaml-alcotest)
7504 ("ocaml-markup" ,ocaml-markup)
7505 ("ocaml-sexplib" ,ocaml-sexplib)
7506 ("ocaml-re" ,ocaml-re)
7507 ("ocaml-uutf" ,ocaml-uutf)))
7509 `(("ocaml-astring" ,ocaml-astring)
7510 ("ocaml-cmdliner" ,ocaml-cmdliner)
7511 ("ocaml-cppo" ,ocaml-cppo)
7512 ("ocaml-fpath" ,ocaml-fpath)
7513 ("ocaml-result" ,ocaml-result)
7514 ("ocaml-tyxml" ,ocaml-tyxml)
7515 ("ocaml-bisect-ppx" ,ocaml-bisect-ppx)
7516 ("tidy-html" ,tidy-html)))
7519 (define-public ocaml-fftw3
7521 (name "ocaml-fftw3")
7527 (url "https://github.com/Chris00/fftw-ocaml")
7529 (file-name (git-file-name name version))
7532 "07ljbin9dsclsqh24p7haqjccz1w828sf5xfwlzl298d4a6zsbhs"))))
7533 (build-system dune-build-system)
7535 `(#:test-target "tests"))
7539 (list ocaml-cppo ocaml-lacaml))
7541 "https://github.com/Chris00/fftw-ocaml")
7543 "Bindings to FFTW3")
7545 "Bindings providing OCaml support for the seminal Fast Fourier Transform
7547 (license license:lgpl2.1))) ; with static linking exception.
7549 (define-public ocaml-lacaml
7551 (name "ocaml-lacaml")
7557 (url "https://github.com/mmottl/lacaml")
7559 (file-name (git-file-name name version))
7562 "115535kphchh2a434b48b408x9794j8zzrsdmacsgqdsrgy3rck4"))
7563 (modules '((guix build utils)))
7564 (snippet '(substitute* '("src/dune" "src/config/dune")
7565 (("-march=native") "")))))
7566 (properties '((tunable? . #t)))
7567 (build-system dune-build-system)
7569 `(#:tests? #f)) ; No test target.
7571 (list openblas lapack ocaml-base ocaml-stdio))
7572 (home-page "https://mmottl.github.io/lacaml/")
7574 "OCaml-bindings to BLAS and LAPACK")
7576 "Lacaml interfaces the BLAS-library (Basic Linear Algebra Subroutines) and
7577 LAPACK-library (Linear Algebra routines). It also contains many additional
7578 convenience functions for vectors and matrices.")
7579 (license license:lgpl2.1)))
7581 (define-public ocaml-cairo2
7583 (name "ocaml-cairo2")
7588 (url "https://github.com/Chris00/ocaml-cairo")
7590 (file-name (git-file-name name version))
7593 "1m0wh0s0sqjfa3mgq99lwk0dsg0bwxipaz93hq18m0lz5fqxib1m"))))
7594 (build-system dune-build-system)
7596 `(#:test-target "tests"))
7600 ("lablgtk" ,lablgtk)))
7603 (home-page "https://github.com/Chris00/ocaml-cairo")
7604 (synopsis "Binding to Cairo, a 2D Vector Graphics Library")
7605 (description "Ocaml-cairo2 is a binding to Cairo, a 2D graphics library
7606 with support for multiple output devices. Currently supported output targets
7607 include the X Window System, Quartz, Win32, image buffers, PostScript, PDF,
7608 and SVG file output.")
7609 (license license:lgpl3+)))
7611 (define-public ocaml-version
7613 (name "ocaml-version")
7619 (url "https://github.com/ocurrent/ocaml-version")
7620 (commit (string-append "v" version))))
7621 (file-name (git-file-name name version))
7624 "1c13zk1qna59m5z9jx7da3p7cxd48scpyk7zg7gi6gc6hx5hhjx8"))))
7625 (build-system dune-build-system)
7626 (arguments `(#:tests? #f)) ; no tests
7627 (properties '((upstream-name . "ocaml-version")))
7629 "https://github.com/ocurrent/ocaml-version")
7631 "Manipulate, parse and generate OCaml compiler version strings")
7633 "This library provides facilities to parse version numbers of the OCaml
7634 compiler, and enumerates the various official OCaml releases and configuration
7636 (license license:isc)))
7638 (define-public ocaml-mdx
7645 (url "https://github.com/realworldocaml/mdx")
7647 (file-name (git-file-name name version))
7650 "1w1givvhwv9jzj9zbg4mmlpb35sqi75w83r99p2z50bdr69fdf57"))))
7651 (build-system dune-build-system)
7654 (modify-phases %standard-phases
7655 (add-after 'unpack 'fix-test-format
7657 ;; cmdliner changed the format and the tests fail
7658 (substitute* '("test/bin/mdx-test/misc/no-such-file/test.expected"
7659 "test/bin/mdx-test/misc/no-such-prelude/test.expected")
7661 (("COMMAND") "[COMMAND]")
7662 (("\\.\\.\\.") "…")))))))
7674 (list ocaml-cppo ocaml-lwt ocaml-alcotest))
7676 "https://github.com/realworldocaml/mdx")
7678 "Executable code blocks inside markdown files")
7680 "@code{ocaml-mdx} executes code blocks inside markdown files.
7681 There are (currently) two sub-commands, corresponding
7682 to two modes of operations: pre-processing (@code{ocaml-mdx pp})
7683 and tests (@code{ocaml-mdx test}]).
7685 The pre-processor mode allows mixing documentation and code,
7686 and to practice @dfn{literate programming} using markdown and OCaml.
7688 The test mode ensures that shell scripts and OCaml fragments
7689 in the documentation always stays up-to-date.
7691 @code{ocaml-mdx} is released as two binaries called @code{ocaml-mdx} and
7692 @code{mdx} which are the same, mdx being the deprecated name, kept for now for
7694 (license license:isc)))
7696 (define-public ocaml-mparser
7698 (name "ocaml-mparser")
7704 (url "https://github.com/murmour/mparser")
7706 (file-name (git-file-name name version))
7709 "16j19v16r42gcsii6a337zrs5cxnf12ig0vaysxyr7sq5lplqhkx"))))
7710 (build-system dune-build-system)
7713 '(#:package "mparser"
7715 (home-page "https://github.com/murmour/mparser")
7716 (synopsis "Simple monadic parser combinator library")
7718 "This library implements a rather complete and efficient monadic parser
7719 combinator library similar to the Parsec library for Haskell by Daan Leijen and
7720 the FParsec library for FSharp by Stephan Tolksdorf.")
7721 ;; With static linking exception.
7722 (license license:lgpl2.1+)))
7724 (define-public ocaml-mparser-re
7726 (inherit ocaml-mparser)
7727 (name "ocaml-mparser-re")
7730 '(#:package "mparser-re"
7733 (list ocaml-mparser ocaml-re))
7734 (synopsis "MParser plugin for RE-based regular expressions")
7735 (description "This package provides RE-based regular expressions
7736 support for Mparser.")))
7738 (define-public ocaml-mparser-pcre
7740 (inherit ocaml-mparser)
7741 (name "ocaml-mparser-pcre")
7744 '(#:package "mparser-pcre"
7747 (list ocaml-mparser ocaml-pcre))
7748 (synopsis "MParser plugin for PCRE-based regular expressions")
7749 (description "This package provides PCRE-based regular expressions
7750 support for Mparser.")))
7752 (define-public lablgtk3
7759 (url "https://github.com/garrigue/lablgtk")
7761 (file-name (git-file-name name version))
7764 "11qfc39cmwfwfpwmjh6wh98zwdv6p73bv8hqwcsss869vs1r7gmn"))))
7765 (build-system dune-build-system)
7769 (modify-phases %standard-phases
7770 (add-before 'build 'make-writable
7772 (for-each (lambda (file)
7774 (find-files "." "."))))
7775 (add-before 'build 'set-version
7777 (substitute* "dune-project"
7778 (("\\(name lablgtk3\\)")
7779 (string-append "(name lablgtk3)\n(version " ,version ")"))))))))
7781 (list ocaml-cairo2))
7783 (list camlp5 gtk+ gtksourceview-3 gtkspell3))
7786 (home-page "https://github.com/garrigue/lablgtk")
7787 (synopsis "OCaml interface to GTK+3")
7788 (description "LablGtk is an OCaml interface to GTK+ 1.2, 2.x and 3.x. It
7789 provides a strongly-typed object-oriented interface that is compatible with the
7790 dynamic typing of GTK+. Most widgets and methods are available. LablGtk
7791 also provides bindings to gdk-pixbuf, the GLArea widget (in combination with
7792 LablGL), gnomecanvas, gnomeui, gtksourceview, gtkspell, libglade (and it can
7793 generate OCaml code from .glade files), libpanel, librsvg and quartz.")
7794 ;; Version 2 only, with linking exception.
7795 (license license:lgpl2.0)))
7797 (define-public ocaml-reactivedata
7799 (name "ocaml-reactivedata")
7804 (url "https://github.com/ocsigen/reactiveData")
7806 (file-name (git-file-name name version))
7809 "0gmpfnw08c7hx4bsgrgvp6w7pq2ghqxq3qd1cbdyscbg9n22jrca"))))
7811 `(#:tests? #f)) ;no tests
7812 (build-system dune-build-system)
7813 (properties `((upstream-name . "reactiveData")))
7816 (home-page "https://github.com/ocsigen/reactiveData")
7817 (synopsis "Declarative events and signals for OCaml")
7819 "React is an OCaml module for functional reactive programming (FRP). It
7820 provides support to program with time varying values: declarative events and
7821 signals. React doesn't define any primitive event or signal, it lets the
7822 client chooses the concrete timeline.")
7823 (license license:lgpl2.1+)))
7825 (define-public ocaml-uucd
7832 (uri (string-append "https://erratique.ch/software/uucd/releases/"
7833 "uucd-" version ".tbz"))
7836 "0fc737v5gj3339jx4x9xr096lxrpwvp6vaiylhavcvsglcwbgm30"))))
7837 (build-system ocaml-build-system)
7839 '(#:build-flags '("build" "--tests" "true")
7841 (modify-phases %standard-phases
7842 (delete 'configure))))
7846 (list opam ocaml-findlib ocamlbuild ocaml-topkg))
7847 (home-page "https://erratique.ch/software/uucd")
7848 (synopsis "Unicode character database decoder for OCaml")
7849 (description "Uucd is an OCaml module to decode the data of the Unicode
7850 character database from its XML representation. It provides high-level (but
7851 not necessarily efficient) access to the data so that efficient
7852 representations can be extracted.")
7853 (license license:isc)))
7855 (define-public ocaml-uucp
7862 (uri (string-append "https://erratique.ch/software/uucp/releases/"
7863 "uucp-" version ".tbz"))
7866 "1yx9nih3d9prb9zizq8fzmmqylf24a6yifhf81h33znrj5xn1mpj"))))
7867 (build-system ocaml-build-system)
7869 '(#:build-flags '("build" "--tests" "true")
7871 (modify-phases %standard-phases
7872 (delete 'configure))))
7881 (home-page "https://erratique.ch/software/uucp")
7882 (synopsis "Unicode character properties for OCaml")
7883 (description "Uucp is an OCaml library providing efficient access to a
7884 selection of character properties of the Unicode character database.")
7885 (license license:isc)))
7887 (define-public ocaml-uuseg
7889 (name "ocaml-uuseg")
7894 (uri (string-append "https://erratique.ch/software/uuseg/releases/"
7895 "uuseg-" version ".tbz"))
7898 "1g9zyzjkhqxgbb9mh3cgaawscwdazv6y8kdqvmy6yhnimmfqv25p"))))
7899 (build-system ocaml-build-system)
7901 '(#:build-flags '("build" "--tests" "true")
7903 (modify-phases %standard-phases
7904 (delete 'configure))))
7906 (list ocaml-uucp ocaml-uutf ocaml-cmdliner))
7908 (list opam ocaml-findlib ocamlbuild ocaml-topkg))
7909 (home-page "https://erratique.ch/software/uuseg")
7910 (synopsis "Unicode text segmentation for OCaml")
7911 (description "Uuseg is an OCaml library for segmenting Unicode text. It
7912 implements the locale independent Unicode text segmentation algorithms to
7913 detect grapheme cluster, word and sentence boundaries and the Unicode line
7914 breaking algorithm to detect line break opportunities.
7916 The library is independent from any IO mechanism or Unicode text data
7917 structure and it can process text without a complete in-memory
7919 (license license:isc)))
7921 (define-public ocaml-fix
7924 (version "20220121")
7929 (url "https://gitlab.inria.fr/fpottier/fix")
7931 (file-name (git-file-name name version))
7934 "15785v43jcbqsw1y653cnb89alrcnbdri1h0w6zl6p7769ja9rdj"))))
7935 (build-system dune-build-system)
7939 (home-page "https://gitlab.inria.fr/fpottier/fix")
7940 (synopsis "Facilities for memoization and fixed points")
7941 (description "This package provides helpers with various constructions
7942 that involve memoization and recursion.")
7943 (license license:lgpl2.0)))
7945 (define-public ocaml-dune-build-info
7948 (name "ocaml-dune-build-info")
7949 (build-system dune-build-system)
7951 '(#:package "dune-build-info"
7952 ;; No separate test suite from dune.
7956 (synopsis "Embed build information inside an executable")
7957 (description "This package allows one to access information about how the
7958 executable was built, such as the version of the project at which it was built
7959 or the list of statically linked libraries with their versions. It supports
7960 reporting the version from the version control system during development to
7961 get an precise reference of when the executable was built.")))
7963 (define-public ocaml-either
7965 (name "ocaml-either")
7971 (url "https://github.com/mirage/either")
7973 (file-name (git-file-name name version))
7975 (base32 "099p1m24vz5i0043zcfp88krzjsa2qbrphrm4bnx84gif5vgkxwm"))))
7976 (build-system dune-build-system)
7980 (home-page "https://github.com/mirage/either")
7981 (synopsis "Compatibility Either module")
7982 (description "This library is a compatibility module for the Either module
7983 defined in OCaml 4.12.0.")
7984 (license license:expat)))
7986 (define-public ocamlformat
7988 (name "ocamlformat")
7994 (url "https://github.com/ocaml-ppx/ocamlformat")
7996 (file-name (git-file-name name version))
7999 "171lq3vx4y8xj4by5zy93isx8nhg6ysxg1hxmkqkq16fdaiz8mnc"))))
8000 (build-system dune-build-system)
8002 '(#:package "ocamlformat"
8004 (modify-phases %standard-phases
8005 ;; Tests related to other packages
8006 (add-after 'unpack 'remove-unrelated-tests
8008 (delete-file-recursively "test/rpc")))
8009 (add-after 'unpack 'fix-test-format
8011 (substitute* "test/cli/repl_file_errors.t/run.t"
8012 ((" ;;") ";;")))))))
8017 ocaml-dune-build-info
8030 (list git-minimal ocaml-alcotest ocaml-ocp-indent ocaml-bisect-ppx))
8031 (home-page "https://github.com/ocaml-ppx/ocamlformat")
8032 (synopsis "Auto-formatter for OCaml code")
8033 (description "OCamlFormat is a tool to automatically format OCaml code in
8035 (license license:expat)))
8037 (define-public ocaml-bigstringaf
8039 (name "ocaml-bigstringaf")
8041 (home-page "https://github.com/inhabitedtype/bigstringaf")
8048 (file-name (git-file-name name version))
8051 "188j9awxg99vrp2l3rqfmdxdazq5xrjmg1wf62vfqsks9sff6wqx"))))
8052 (build-system dune-build-system)
8054 '(#:test-target "."))
8056 (list ocaml-bigarray-compat))
8058 (list ocaml-alcotest pkg-config))
8060 "Bigstring intrinsics and fast blits based on memcpy/memmove")
8062 "The OCaml compiler has a bunch of intrinsics for Bigstrings, but they're
8063 not widely-known, sometimes misused, and so programs that use Bigstrings are
8064 slower than they have to be. And even if a library got that part right and
8065 exposed the intrinsics properly, the compiler doesn't have any fast blits
8066 between Bigstrings and other string-like types. @code{bigstringaf} provides
8067 these missing pieces.")
8068 (license license:bsd-3)))
8070 (define-public ocaml-trie
8074 (home-page "https://github.com/kandu/trie/")
8081 (file-name (git-file-name name version))
8083 (base32 "0s7p9swjqjsqddylmgid6cv263ggq7pmb734z4k84yfcrgb6kg4g"))))
8084 (build-system dune-build-system)
8086 '(#:tests? #f)) ;no tests
8087 (synopsis "Strict impure trie tree")
8089 "This module implements strict impure trie tree data structure for
8091 (license license:expat)))
8093 (define-public ocaml-mew
8097 (home-page "https://github.com/kandu/mew")
8104 (file-name (git-file-name name version))
8106 (base32 "0417xsghj92v3xa5q4dk4nzf2r4mylrx2fd18i7cg3nzja65nia2"))))
8107 (build-system dune-build-system)
8109 (list ocaml-result ocaml-trie))
8111 (list ocaml-ppx-expect))
8112 (synopsis "General modal editing engine generator")
8114 "This package provides the core modules of Modal Editing Witch, a general
8115 modal editing engine generator.")
8116 (license license:expat)))
8118 (define-public ocaml-mew-vi
8120 (name "ocaml-mew-vi")
8122 (home-page "https://github.com/kandu/mew_vi")
8129 (file-name (git-file-name name version))
8131 (base32 "0lihbf822k5zasl60w5mhwmdkljlq49c9saayrws7g4qc1j353r8"))))
8132 (build-system dune-build-system)
8134 (list ocaml-mew ocaml-react))
8136 (list ocaml-ppx-expect))
8137 (properties `((upstream-name . "mew_vi")))
8138 (synopsis "Modal editing VI-like editing engine generator")
8139 (description "This module provides a vi-like modal editing engine
8141 (license license:expat)))
8143 (define-public ocaml-syntax-shims
8145 (name "ocaml-syntax-shims")
8147 (home-page "https://github.com/ocaml-ppx/ocaml-syntax-shims")
8154 (file-name (git-file-name name version))
8157 "0l1i8z95qgb0lxlrv3yb5nkp391hqsiyi4r91p12k3xmggqixagf"))))
8158 (build-system dune-build-system)
8160 `((upstream-name . "ocaml-syntax-shims")))
8162 "Backport new syntax to older OCaml versions")
8164 "This package backports new language features such as @code{let+} to older
8166 (license license:expat)))
8168 (define-public ocaml-angstrom
8170 (name "ocaml-angstrom")
8172 (home-page "https://github.com/inhabitedtype/angstrom")
8179 (file-name (git-file-name name version))
8182 "1hmrkdcdlkwy7rxhngf3cv3sa61cznnd9p5lmqhx20664gx2ibrh"))))
8183 (build-system dune-build-system)
8185 ;; Only build the base angstrom package.
8186 '(#:package "angstrom"
8189 (list ocaml-bigstringaf))
8191 (list ocaml-alcotest ocaml-ppx-let ocaml-syntax-shims))
8192 (synopsis "Parser combinators built for speed and memory-efficiency")
8194 "Angstrom is a parser-combinator library that makes it easy to write
8195 efficient, expressive, and reusable parsers suitable for high-performance
8196 applications. It exposes monadic and applicative interfaces for composition,
8197 and supports incremental input through buffered and unbuffered interfaces.
8198 Both interfaces give the user total control over the blocking behavior of
8199 their application, with the unbuffered interface enabling zero-copy IO.
8200 Parsers are backtracking by default and support unbounded lookahead.")
8201 (license license:bsd-3)))
8203 (define-public ocaml-graphics
8205 (name "ocaml-graphics")
8207 (home-page "https://github.com/ocaml/graphics")
8214 (file-name (git-file-name name version))
8217 "1q20f8y6ijxbvzik2ns4yl3w54q5z8kd0pby8i8c64a04hvly08m"))))
8218 (build-system dune-build-system)
8221 (synopsis "The OCaml graphics library")
8223 "The graphics library provides a set of portable drawing primitives.
8224 Drawing takes place in a separate window that is created when
8225 Graphics.open_graph is called. This library used to be distributed with OCaml
8227 (license license:lgpl2.1+)))
8229 (define-public ocaml-uri-sexp
8232 (name "ocaml-uri-sexp")
8234 '(#:package "uri-sexp"
8237 (list ocaml-uri ocaml-ppx-sexp-conv ocaml-sexplib0))
8238 (native-inputs (list ocaml-ounit))
8239 (synopsis "RFC3986 URI/URL parsing library")
8240 (description "This package adds S-exp support to @code{ocaml-uri}.")))
8242 (define-public ocaml-cohttp
8244 (name "ocaml-cohttp")
8250 (url "https://github.com/mirage/ocaml-cohttp")
8251 (commit (string-append "v" version))))
8252 (file-name (git-file-name name version))
8255 "074xis3wmr76gadh1ffmfzjfx13mw4kr2s6rkwqwzcl6l85n9x2z"))))
8256 (build-system dune-build-system)
8258 '(#:package "cohttp"
8259 #:test-target "cohttp_test/src"))
8269 (list ocaml-fmt ocaml-jsonm ocaml-alcotest))
8270 (home-page "https://github.com/mirage/ocaml-cohttp")
8271 (synopsis "OCaml library for HTTP clients and servers")
8273 "Cohttp is an OCaml library for creating HTTP daemons. It has a portable
8274 HTTP parser, and implementations using various asynchronous programming
8276 (license license:isc)))
8278 (define-public js-of-ocaml
8280 (name "js-of-ocaml")
8286 (url "https://github.com/ocsigen/js_of_ocaml")
8288 (file-name (git-file-name name version))
8290 (base32 "0iyhl9z57j53j2jvyqcwmxhbvy23l6g80aa0abmlgwam14yskspf"))))
8291 (build-system dune-build-system)
8293 `(#:tests? #f ;tests assume ocaml 4.13
8309 (list node ocaml-ppx-expect ocaml-num))
8310 (properties `((upstream-name . "js_of_ocaml")))
8311 (home-page "https://ocsigen.org/js_of_ocaml/")
8312 (synopsis "Compiler from OCaml bytecode to Javascript")
8313 (description "Js_of_ocaml is a compiler from OCaml bytecode to JavaScript.
8314 It makes it possible to run pure OCaml programs in JavaScript environment like
8315 browsers and Node.js.")
8316 (license license:lgpl2.1+)))
8318 (define-public ocaml-bibtex2html
8320 (name "ocaml-bibtex2html")
8325 (uri "https://www.lri.fr/~filliatr/ftp/bibtex2html/bibtex2html-1.99.tar.gz")
8326 (sha256 (base32 "07gzrs4lfrkvbn48cgn2gn6c7cx3jsanakkrb2irj0gmjzfxl96j"))))
8327 (build-system ocaml-build-system)
8330 (modify-phases %standard-phases
8331 (add-after 'unpack 'patch-/bin/sh
8333 (substitute* "configure" (("/bin/sh") (which "bash")))
8334 (setenv "HOME" (getcwd)) ;; mktexfmt needs writable home directory
8338 ("texlive" ,(texlive-updmap.cfg
8339 (list texlive-fonts-ec texlive-preprint
8340 texlive-hyperref texlive-bibtex)))))
8343 (home-page "https://www.lri.fr/~filliatr/bibtex2html/")
8344 (synopsis "BibTeX to HTML translator")
8345 (description "This package allows you to produce, from a set of
8346 bibliography files in BibTeX format, a bibliography in HTML format.")
8347 (license license:gpl2)))