summaryrefslogtreecommitdiff
path: root/dev-ml/llvm-ocaml
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-01-15 15:51:32 +0000
committerV3n3RiX <venerix@redcorelinux.org>2020-01-15 15:51:32 +0000
commit21435953e16cda318a82334ddbadb3b5c36d9ea7 (patch)
treee1810a4b135afce04b34862ef0fab2bfaeb8aeca /dev-ml/llvm-ocaml
parent7bc9c63c9da678a7e6fceb095d56c634afd22c56 (diff)
gentoo resync : 15.01.2020
Diffstat (limited to 'dev-ml/llvm-ocaml')
-rw-r--r--dev-ml/llvm-ocaml/Manifest11
-rw-r--r--dev-ml/llvm-ocaml/llvm-ocaml-10.0.0.9999.ebuild4
-rw-r--r--dev-ml/llvm-ocaml/llvm-ocaml-9.0.1.9999.ebuild118
-rw-r--r--dev-ml/llvm-ocaml/llvm-ocaml-9.0.1.ebuild (renamed from dev-ml/llvm-ocaml/llvm-ocaml-9.0.0.ebuild)4
-rw-r--r--dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc2.ebuild118
-rw-r--r--dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc3.ebuild118
6 files changed, 7 insertions, 366 deletions
diff --git a/dev-ml/llvm-ocaml/Manifest b/dev-ml/llvm-ocaml/Manifest
index a58201c04639..a748f8327faf 100644
--- a/dev-ml/llvm-ocaml/Manifest
+++ b/dev-ml/llvm-ocaml/Manifest
@@ -1,13 +1,8 @@
DIST llvm-7.1.0.src.tar.xz 28313784 BLAKE2B b78d9a7fc5ef6e352e77d339e5c4eef5ccedf67c05e7abd949e72619aa8a5ed65e7e5e2008354be8e7916d75581719b99f34227838fcc86c5d0080913c2fb22c SHA512 a7dbd5693d1f2dae6b6e52893a100f9349cbfcfb25c5fdcad46364acbff0dbd3573f8fbc026c68eb9fd56335198aa94b866cc3dd7ea0cbd2cbfb5f8fe3444a7a
DIST llvm-8.0.1.src.tar.xz 30477608 BLAKE2B 4319c837b36111401e3b0f9659b8d875c89463bcc7816df1aefe1e3ff989860bbaa92504718f8e15416cfd9f3491c13777cd5cb661877b237b342b0e515b93f5 SHA512 82e120be5cabdfd5111aebbea68a663fe229c8861d73802d6ab09a3bf48f60de333e07e61f8fb61beaa14ac2bea24fcd74fa6f761acaf62469f536b79fcb1e16
-DIST llvm-9.0.0.src.tar.xz 32994768 BLAKE2B 7f09bff9bcada95ab9c920c78aef92b57e665d9188bab39c734084ceb03a801c942fed48ea77fabeeb6110c648cb69363c659a6ce93ebf67dbba5c187219b13b SHA512 1bb3341e1d231559b948f1505b33c2e2e03989f9b8bbfef0e0cdaff5ac43f85574c9ec5ac53399b914f497d6899425d861411024e8d7e1d1a338c1c6951ac658
-DIST llvmorg-9.0.1-rc2.tar.gz 113203311 BLAKE2B 6e426060853e1587febedb75189444a1451236b713f800a4f3401c54318e48b0f5e0c484e9e4ef261faceed9b43b445a4153b061d4dadcc617047f9320b4f56a SHA512 fececd9365645920b9afdad1e94d5e10553ad4a39d84b3ac811b86014c395d51f7e4dabe54bb095a99481400c408bee3c9a2044168724d5e094e3258587a5d2c
-DIST llvmorg-9.0.1-rc3.tar.gz 113205740 BLAKE2B 3ca81e812833ecc2ac1bacfdeb86f54609ee125ba7390ce6af0113e949496149102360f35a9a0194dff93fb5cb6ade40a68382a03a7e55771a13198abb7ca9de SHA512 ea56a4ee57aacdd00a1d6551cdc768ecce3124a0eb6a9d09fe060bb147019a5119b2a9eaca576474be42e0296293daa923edd86dadb6759df0c2d7fc7a74f9f1
-EBUILD llvm-ocaml-10.0.0.9999.ebuild 3228 BLAKE2B b129cff30934d06d5593d3063c1cfab59c026033bc91fb966372dff69f9280fb5bca8201f4d821545890a4a8fc695f33d1f87cff5413c45603450b35b0da2f4f SHA512 9c66a27ffd2c3b693715c3280e4a50d5b991578d4258586159c9f54c87f855c24dc359e52f387bb1af45702196ef287eecf9bb50e3c31be96220ece3f77c2600
+DIST llvmorg-9.0.1.tar.gz 113193320 BLAKE2B b86e405f2b8e00436045fd409fe19cdde75c797b1192c62a22b5ec75e6b4dc8e874a0f33008dc31562445e4cbe53a992b6f48c684255a6a1ef261e595b8b161f SHA512 fa88beeaae94b6d0cd9b5ba38658d0ffed8004035d7d8a4f95c3d31a709b88b581ae9bd7761333c8e5375c44b8f6be01768b5a3be901163159d7e6c43b71da59
+EBUILD llvm-ocaml-10.0.0.9999.ebuild 3226 BLAKE2B c541ef2c066ea53dcc91311072147670b9f64e5d9b09b3c4f7ca9086d9526c6427e1332b7e50c17c86bf3172d520cf0845b2debb967ae66144521e332e7a1f6c SHA512 95cf7eb3d0748b09e4d588db19108654bd93e52e0d23278a64707e2cc40ae39e2d7cdd8b0568b9312f24c5cba34e3c119b51ae7e398693b4b64881b2779699f2
EBUILD llvm-ocaml-7.1.0.ebuild 3019 BLAKE2B 3bb0282cbc65f6a10d75c82d329265a4b9420eb13219bcc446fba957bd96bc94d0ffc8821f81b094f814758891a63c011233742edfddac6b4bed166ff42f95ea SHA512 b5d0686406132877d2e34f6eaf9476511e398d495d4f0753374c6665fcf1c986f0099be24bb434c11f9265320f34b36a0aa807569e5379a9a6c44e133ea1051c
EBUILD llvm-ocaml-8.0.1.ebuild 3064 BLAKE2B 41792ef0b7764c4b7c297a05ee56d4e613cbfbcb2e2157e7b70c8ecbb71aea698079abca2324291f9e0b9565e36509e81ee313bd152bb0c15c74c6b69c5f4dd6 SHA512 042075a171609318603e93320a6080f6b75319b7a6490a85bced7138001d30a72b45a0bf348a0e7c5a80f56c8c7cf3e6f921ed5fea41b62ece3226d00dde49d3
-EBUILD llvm-ocaml-9.0.0.ebuild 2930 BLAKE2B 75e7305a1538546960c59ce70dd9b33b041c3861075b7eb20b7f4337b26b0dbe019db672cc2498436fddf70668bbdd08ff76607c4f7928d8c1e056f3a68742bb SHA512 4f115b0008f38f2613c0a515ad1e3f85c5bafd20ba755bdc64151287c4a2648f5343828b5b16986620a74eccadb75f521269bd1e070518ed0e3bde5af0472e51
-EBUILD llvm-ocaml-9.0.1.9999.ebuild 2914 BLAKE2B 990b474f9bb2ef2a78e6df0b9c2041b48cffc62def03676210521a7da37291d6961b75bdcfff60af94bcd787420f43cb976e0a06459a06bfc1c03e2ddcb28941 SHA512 661257a87ab84be4e34ebd7296d2b62e1841a72b0962792b3f2b94363069034ae3fd536bd94b957e604d1991a5196dd53aea68fbd20c8623c55d905a714cade3
-EBUILD llvm-ocaml-9.0.1_rc2.ebuild 2930 BLAKE2B 75e7305a1538546960c59ce70dd9b33b041c3861075b7eb20b7f4337b26b0dbe019db672cc2498436fddf70668bbdd08ff76607c4f7928d8c1e056f3a68742bb SHA512 4f115b0008f38f2613c0a515ad1e3f85c5bafd20ba755bdc64151287c4a2648f5343828b5b16986620a74eccadb75f521269bd1e070518ed0e3bde5af0472e51
-EBUILD llvm-ocaml-9.0.1_rc3.ebuild 2930 BLAKE2B 75e7305a1538546960c59ce70dd9b33b041c3861075b7eb20b7f4337b26b0dbe019db672cc2498436fddf70668bbdd08ff76607c4f7928d8c1e056f3a68742bb SHA512 4f115b0008f38f2613c0a515ad1e3f85c5bafd20ba755bdc64151287c4a2648f5343828b5b16986620a74eccadb75f521269bd1e070518ed0e3bde5af0472e51
+EBUILD llvm-ocaml-9.0.1.ebuild 2928 BLAKE2B 5b0d8dafee22b55ae1fd5d9344ce10d96c3495237ffa6db6f0b429b10c99a85fcd0518942b41fc236b9654f9ae0d8ba7cad36a621c954e1900a5aede54ad8f64 SHA512 cc433c0d765e92cbf13a18b9c07f21e2369711ca98dcc71ae928e8ad49a089866b26a1426855bf555aa50f80d2de4eb4d150700f4851e157dce443c766acad86
MISC metadata.xml 216 BLAKE2B fe5e49887842aa513fbf1f2e09bed09a884d531fd21bdaeb2d389e8bf590b6c0e7063f0af98f66e2db129308ab0f0804ba327c3c752bbb4c900c59ac109d99aa SHA512 3485598147c953e72e1785693a489a7e7d73d59620b76054db9c0ce95d8bfa0e8ffec29da7f7a9d73a32e5b77eac07ca3306c56a972dc57fd89d477edaebf3d5
diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-10.0.0.9999.ebuild b/dev-ml/llvm-ocaml/llvm-ocaml-10.0.0.9999.ebuild
index 9445259b89dd..b9f6124e6f0b 100644
--- a/dev-ml/llvm-ocaml/llvm-ocaml-10.0.0.9999.ebuild
+++ b/dev-ml/llvm-ocaml/llvm-ocaml-10.0.0.9999.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-PYTHON_COMPAT=( python{2_7,3_{5,6,7}} )
+PYTHON_COMPAT=( python{2_7,3_{6,7}} )
inherit cmake-utils llvm llvm.org multiprocessing python-any-r1
DESCRIPTION="OCaml bindings for LLVM"
diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1.9999.ebuild b/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1.9999.ebuild
deleted file mode 100644
index e4629d049347..000000000000
--- a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1.9999.ebuild
+++ /dev/null
@@ -1,118 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python{2_7,3_{5,6,7}} )
-inherit cmake-utils llvm llvm.org multiprocessing python-any-r1
-
-DESCRIPTION="OCaml bindings for LLVM"
-HOMEPAGE="https://llvm.org/"
-LLVM_COMPONENTS=( llvm )
-llvm.org_set_globals
-
-# Keep in sync with sys-devel/llvm
-ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM BPF Hexagon Lanai Mips MSP430
- NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore )
-ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" )
-LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/?}
-
-LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA"
-SLOT="0/${PV}"
-KEYWORDS=""
-IUSE="debug test ${ALL_LLVM_TARGETS[*]}"
-REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )"
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- >=dev-lang/ocaml-4.00.0:0=
- dev-ml/ocaml-ctypes:=
- ~sys-devel/llvm-${PV}:=[${LLVM_TARGET_USEDEPS// /,},debug?]
- !sys-devel/llvm[ocaml(-)]"
-DEPEND="${RDEPEND}"
-BDEPEND="
- dev-lang/perl
- dev-ml/findlib
- test? ( dev-ml/ounit )
- ${PYTHON_DEPS}"
-
-# least intrusive of all
-CMAKE_BUILD_TYPE=RelWithDebInfo
-
-pkg_setup() {
- LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- # Python is needed to run tests using lit
- python_setup
-
- cmake-utils_src_prepare
-}
-
-src_configure() {
- local libdir=$(get_libdir)
- local mycmakeargs=(
- -DLLVM_LIBDIR_SUFFIX=${libdir#lib}
-
- -DBUILD_SHARED_LIBS=ON
- -DLLVM_OCAML_OUT_OF_TREE=ON
- -DLLVM_TARGETS_TO_BUILD="${LLVM_TARGETS// /;}"
- -DLLVM_BUILD_TESTS=$(usex test)
-
- # disable various irrelevant deps and settings
- -DLLVM_ENABLE_FFI=OFF
- -DLLVM_ENABLE_TERMINFO=OFF
- -DHAVE_HISTEDIT_H=NO
- -DWITH_POLLY=OFF
- -DLLVM_ENABLE_ASSERTIONS=$(usex debug)
- -DLLVM_ENABLE_EH=ON
- -DLLVM_ENABLE_RTTI=ON
-
- -DLLVM_HOST_TRIPLE="${CHOST}"
-
- # disable go bindings
- -DGO_EXECUTABLE=GO_EXECUTABLE-NOTFOUND
-
- # TODO: ocamldoc
- )
-
- use test && mycmakeargs+=(
- -DLLVM_LIT_ARGS="-vv;-j;${LIT_JOBS:-$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")}"
- )
-
- # 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
-
- local llvm_libdir=$(llvm-config --libdir)
- # an ugly hack; TODO: figure out a way to pass -L to ocaml...
- cd "${BUILD_DIR}/${libdir}" || die
- ln -s "${llvm_libdir}"/*.so . || die
-
- if use test; then
- local llvm_bindir=$(llvm-config --bindir)
- # Force using system-installed tools.
- sed -i -e "/llvm_tools_dir/s@\".*\"@\"${llvm_bindir}\"@" \
- "${BUILD_DIR}"/test/lit.site.cfg.py || die
- fi
-}
-
-src_compile() {
- cmake-utils_src_compile ocaml_all
-}
-
-src_test() {
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- cmake-utils_src_make check-llvm-bindings-ocaml
-}
-
-src_install() {
- DESTDIR="${D}" \
- cmake -P "${BUILD_DIR}"/bindings/ocaml/cmake_install.cmake || die
-
- dodoc bindings/ocaml/README.txt
-}
diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.0.ebuild b/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1.ebuild
index 0381b55ac4ad..a70188ba1f0c 100644
--- a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.0.ebuild
+++ b/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-PYTHON_COMPAT=( python{2_7,3_{5,6,7}} )
+PYTHON_COMPAT=( python{2_7,3_{6,7}} )
inherit cmake-utils llvm llvm.org multiprocessing python-any-r1
DESCRIPTION="OCaml bindings for LLVM"
diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc2.ebuild b/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc2.ebuild
deleted file mode 100644
index 0381b55ac4ad..000000000000
--- a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc2.ebuild
+++ /dev/null
@@ -1,118 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python{2_7,3_{5,6,7}} )
-inherit cmake-utils llvm llvm.org multiprocessing python-any-r1
-
-DESCRIPTION="OCaml bindings for LLVM"
-HOMEPAGE="https://llvm.org/"
-LLVM_COMPONENTS=( llvm )
-llvm.org_set_globals
-
-# Keep in sync with sys-devel/llvm
-ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM BPF Hexagon Lanai Mips MSP430
- NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore )
-ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" )
-LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/?}
-
-LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA"
-SLOT="0/${PV}"
-KEYWORDS="~amd64 ~arm ~x86"
-IUSE="debug test ${ALL_LLVM_TARGETS[*]}"
-REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )"
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- >=dev-lang/ocaml-4.00.0:0=
- dev-ml/ocaml-ctypes:=
- ~sys-devel/llvm-${PV}:=[${LLVM_TARGET_USEDEPS// /,},debug?]
- !sys-devel/llvm[ocaml(-)]"
-DEPEND="${RDEPEND}"
-BDEPEND="
- dev-lang/perl
- dev-ml/findlib
- test? ( dev-ml/ounit )
- ${PYTHON_DEPS}"
-
-# least intrusive of all
-CMAKE_BUILD_TYPE=RelWithDebInfo
-
-pkg_setup() {
- LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- # Python is needed to run tests using lit
- python_setup
-
- cmake-utils_src_prepare
-}
-
-src_configure() {
- local libdir=$(get_libdir)
- local mycmakeargs=(
- -DLLVM_LIBDIR_SUFFIX=${libdir#lib}
-
- -DBUILD_SHARED_LIBS=ON
- -DLLVM_OCAML_OUT_OF_TREE=ON
- -DLLVM_TARGETS_TO_BUILD="${LLVM_TARGETS// /;}"
- -DLLVM_BUILD_TESTS=$(usex test)
-
- # disable various irrelevant deps and settings
- -DLLVM_ENABLE_FFI=OFF
- -DLLVM_ENABLE_TERMINFO=OFF
- -DHAVE_HISTEDIT_H=NO
- -DWITH_POLLY=OFF
- -DLLVM_ENABLE_ASSERTIONS=$(usex debug)
- -DLLVM_ENABLE_EH=ON
- -DLLVM_ENABLE_RTTI=ON
-
- -DLLVM_HOST_TRIPLE="${CHOST}"
-
- # disable go bindings
- -DGO_EXECUTABLE=GO_EXECUTABLE-NOTFOUND
-
- # TODO: ocamldoc
- )
-
- use test && mycmakeargs+=(
- -DLLVM_LIT_ARGS="-vv;-j;${LIT_JOBS:-$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")}"
- )
-
- # 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
-
- local llvm_libdir=$(llvm-config --libdir)
- # an ugly hack; TODO: figure out a way to pass -L to ocaml...
- cd "${BUILD_DIR}/${libdir}" || die
- ln -s "${llvm_libdir}"/*.so . || die
-
- if use test; then
- local llvm_bindir=$(llvm-config --bindir)
- # Force using system-installed tools.
- sed -i -e "/llvm_tools_dir/s@\".*\"@\"${llvm_bindir}\"@" \
- "${BUILD_DIR}"/test/lit.site.cfg.py || die
- fi
-}
-
-src_compile() {
- cmake-utils_src_compile ocaml_all
-}
-
-src_test() {
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- cmake-utils_src_make check-llvm-bindings-ocaml
-}
-
-src_install() {
- DESTDIR="${D}" \
- cmake -P "${BUILD_DIR}"/bindings/ocaml/cmake_install.cmake || die
-
- dodoc bindings/ocaml/README.txt
-}
diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc3.ebuild b/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc3.ebuild
deleted file mode 100644
index 0381b55ac4ad..000000000000
--- a/dev-ml/llvm-ocaml/llvm-ocaml-9.0.1_rc3.ebuild
+++ /dev/null
@@ -1,118 +0,0 @@
-# Copyright 1999-2019 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python{2_7,3_{5,6,7}} )
-inherit cmake-utils llvm llvm.org multiprocessing python-any-r1
-
-DESCRIPTION="OCaml bindings for LLVM"
-HOMEPAGE="https://llvm.org/"
-LLVM_COMPONENTS=( llvm )
-llvm.org_set_globals
-
-# Keep in sync with sys-devel/llvm
-ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM BPF Hexagon Lanai Mips MSP430
- NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore )
-ALL_LLVM_TARGETS=( "${ALL_LLVM_TARGETS[@]/#/llvm_targets_}" )
-LLVM_TARGET_USEDEPS=${ALL_LLVM_TARGETS[@]/%/?}
-
-LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA"
-SLOT="0/${PV}"
-KEYWORDS="~amd64 ~arm ~x86"
-IUSE="debug test ${ALL_LLVM_TARGETS[*]}"
-REQUIRED_USE="|| ( ${ALL_LLVM_TARGETS[*]} )"
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- >=dev-lang/ocaml-4.00.0:0=
- dev-ml/ocaml-ctypes:=
- ~sys-devel/llvm-${PV}:=[${LLVM_TARGET_USEDEPS// /,},debug?]
- !sys-devel/llvm[ocaml(-)]"
-DEPEND="${RDEPEND}"
-BDEPEND="
- dev-lang/perl
- dev-ml/findlib
- test? ( dev-ml/ounit )
- ${PYTHON_DEPS}"
-
-# least intrusive of all
-CMAKE_BUILD_TYPE=RelWithDebInfo
-
-pkg_setup() {
- LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
- python-any-r1_pkg_setup
-}
-
-src_prepare() {
- # Python is needed to run tests using lit
- python_setup
-
- cmake-utils_src_prepare
-}
-
-src_configure() {
- local libdir=$(get_libdir)
- local mycmakeargs=(
- -DLLVM_LIBDIR_SUFFIX=${libdir#lib}
-
- -DBUILD_SHARED_LIBS=ON
- -DLLVM_OCAML_OUT_OF_TREE=ON
- -DLLVM_TARGETS_TO_BUILD="${LLVM_TARGETS// /;}"
- -DLLVM_BUILD_TESTS=$(usex test)
-
- # disable various irrelevant deps and settings
- -DLLVM_ENABLE_FFI=OFF
- -DLLVM_ENABLE_TERMINFO=OFF
- -DHAVE_HISTEDIT_H=NO
- -DWITH_POLLY=OFF
- -DLLVM_ENABLE_ASSERTIONS=$(usex debug)
- -DLLVM_ENABLE_EH=ON
- -DLLVM_ENABLE_RTTI=ON
-
- -DLLVM_HOST_TRIPLE="${CHOST}"
-
- # disable go bindings
- -DGO_EXECUTABLE=GO_EXECUTABLE-NOTFOUND
-
- # TODO: ocamldoc
- )
-
- use test && mycmakeargs+=(
- -DLLVM_LIT_ARGS="-vv;-j;${LIT_JOBS:-$(makeopts_jobs "${MAKEOPTS}" "$(get_nproc)")}"
- )
-
- # 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
-
- local llvm_libdir=$(llvm-config --libdir)
- # an ugly hack; TODO: figure out a way to pass -L to ocaml...
- cd "${BUILD_DIR}/${libdir}" || die
- ln -s "${llvm_libdir}"/*.so . || die
-
- if use test; then
- local llvm_bindir=$(llvm-config --bindir)
- # Force using system-installed tools.
- sed -i -e "/llvm_tools_dir/s@\".*\"@\"${llvm_bindir}\"@" \
- "${BUILD_DIR}"/test/lit.site.cfg.py || die
- fi
-}
-
-src_compile() {
- cmake-utils_src_compile ocaml_all
-}
-
-src_test() {
- # respect TMPDIR!
- local -x LIT_PRESERVES_TMP=1
- cmake-utils_src_make check-llvm-bindings-ocaml
-}
-
-src_install() {
- DESTDIR="${D}" \
- cmake -P "${BUILD_DIR}"/bindings/ocaml/cmake_install.cmake || die
-
- dodoc bindings/ocaml/README.txt
-}