GNU bug report logs - #35558
[PATCH] gnu: add ocaml-odoc.

Previous Next

Package: guix-patches;

Reported by: Gabriel Hondet <gabrielhondet <at> gmail.com>

Date: Sat, 4 May 2019 13:00:03 UTC

Severity: normal

Tags: patch

Done: Julien Lepiller <julien <at> lepiller.eu>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 35558 in the body.
You can then email your comments to 35558 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#35558; Package guix-patches. (Sat, 04 May 2019 13:00:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to Gabriel Hondet <gabrielhondet <at> gmail.com>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Sat, 04 May 2019 13:00:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Gabriel Hondet <gabrielhondet <at> gmail.com>
To: guix-patches <at> gnu.org
Subject: [PATCH] gnu: add ocaml-odoc.
Date: Sat, 04 May 2019 14:59:21 +0200
[Message part 1 (text/plain, inline)]
Hi everyone,

Please find enclosed a sequence of patches to add ocaml-odoc

Gabriel
[0001-gnu-Add-ocaml-markup.patch (text/x-diff, inline)]
From 5ba11eb3d3868ef92b6b2a37c6531963ec4ec6ab Mon Sep 17 00:00:00 2001
From: gabrielhdt <gabrielhondet <at> gmail.com>
Date: Sat, 4 May 2019 14:34:05 +0200
Subject: [PATCH 1/4] gnu: Add ocaml-markup.

* gnu/packages/ocaml.scm (ocaml-markup): New variable.
---
 gnu/packages/ocaml.scm | 42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 6e69be3f19..82fd1cdd91 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -4960,3 +4960,45 @@ the full Core is not available, such as in Javascript.")
                license:asl2.0
                ;; MLton and sjs
                license:expat))))
+
+(define-public ocaml-markup
+  (package
+    (name "ocaml-markup")
+    (version "0.8.0")
+    (home-page "https://github.com/aantron/markup.ml")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url (string-append home-page ".git"))
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "0aif4abvfmi9xc1pvw5n5rbm6rzkkpsxyvdn0lanr33rjpvkwdlm"))))
+    (build-system dune-build-system)
+    (inputs
+     `(("ocaml-uchar" ,ocaml-uchar)
+       ("ocaml-uutf" ,ocaml-uutf)
+       ("ocaml-lwt" ,ocaml-lwt)))
+    (native-inputs `(("ocaml-ounit" ,ocaml-ounit)))
+    (synopsis "Error-recovering functional HTML5 and XML parsers and writers")
+    (description "Markup.ml provides an HTML parser and an XML parser.  The
+parsers are wrapped in a simple interface: they are functions that transform
+byte streams to parsing signal streams.  Streams can be manipulated in various
+ways, such as processing by fold, filter, and map, assembly into DOM tree
+structures, or serialization back to HTML or XML.
+
+Both parsers are based on their respective standards.  The HTML parser, in
+particular, is based on the state machines defined in HTML5.
+
+The parsers are error-recovering by default, and accept fragments.  This makes
+it very easy to get a best-effort parse of some input.  The parsers can,
+however, be easily configured to be strict, and to accept only full documents.
+
+Apart from this, the parsers are streaming (do not build up a document in
+memory), non-blocking (can be used with threading libraries), lazy (do not
+consume input unless the signal stream is being read), and process the input in
+a single pass. They automatically detect the character encoding of the input
+stream, and convert everything to UTF-8.")
+    (license license:bsd-3)))
-- 
2.21.0

[0002-gnu-Add-ocaml-tyxml.patch (text/x-diff, inline)]
From 8883d5dce989627527bedfe67d37db3719723710 Mon Sep 17 00:00:00 2001
From: gabrielhdt <gabrielhondet <at> gmail.com>
Date: Sat, 4 May 2019 14:47:13 +0200
Subject: [PATCH 2/4] gnu: Add ocaml-tyxml.

* gnu/packages/ocaml.scm (ocaml-tyxml): New variable.
---
 gnu/packages/ocaml.scm | 40 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 82fd1cdd91..3588836beb 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -5002,3 +5002,43 @@ consume input unless the signal stream is being read), and process the input in
 a single pass. They automatically detect the character encoding of the input
 stream, and convert everything to UTF-8.")
     (license license:bsd-3)))
