summaryrefslogtreecommitdiff
path: root/dev-ml/llvm-ocaml
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2020-09-30 17:27:54 +0100
committerV3n3RiX <venerix@redcorelinux.org>2020-09-30 17:27:54 +0100
commitf70a1bfc721336d4fc7dfb711c2f518a6b18cf16 (patch)
treee907cb121b30e3c1df1710719c0ddf4029597a47 /dev-ml/llvm-ocaml
parentdb063b515939ab15261136b24e4bc44386335c0c (diff)
gentoo resync : 30.09.2020
Diffstat (limited to 'dev-ml/llvm-ocaml')
-rw-r--r--dev-ml/llvm-ocaml/Manifest2
-rw-r--r--dev-ml/llvm-ocaml/llvm-ocaml-11.0.0_rc4.ebuild115
2 files changed, 117 insertions, 0 deletions
diff --git a/dev-ml/llvm-ocaml/Manifest b/dev-ml/llvm-ocaml/Manifest
index 5fe0a52bfe27..06f6742d922f 100644
--- a/dev-ml/llvm-ocaml/Manifest
+++ b/dev-ml/llvm-ocaml/Manifest
@@ -1,11 +1,13 @@
DIST llvmorg-10.0.0.tar.gz 120804856 BLAKE2B 6b0254f5b913398cdcf2b2ec1ff219888706d2b79d5296590934714e42ac79f6a6547941ac2b1d2c4e6313dd18b6c7068e748aa6ac033e49fccbf5d355aa8191 SHA512 baa182d62fef1851836013ae8a1a00861ea89769778d67fb97b407a9de664e6c85da2af9c5b3f75d2bf34ff6b00004e531ca7e4b3115a26c0e61c575cf2303a0
DIST llvmorg-10.0.1.tar.gz 120880730 BLAKE2B 30f19f56c4d1f6abcda5fec76256219d1e3c8a6ff1a1f152f94bfe362c07884339fe571ff7fe903ed3b3deb150b2fa868c387887a0dea2930dc08b81db71a5b1 SHA512 48078fff9293a87f1a973f3348f79506f04c3da774295f5eb67d74dd2d1aa94f0973f8ced3f4ab9e8339902071f82c603b43d5608ad7227046c4da769c5d2151
DIST llvmorg-11.0.0-rc3.tar.gz 122766783 BLAKE2B 052fdc864fed52692141284ebdc41d52d21fbeaf24ac5ed3e67701537baa683bae61b1c06de68322e0578a27a1f5a8856088cdc001d2b8d34d2ec88ae65ff739 SHA512 a28ce74775373c63fe23b3116cd25db0efb95c6fdb60e56f2522659a404a59576f3d9429a109cb0f90534927259289aa1c712673f36f92272d642bf8dce5699f
+DIST llvmorg-11.0.0-rc4.tar.gz 122768150 BLAKE2B e92417b6e1775a10c196534518036de6393e3cb9e0e656d4f864e7870be8fb0dad3f4cf170345e653ba60f36172df117977d5dfebe3d9ee7ec2c160d3dc9c5cd SHA512 ed2aee9f6d0bb887f27840158e9f95d94c9ad3981a0388a33fcd3e405f5072134a02999075238b6a2b8803149aa08ac790214605b186c2cc2d4827ba53c00de1
DIST llvmorg-9.0.1.tar.gz 113193320 BLAKE2B b86e405f2b8e00436045fd409fe19cdde75c797b1192c62a22b5ec75e6b4dc8e874a0f33008dc31562445e4cbe53a992b6f48c684255a6a1ef261e595b8b161f SHA512 fa88beeaae94b6d0cd9b5ba38658d0ffed8004035d7d8a4f95c3d31a709b88b581ae9bd7761333c8e5375c44b8f6be01768b5a3be901163159d7e6c43b71da59
EBUILD llvm-ocaml-10.0.0.ebuild 3219 BLAKE2B 8d2ac0dc88b865f723c527315aaabb6bbd75773660b63197c833c72d7915495e494d73144f84a451dec3793d45a2f7f44dc22beb5c60f55dfd88a23bb04aede0 SHA512 fa83b587c1170564e25c040e2809daf6dc13d1718074d22a7093f08e7444d6378dbeb2f5ddc57f681f4a93b14c95275c87027c9e9191757b1fba4c9008464d38
EBUILD llvm-ocaml-10.0.1.ebuild 2960 BLAKE2B bf67406bf61b50af82f34276f7bfa6abe0bf809656e2addcc51efb7c1be5d4137462c9108239eea5f273a0e68f26c3300b3d2cc3cfe9df0c8555926e481fe231 SHA512 05e79634eb5e5ba38e0b0638a9627b7c8b38dfc7c685eaed8571283ed7791eb5d0ae2f6333cddf9b1f0f19b47e6d0e4c10444a4bc8bcdb69ce7061b25440a1b3
EBUILD llvm-ocaml-11.0.0.9999.ebuild 2947 BLAKE2B b457ceed658d32cafc3926b32d73b4da03fb1b2b3d26988a95b839c75a97a61e401f1249acd10ba25b380ddac1ffa65b1e07ee97d054940da8d999bbb0fbe915 SHA512 8fb8849eef370b9becb05033c1108b0858dff95cfada75a634c52e558bf551346b69e6cfcd406c4c6a0d2a0660a00d92808c99471ec0b65ff5986f4cf399a630
EBUILD llvm-ocaml-11.0.0_rc3.ebuild 2947 BLAKE2B b457ceed658d32cafc3926b32d73b4da03fb1b2b3d26988a95b839c75a97a61e401f1249acd10ba25b380ddac1ffa65b1e07ee97d054940da8d999bbb0fbe915 SHA512 8fb8849eef370b9becb05033c1108b0858dff95cfada75a634c52e558bf551346b69e6cfcd406c4c6a0d2a0660a00d92808c99471ec0b65ff5986f4cf399a630
+EBUILD llvm-ocaml-11.0.0_rc4.ebuild 2947 BLAKE2B b457ceed658d32cafc3926b32d73b4da03fb1b2b3d26988a95b839c75a97a61e401f1249acd10ba25b380ddac1ffa65b1e07ee97d054940da8d999bbb0fbe915 SHA512 8fb8849eef370b9becb05033c1108b0858dff95cfada75a634c52e558bf551346b69e6cfcd406c4c6a0d2a0660a00d92808c99471ec0b65ff5986f4cf399a630
EBUILD llvm-ocaml-12.0.0.9999.ebuild 2947 BLAKE2B b457ceed658d32cafc3926b32d73b4da03fb1b2b3d26988a95b839c75a97a61e401f1249acd10ba25b380ddac1ffa65b1e07ee97d054940da8d999bbb0fbe915 SHA512 8fb8849eef370b9becb05033c1108b0858dff95cfada75a634c52e558bf551346b69e6cfcd406c4c6a0d2a0660a00d92808c99471ec0b65ff5986f4cf399a630
EBUILD llvm-ocaml-9.0.1.ebuild 2922 BLAKE2B d7ae97c680d9f223a0fbaf2989ee60c4ae2baebf73664c9909485fea6c99f5c4c817ff522bee6175a741a5632687d1d0ea5b7b961587a258ca0737ac419390ac SHA512 dc30f078950d944a5c9d18d8804db82300845564afc05878cc7b157d37ad32259c528b358b9cd12684da3b9885b62e92cc6a32b46b8c4cbf48269839bd4cfa02
MISC metadata.xml 216 BLAKE2B fe5e49887842aa513fbf1f2e09bed09a884d531fd21bdaeb2d389e8bf590b6c0e7063f0af98f66e2db129308ab0f0804ba327c3c752bbb4c900c59ac109d99aa SHA512 3485598147c953e72e1785693a489a7e7d73d59620b76054db9c0ce95d8bfa0e8ffec29da7f7a9d73a32e5b77eac07ca3306c56a972dc57fd89d477edaebf3d5
diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-11.0.0_rc4.ebuild b/dev-ml/llvm-ocaml/llvm-ocaml-11.0.0_rc4.ebuild
new file mode 100644
index 000000000000..575154be6047
--- /dev/null
+++ b/dev-ml/llvm-ocaml/llvm-ocaml-11.0.0_rc4.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{6..9} )
+inherit cmake llvm llvm.org 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_EXPERIMENTAL_TARGETS=( ARC VE )
+ALL_LLVM_TARGETS=( AArch64 AMDGPU ARM AVR BPF Hexagon Lanai Mips MSP430
+ NVPTX PowerPC RISCV Sparc SystemZ WebAssembly X86 XCore
+ "${ALL_LLVM_EXPERIMENTAL_TARGETS[@]}" )
+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}"
+
+pkg_setup() {
+ LLVM_MAX_SLOT=${PV%%.*} llvm_pkg_setup
+ python-any-r1_pkg_setup
+}
+
+src_configure() {
+ local libdir=$(get_libdir)
+ local mycmakeargs=(
+ -DLLVM_LIBDIR_SUFFIX=${libdir#lib}
+
+ -DBUILD_SHARED_LIBS=OFF
+ -DLLVM_BUILD_LLVM_DYLIB=ON
+ -DLLVM_LINK_LLVM_DYLIB=ON
+ -DLLVM_OCAML_OUT_OF_TREE=ON
+
+ # cheap hack: LLVM combines both anyway, and the only difference
+ # is that the former list is explicitly verified at cmake time
+ -DLLVM_TARGETS_TO_BUILD=""
+ -DLLVM_EXPERIMENTAL_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
+ -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="$(get_lit_flags)"
+ )
+
+ # 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_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_build ocaml_all
+}
+
+src_test() {
+ # respect TMPDIR!
+ local -x LIT_PRESERVES_TMP=1
+ cmake_build check-llvm-bindings-ocaml
+}
+
+src_install() {
+ DESTDIR="${D}" \
+ cmake -P "${BUILD_DIR}"/bindings/ocaml/cmake_install.cmake || die
+
+ dodoc bindings/ocaml/README.txt
+}