blob: 4102ea67737c7970f9d5b3f178d43791888fa12f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit dune multiprocessing
MYPN="ocaml-${PN}"
DESCRIPTION="Pure OCaml library to read and write tar files"
HOMEPAGE="
https://github.com/mirage/ocaml-tar
https://opam.ocaml.org/packages/tar/
"
SRC_URI="https://github.com/mirage/${MYPN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${MYPN}-${PV}"
LICENSE="ISC"
SLOT="0/${PV}"
KEYWORDS="~amd64"
IUSE="mirage ocamlopt test unix"
RDEPEND="
dev-ml/camlp-streams:=
dev-ml/cstruct:=
dev-ml/re:=
dev-ml/lwt:=
mirage? (
dev-ml/io-page:=
dev-ml/mirage-block:=
dev-ml/mirage-kv:=
dev-ml/ptime:=
)
"
DEPEND="
${RDEPEND}
test? (
dev-ml/mirage-block-unix
dev-ml/ounit2
)
"
RESTRICT="!test? ( test )"
REQUIRED_USE="
test? ( mirage unix )
"
src_compile() {
local pkgs="tar"
for u in mirage unix ; do
if use ${u} ; then
pkgs="${pkgs},tar-${u}"
fi
done
dune build -p "${pkgs}" -j $(makeopts_jobs) || die
}
src_install() {
dune_src_install tar
use mirage && dune_src_install tar-mirage
use unix && dune_src_install tar-unix
}
|