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