Skip to content

Commit

Permalink
dev-ml/llvm-ocaml: Port to cmake.eclass
Browse files Browse the repository at this point in the history
Signed-off-by: Michał Górny <[email protected]>
  • Loading branch information
mgorny committed Jun 20, 2020
1 parent 332e3c6 commit fa8e9f1
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions dev-ml/llvm-ocaml/llvm-ocaml-10.0.1_rc1.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
EAPI=7

PYTHON_COMPAT=( python3_{6,7,8} )
inherit cmake-utils llvm llvm.org multiprocessing python-any-r1
inherit cmake llvm llvm.org multiprocessing python-any-r1

DESCRIPTION="OCaml bindings for LLVM"
HOMEPAGE="https://llvm.org/"
Expand Down Expand Up @@ -53,7 +53,7 @@ src_prepare() {
# cmake eclasses suck by forcing ${S} here
CMAKE_USE_DIR=${S} \
S=${WORKDIR} \
cmake-utils_src_prepare
cmake_src_prepare
}

src_configure() {
Expand Down Expand Up @@ -95,7 +95,7 @@ src_configure() {
# LLVM_ENABLE_ASSERTIONS=NO does not guarantee this for us, #614844
# also: custom rules for OCaml do not work for CPPFLAGS
use debug || local -x CFLAGS="${CFLAGS} -DNDEBUG"
cmake-utils_src_configure
cmake_src_configure

local llvm_libdir=$(llvm-config --libdir)
# an ugly hack; TODO: figure out a way to pass -L to ocaml...
Expand All @@ -111,13 +111,13 @@ src_configure() {
}

src_compile() {
cmake-utils_src_compile ocaml_all
cmake_build ocaml_all
}

src_test() {
# respect TMPDIR!
local -x LIT_PRESERVES_TMP=1
cmake-utils_src_make check-llvm-bindings-ocaml
cmake_build check-llvm-bindings-ocaml
}

src_install() {
Expand Down

0 comments on commit fa8e9f1

Please sign in to comment.