From mboxrd@z Thu Jan 1 00:00:00 1970 From: Julien Lepiller Subject: [PATCH 35/96] gnu: Add ocaml-uutf Date: Tue, 3 Jan 2017 20:11:16 +0100 Message-ID: <20170103191217.6431-36-julien@lepiller.eu> References: <20170103191217.6431-1-julien@lepiller.eu> Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:33038) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cOUXT-0000Q9-CM for guix-devel@gnu.org; Tue, 03 Jan 2017 14:14:28 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cOUXS-0005OI-Fi for guix-devel@gnu.org; Tue, 03 Jan 2017 14:14:27 -0500 Received: from dau94-h03-89-91-205-84.dsl.sta.abo.bbox.fr ([89.91.205.84]:35359 helo=skaro.lepiller.eu) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1cOUXS-0005Nb-6j for guix-devel@gnu.org; Tue, 03 Jan 2017 14:14:26 -0500 Received: from localhost (localhost [127.0.0.1]) by skaro.lepiller.eu (Postfix) with ESMTP id 488BF811B8 for ; Tue, 3 Jan 2017 20:14:24 +0100 (CET) Received: from skaro.lepiller.eu ([127.0.0.1]) by localhost (lepiller.eu [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id y-DVao_WJiVB for ; Tue, 3 Jan 2017 20:14:19 +0100 (CET) Received: from localhost.localdomain (128-79-116-134.hfc.dyn.abo.bbox.fr [128.79.116.134]) by skaro.lepiller.eu (Postfix) with ESMTPSA id A7B81811E5 for ; Tue, 3 Jan 2017 20:12:57 +0100 (CET) In-Reply-To: <20170103191217.6431-1-julien@lepiller.eu> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: guix-devel@gnu.org * gna/packages/ocaml.scm (ocaml-uutf): New variable. --- gnu/packages/ocaml.scm | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm index 48583e8c0..a4b129f42 100644 --- a/gnu/packages/ocaml.scm +++ b/gnu/packages/ocaml.scm @@ -1513,3 +1513,34 @@ representation of the data.") (description "The uchar package provides a compatibility library for the `Uchar` module introduced in OCaml 4.03.") (license license:lgpl2.1))) + +(define-public ocaml-uutf + (package + (name "ocaml-uutf") + (version "1.0.0") + (home-page "http://erratique.ch/software/uutf") + (source (origin + (method url-fetch) + (uri (string-append home-page "/releases/uutf-" version ".tbz")) + (sha256 + (base32 + "08i0cw02cxw4mi2rs01v9xi307qshs6fnd1dlqyb52kcxzblpp37")))) + (build-system ocaml-build-system) + (arguments `(#:tests? #f + #:build-flags (list "build") + #:phases + (modify-phases %standard-phases + (delete 'configure)))) + (native-inputs `(("opam" ,opam) + ("topkg" ,ocaml-topkg))) + (propagated-inputs `(("uchar" ,ocaml-uchar) + ("cmdliner" ,ocaml-cmdliner))) + (synopsis "Non-blocking streaming Unicode codec for OCaml") + (description "Uutf is a non-blocking streaming codec to decode and encode +the UTF-8, UTF-16, UTF-16LE and UTF-16BE encoding schemes. It can efficiently +work character by character without blocking on IO. Decoders perform character +position tracking and support newline normalization. + +Functions are also provided to fold over the characters of UTF encoded OCaml +string values and to directly encode characters in OCaml Buffer.t values.") + (license license:isc))) -- 2.11.0