+
+(define-public ocaml-tyxml
+  (package
+    (name "ocaml-tyxml")
+    (version "4.3.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/ocsigen/tyxml.git")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "0wv19xipkj8l2sks1h53105ywbjwk7q93fb7b8al4a2g9wr109c0"))))
+    (build-system dune-build-system)
+    (inputs
+     `(("ocaml-re" ,ocaml-re)
+       ("ocaml-seq" ,ocaml-seq)
+       ("ocaml-uutf" ,ocaml-uutf)
+       ("ocaml-ppx-tools-versioned" ,ocaml-ppx-tools-versioned)
+       ("ocaml-markup" ,ocaml-markup)))
+    (native-inputs
+     `(("ocaml-alcotest" ,ocaml-alcotest)))
+    (arguments `(#:jbuild? #t))
+    (home-page "https://github.com/ocsigen/tyxml/")
+    (synopsis "TyXML is a library for building correct HTML and SVG documents")
+    (description "TyXML provides a set of convenient combinators that uses the
+OCaml type system to ensure the validity of the generated documents.  TyXML can
+be used with any representation of HTML and SVG: the textual one, provided
+directly by this package, or DOM trees (@code{js_of_ocaml-tyxml}) virtual DOM
+(@code{virtual-dom}) and reactive or replicated trees (@code{eliom}).  You can
+also create your own representation and use it to instantiate a new set of
+combinators.
+
+@code{
+open Tyxml
+let to_ocaml = Html.(a ~a:[a_href \"ocaml.org\"] [txt \"OCaml!\"])
+}")
+    (license license:lgpl2.1)))
-- 
2.21.0

[0003-gnu-Add-ocaml-bisect-ppx.patch (text/x-diff, inline)]
From 06bce0893b0a6a1fb2ab09d01e4fbfd2d3a75dd5 Mon Sep 17 00:00:00 2001
From: gabrielhdt <gabrielhondet <at> gmail.com>
Date: Sat, 4 May 2019 14:48:38 +0200
Subject: [PATCH 3/4] gnu: Add ocaml-bisect-ppx.

* gnu/packages/ocaml.scm (ocaml-bisect-ppx): New variable.
---
 gnu/packages/ocaml.scm | 30 ++++++++++++++++++++++++++++++
 1 file changed, 30 insertions(+)

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 3588836beb..787bbd855c 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -5042,3 +5042,33 @@ open Tyxml
 let to_ocaml = Html.(a ~a:[a_href \"ocaml.org\"] [txt \"OCaml!\"])
 }")
     (license license:lgpl2.1)))
+
+(define-public ocaml-bisect-ppx
+  (package
+    (name "ocaml-bisect-ppx")
+    (version "1.4.1")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/aantron/bisect_ppx.git")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "1vp3qvrkz7q25nbmvd40vhsnz2k9aqh17bnd21i3q8q0xlr5hdag"))))
+    (build-system dune-build-system)
+    (inputs
+     `(("ocaml-migrate-parsetree" ,ocaml-migrate-parsetree)
+       ("ocaml-ppx-tools-versioned" ,ocaml-ppx-tools-versioned)
+       ("ocaml-ounit" ,ocaml-ounit)))
+    (home-page "https://github.com/aantron/bisect_ppx")
+    (synopsis "Code coverage for OCaml")
+    (description "Bisect_ppx helps you test thoroughly.  It is a small
+preprocessor that inserts instrumentation at places in your code, such as
+if-then-else and match expressions.  After you run tests, Bisect_ppx gives a
+nice HTML report showing which places were visited and which were missed.
+
+Usage is simple - add package bisect_ppx when building tests, run your tests,
+then run the Bisect_ppx report tool on the generated visitation files.")
+    (license license:mpl2.0)))
-- 
2.21.0

[0004-gnu-Add-ocaml-odoc.patch (text/x-diff, inline)]
From 8cf63e00d15182fc674fa6e75b2949aa460f0cce Mon Sep 17 00:00:00 2001
From: gabrielhdt <gabrielhondet <at> gmail.com>
Date: Sat, 4 May 2019 14:53:58 +0200
Subject: [PATCH 4/4] gnu: Add ocaml-odoc.

