dev-ml/jsonm: fix install with -ocamlopt

Closes: https://bugs.gentoo.org/951856
Signed-off-by: Alfredo Tupone <tupone@gentoo.org>
This commit is contained in:
Alfredo Tupone
2025-03-23 09:44:50 +01:00
parent 93d92a2547
commit a44c4f4908

View File

@@ -1,4 +1,4 @@
# Copyright 1999-2024 Gentoo Authors
# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
@@ -29,9 +29,10 @@ src_install() {
# Can't use opam-installer here as it is an opam dep...
findlib_src_preinst
local nativelibs="$(echo _build/src/${PN}.cm{x,xa,xs,ti} _build/src/${PN}.a)"
local nativelibs=""
use ocamlopt && nativelibs="$(echo _build/src/${PN}.cm{x,xa,xs,ti} _build/src/${PN}.a)"
ocamlfind install ${PN} _build/pkg/META _build/src/${PN}.mli _build/src/${PN}.cm{a,i} ${nativelibs} || die
newbin _build/test/jsontrip.native jsontrip
use ocamlopt && newbin _build/test/jsontrip.native jsontrip
dodoc CHANGES.md TODO.md README.md
}