Gentoo Archives: gentoo-commits

From: Alfredo Tupone <tupone@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-ml/uutf/
Date: Mon, 05 Jul 2021 19:23:25
Message-Id: 1625512983.24c878bcf0b36279209d6bcfd7517308634359f7.tupone@gentoo
1 commit: 24c878bcf0b36279209d6bcfd7517308634359f7
2 Author: Alfredo Tupone <tupone <AT> gentoo <DOT> org>
3 AuthorDate: Mon Jul 5 19:23:03 2021 +0000
4 Commit: Alfredo Tupone <tupone <AT> gentoo <DOT> org>
5 CommitDate: Mon Jul 5 19:23:03 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=24c878bc
7
8 dev-ml/uutf: bump to 1.0.2
9
10 Package-Manager: Portage-3.0.20, Repoman-3.0.2
11 Signed-off-by: Alfredo Tupone <tupone <AT> gentoo.org>
12
13 dev-ml/uutf/Manifest | 1 +
14 dev-ml/uutf/uutf-1.0.2.ebuild | 63 +++++++++++++++++++++++++++++++++++++++++++
15 2 files changed, 64 insertions(+)
16
17 diff --git a/dev-ml/uutf/Manifest b/dev-ml/uutf/Manifest
18 index 29cbb152037..89a09addc80 100644
19 --- a/dev-ml/uutf/Manifest
20 +++ b/dev-ml/uutf/Manifest
21 @@ -1 +1,2 @@
22 DIST uutf-1.0.1.tbz 22215 BLAKE2B 58cbb8db94024ddaa02c213df4e5321ad33513370c6d1d54ac09f57821df8ac3b330c2659f9aeb0e78dfd15d2f50be714a5a5d6e6d3dcc3f81539c1a6c8c3771 SHA512 35cbee8c82a566f2fe4fcd549936d4c4dc67f5b71bfd3ea97ff25d7cf21cfb77cb5ee313c95ad26a2a61bb84aa48c300bbb79a1a7128c6161e9abe9c390a7d18
23 +DIST uutf-1.0.2.tbz 22420 BLAKE2B 8391f6c3cde40db3fa86b9243d8ea8fb52409aa958d1020f302d602bf7c06c44b7d93f7a6a64a1b0964c7bb5856e15178957bba48102dbd36d8efe9581db3787 SHA512 5f2dbe78eaf73a292438d84c7185c839a7ac13cee9616a7b5006990314c6a0d42b212854cc2e89d815d3c45804f94bb40af75ecb60da7092887d8dc21e968bdd
24
25 diff --git a/dev-ml/uutf/uutf-1.0.2.ebuild b/dev-ml/uutf/uutf-1.0.2.ebuild
26 new file mode 100644
27 index 00000000000..320c6dea77e
28 --- /dev/null
29 +++ b/dev-ml/uutf/uutf-1.0.2.ebuild
30 @@ -0,0 +1,63 @@
31 +# Copyright 1999-2021 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +
36 +inherit findlib
37 +
38 +DESCRIPTION="Non-blocking streaming Unicode codec for OCaml"
39 +HOMEPAGE="https://erratique.ch/software/uutf"
40 +SRC_URI="https://erratique.ch/software/uutf/releases/${P}.tbz"
41 +
42 +LICENSE="ISC"
43 +SLOT="0/${PV}"
44 +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86"
45 +IUSE="doc utftrip +ocamlopt test"
46 +RESTRICT="!test? ( test )"
47 +REQUIRED_USE="utftrip? ( ocamlopt )"
48 +
49 +RDEPEND=">=dev-lang/ocaml-3.12:=[ocamlopt?]
50 + dev-ml/uchar:=
51 + utftrip? ( dev-ml/cmdliner:= )"
52 +DEPEND="${RDEPEND}
53 + dev-ml/ocamlbuild
54 + dev-ml/topkg
55 + test? ( dev-ml/cmdliner )"
56 +
57 +src_compile() {
58 + ocaml pkg/pkg.ml build \
59 + --with-cmdliner "$(usex utftrip true false)" \
60 + || die
61 +}
62 +
63 +src_test() {
64 + if use ocamlopt ; then
65 + ocamlbuild -use-ocamlfind tests.otarget || die
66 + pushd _build/test || die
67 + ./test.native || die
68 + # Rebuild to avoid mismatches between installed files, bug #604674
69 + popd || die
70 + ocaml pkg/pkg.ml build \
71 + --with-cmdliner "$(usex utftrip true false)" \
72 + || die
73 + else
74 + ewarn "Sorry, ${PN} tests require native support (ocamlopt)"
75 + fi
76 +}
77 +
78 +src_install() {
79 + # Can't use opam-installer here as it is an opam dep...
80 + findlib_src_preinst
81 + local nativelibs=""
82 +
83 + use ocamlopt && nativelibs="$(echo _build/src/uutf.cm{x,xa,xs} _build/src/uutf.a)"
84 + ocamlfind install uutf _build/pkg/META _build/src/uutf.mli _build/src/uutf.cm{a,i} ${nativelibs} || die
85 +
86 + use utftrip && newbin utftrip.$(usex ocamlopt native byte) utftrip
87 + dodoc CHANGES.md README.md
88 +
89 + if use doc ; then
90 + docinto html
91 + dodoc -r doc/*
92 + fi
93 +}