* gnu/packages/ocaml.scm (ocaml-odoc): New variable.
---
 gnu/packages/ocaml.scm | 54 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 54 insertions(+)

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 787bbd855c..6cb597e75f 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -5072,3 +5072,57 @@ nice HTML report showing which places were visited and which were missed.
 Usage is simple - add package bisect_ppx when building tests, run your tests,
 then run the Bisect_ppx report tool on the generated visitation files.")
     (license license:mpl2.0)))
+
+(define-public ocaml-odoc
+  (package
+    (name "ocaml-odoc")
+    (version "1.4.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/ocaml/odoc")
+             (commit version)))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32
+         "0br11cw6wa0mwafja4xdb45d2f8908l6nzdq5mw5lbfq2jnp68km"))))
+    (build-system dune-build-system)
+    (inputs
+     `(("ocaml-alcotest" ,ocaml-alcotest)
+       ("ocaml-markup" ,ocaml-markup)
+       ("ocaml-sexplib" ,ocaml-sexplib)
+       ("ocaml-re" ,ocaml-re)
+       ("ocaml-uutf" ,ocaml-uutf)))
+    (native-inputs
+     `(("ocaml-astring" ,ocaml-astring)
+       ("ocaml-cmdliner" ,ocaml-cmdliner)
+       ("ocaml-cppo" ,ocaml-cppo)
+       ("ocaml-fpath" ,ocaml-fpath)
+       ("ocaml-result" ,ocaml-result)
+       ("ocaml-tyxml" ,ocaml-tyxml)
+       ("ocaml-bisect-ppx" ,ocaml-bisect-ppx)))
+    (home-page "https://github.com/ocaml/odoc")
+    (synopsis "OCaml documentation generator")
+    (description "@emph{odoc} is a documentation generator for OCaml.  It reads
+@emph{doc comments}, delimited with @code{(** ... *)}, and outputs
+@acronym{HTML}.
+
+Text inside doc comments is marked up in ocamldoc syntax:
+@code{
+val compare : string -> string -> int
+(** [compare s1 s2] compares [s1] and [s2] in {e lexicographic} order.  The
+    result is negative if [s1] precedes [s2], positive if [s1] follows [s2],
+    and zero if [s1] and [s2] are equal. *)
+}
+
+The syntax reference is
+@uref{https://caml.inria.fr/pub/docs/manual-ocaml/ocamldoc.html#sec357, here}.
+There is also an
+@uref{https://caml.inria.fr/pub/docs/manual-ocaml/ocamldoc.html#sec352,
+explanation} of how to attach comments to specific types, values, and other
+elements in your program.
+
+odoc's main advantage over ocamldoc is an accurate cross-referencer, which
+handles the complexity of the OCaml module system.")
+    (license license:isc)))
-- 
2.21.0

[signature.asc (application/pgp-signature, inline)]

Reply sent to Julien Lepiller <julien <at> lepiller.eu>:
You have taken responsibility. (Tue, 14 May 2019 19:44:01 GMT) Full text and rfc822 format available.

Notification sent to Gabriel Hondet <gabrielhondet <at> gmail.com>:
bug acknowledged by developer. (Tue, 14 May 2019 19:44:02 GMT) Full text and rfc822 format available.

Message #10 received at 35558-done <at> debbugs.gnu.org (full text, mbox):

From: Julien Lepiller <julien <at> lepiller.eu>
To: 35558-done <at> debbugs.gnu.org
Subject: Re: [bug#35558] [PATCH] gnu: add ocaml-odoc.
Date: Tue, 14 May 2019 21:42:40 +0200
Le Sat, 04 May 2019 14:59:21 +0200,
Gabriel Hondet <gabrielhondet <at> gmail.com> a écrit :

> Hi everyone,
> 
> Please find enclosed a sequence of patches to add ocaml-odoc
> 
> Gabriel

Pushed as 38089b549fa1d54fcced3aaab96cc50ea980eb54 to
2f8e77bee26aa548e232a06cbec41f9bf31e533d.

Thank you and sorry for the delay!




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 12 Jun 2019 11:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 4 years and 312 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.