From a984494e5a73cca4db8adb6b670fbd04c3af955f Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 29 Jul 2023 22:40:34 +0100 Subject: gentoo auto-resync : 29:07:2023 - 22:40:34 --- dev-ml/llvm-ocaml/Manifest | 3 + dev-ml/llvm-ocaml/llvm-ocaml-17.0.0_rc1.ebuild | 112 +++++++++++++++++++++++++ 2 files changed, 115 insertions(+) create mode 100644 dev-ml/llvm-ocaml/llvm-ocaml-17.0.0_rc1.ebuild (limited to 'dev-ml/llvm-ocaml') diff --git a/dev-ml/llvm-ocaml/Manifest b/dev-ml/llvm-ocaml/Manifest index deed144f2768..066bdabaf601 100644 --- a/dev-ml/llvm-ocaml/Manifest +++ b/dev-ml/llvm-ocaml/Manifest @@ -4,11 +4,14 @@ DIST llvm-project-15.0.7.src.tar.xz 110936452 BLAKE2B f3d277e2029157329e5be78b78 DIST llvm-project-15.0.7.src.tar.xz.sig 566 BLAKE2B 47dc8c82d86237b80c6d85f83a6c9a6e9e174cf8e7f367b071e0cd9481d7cd408e991337c5624e07f3f370f26387c814f212808575ed1c1b58404d3e3836b7df SHA512 fc6891b440dd1175eb8df3790590af8d36bc92301660f84744ae15123475aeb900a151e6a8e7998ded27ec4d86871903ad0b89cd61164943054c2e3bc8d8beb2 DIST llvm-project-16.0.6.src.tar.xz 118013488 BLAKE2B 95192d39cbd2914e5609db365965f1c00bfea6c2d653b3996bd2acef8a2b37e37f6fc8a9d2b65711ad72657e0ef52c42f733053cf65051e7822f27396c30406d SHA512 89a67ebfbbc764cc456e8825ecfa90707741f8835b1b2adffae0b227ab1fe5ca9cce75b0efaffc9ca8431cae528dc54fd838867a56a2b645344d9e82d19ab1b7 DIST llvm-project-16.0.6.src.tar.xz.sig 566 BLAKE2B 2060cebd5ed57cb8a86a44238c43dfd4b921649298b10c3d19da308374c1e49869174294e29943c2af459fe06428264e26881d6c1288ebbc48686cc2cf467c7a SHA512 ca249262c7102e0889ec1bdc6f71a3a6f0e7e5d5fbab8abcd6fccd2871e7955eff7af5b055a76006097baf0dfaf2f5069eff3035b3107fc552abdb2481b21447 +DIST llvm-project-17.0.0rc1.src.tar.xz 127805900 BLAKE2B ab6e3b7e7af10bbb086bdd271691c259925b8047d8425b0eafb55d2c1daf637c3a56903b88e50283667955e780a47f61e7215a1e3a1acd3634c62960cf17317f SHA512 fa7ebe7fad14087861dc0eea08f68e8aa01dcc6560d70163ec38819a7fd799484f6ab1e35a69393a14962b45fa0a469c9d6c5fd2882b3609305bd01bc9f6701f +DIST llvm-project-17.0.0rc1.src.tar.xz.sig 438 BLAKE2B 976098c616d7f01c08c5be1d76dd395950184d2c6750f3f2c14235cdf446f1d876d842b3591f827cf1157fa25c707862a374e34d61fb73afe5a7b08d6041ee4a SHA512 272e92dec1fd43819f6fafdaa7f55a975e60a1c3000a69875209b89b7f3e2d2851e32ec0f2725242479203068349aaeff8da261d998a2325a9c52733bc5d7697 DIST llvm-project-5f1a388a11ae67c2e5d7a4d1fe45e369a393c572.tar.gz 194911977 BLAKE2B d7277591ddca0046dcc244f591732440a6c63c06557d96d18792c2544797a3bcea4af241ad1e9c0106a9751f52bfbcec0544020cc20874e8c64a31a8055d07d0 SHA512 b38aed6a21a3dd4325faf45475b843dcebab89d8ad9683e0f7699701f9645fa9467e032b822473c53a3242930d681caba9dd9530560636cf093108640470bbbe EBUILD llvm-ocaml-14.0.6.ebuild 2594 BLAKE2B 40fea3429bbf2e22f45598a679d9e5c6fa06343081a3a0a7c238bcbc8c3f270fea924ad57cab4f580adef66fe269eec188e6ed9f46772907063267805b7b51c7 SHA512 da649915c4804091ac68d9011a2370560f71e88952d13975a5f882e2c485d561fa0a5a43c61dd48f196534eae1e10aa6e46a9a9f6959d998ca850128c75a2615 EBUILD llvm-ocaml-15.0.7.ebuild 2598 BLAKE2B 22f3c86bea3a17027f4513685ddb9077800918dbe8dc74dd17e7d8ccfb729c11baf6eb60915d6795170d4dd5ee66b5c19d16653044a0ad7bb34f18161db06848 SHA512 04de6e60fc31644b6e99af4277f5300cdcee1f8e35f9038b490ed7841fd0c92e71bdaa423cdedbc5cccbd219e32857c8d1d0e09dfdfe4919b165ee73670efbfe EBUILD llvm-ocaml-16.0.6.ebuild 2533 BLAKE2B 598e42d89fce0b0a85a01b41166de25343dd6da9a6b422ff9f35f0cf515b759f85a180c25108df9ffbd8b773daad310851f05a11489e0af423c13a09b16c4585 SHA512 10809b6cdc64d70d9976a694123102de10804f65a5a9ea1e051638929c31e343f64388340307b500acd760ebbc2187ac6340336c39d6ae1280c34c5de5ce386d EBUILD llvm-ocaml-17.0.0.9999.ebuild 2518 BLAKE2B 73efb3edd502e713d1ed57d5387532ed7b4dd10831b705339eecd8c5df936ee31ff02f877ad36e0b30564f9837ec8c9535bfcbfc41af01ccaae1e4149e5a574e SHA512 42f7cbba2c706ae1c8198d1e2c1ef4771baa631d2cae65ce957c7ad726a7c43d79ce278c39813781ac72ee7c527543514c1b895b5db24f172893b8796210877f EBUILD llvm-ocaml-17.0.0_pre20230722.ebuild 2518 BLAKE2B 73efb3edd502e713d1ed57d5387532ed7b4dd10831b705339eecd8c5df936ee31ff02f877ad36e0b30564f9837ec8c9535bfcbfc41af01ccaae1e4149e5a574e SHA512 42f7cbba2c706ae1c8198d1e2c1ef4771baa631d2cae65ce957c7ad726a7c43d79ce278c39813781ac72ee7c527543514c1b895b5db24f172893b8796210877f +EBUILD llvm-ocaml-17.0.0_rc1.ebuild 2518 BLAKE2B 73efb3edd502e713d1ed57d5387532ed7b4dd10831b705339eecd8c5df936ee31ff02f877ad36e0b30564f9837ec8c9535bfcbfc41af01ccaae1e4149e5a574e SHA512 42f7cbba2c706ae1c8198d1e2c1ef4771baa631d2cae65ce957c7ad726a7c43d79ce278c39813781ac72ee7c527543514c1b895b5db24f172893b8796210877f EBUILD llvm-ocaml-18.0.0.9999.ebuild 2518 BLAKE2B 73efb3edd502e713d1ed57d5387532ed7b4dd10831b705339eecd8c5df936ee31ff02f877ad36e0b30564f9837ec8c9535bfcbfc41af01ccaae1e4149e5a574e SHA512 42f7cbba2c706ae1c8198d1e2c1ef4771baa631d2cae65ce957c7ad726a7c43d79ce278c39813781ac72ee7c527543514c1b895b5db24f172893b8796210877f MISC metadata.xml 299 BLAKE2B 2feead2cd1b35b3a43335ddd7711f8181b52bc63ee7166608914260c67528add5251349063afbef4f8cf0ec09b2cd4c3ffdd90f2c14ed60bb69ebc03888f6333 SHA512 cd745c54ab18d25bdaff18582105072574103a36cfe7c175ef740f266d00e9fc6f44c332904d23b911c939cf5bdf52973b388923099d8dd5dfef3c283b5cb685 diff --git a/dev-ml/llvm-ocaml/llvm-ocaml-17.0.0_rc1.ebuild b/dev-ml/llvm-ocaml/llvm-ocaml-17.0.0_rc1.ebuild new file mode 100644 index 000000000000..7499a8afc1dd --- /dev/null +++ b/dev-ml/llvm-ocaml/llvm-ocaml-17.0.0_rc1.ebuild @@ -0,0 +1,112 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..12} ) +inherit cmake llvm llvm.org python-any-r1 + +DESCRIPTION="OCaml bindings for LLVM" +HOMEPAGE="https://llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA" +SLOT="0/${PV}" +KEYWORDS="" +IUSE="+debug test" +RESTRICT="!test? ( test )" + +RDEPEND=" + >=dev-lang/ocaml-4.00.0:0= + dev-ml/ocaml-ctypes:= + ~sys-devel/llvm-${PV}:=[debug?] + !sys-devel/llvm[ocaml(-)] +" + +DEPEND=" + ${RDEPEND} +" +BDEPEND=" + ${PYTHON_DEPS} + dev-lang/perl + dev-ml/findlib + >=dev-util/cmake-3.16 +" + +LLVM_COMPONENTS=( llvm cmake third-party ) +LLVM_USE_TARGETS=llvm +llvm.org_set_globals + +pkg_setup() { + LLVM_MAX_SLOT=${LLVM_MAJOR} 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}" + + -DPython3_EXECUTABLE="${PYTHON}" + + # 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 +} -- cgit v1.2.3