commit: 9bf7368a5f99e9073ae8570e8fc9a585aeae8e58 Author: Michał Górny <mgorny <AT> gentoo <DOT> org> AuthorDate: Sat Mar 29 10:25:38 2025 +0000 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> CommitDate: Sat Mar 29 10:25:38 2025 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9bf7368a
dev-python/clang: Add 21.0.0_pre20250329 snapshot Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> dev-python/clang/Manifest | 1 + dev-python/clang/clang-21.0.0_pre20250329.ebuild | 53 ++++++++++++++++++++++++ 2 files changed, 54 insertions(+) diff --git a/dev-python/clang/Manifest b/dev-python/clang/Manifest index bbde20022e78..518a294cf47a 100644 --- a/dev-python/clang/Manifest +++ b/dev-python/clang/Manifest @@ -14,3 +14,4 @@ DIST llvm-project-1c3a9a853ce68c3c539e7cab21380b9d8b18f426.tar.gz 229448743 BLAK DIST llvm-project-1d133420dc512487e2be0e9d86755f2a7c3497a7.tar.gz 229268288 BLAKE2B aca79bcca631deeab429a03cd2732d78d8ecf0c9615bce181445ed875436806609dc85a57d4f97109492833d620d060ea93fed450a4912c2d94597aeabf84974 SHA512 24ecadfccdf785bfbf27d5007afd2a4d5868493b2c5f48d6cf07c335bfbfef5cba4f12a639971e5f95877ae3b8c7b7fc0c210e404d21036af553de82a5059037 DIST llvm-project-20.1.1.src.tar.xz 147215020 BLAKE2B d1774d060036b5340f765d68cc23cbd1e00730874cb3e65b7236303238d7922a7fa191b631c20c3bf17e54c933672a355d4424f2beea17cd25fcf9f5c4c625dd SHA512 b851d3e24a2775f6e789720614a8192d72956f447a39d75e5160a8acf6bd3a3386fab2cca5590b7e020b65e408ccf32432f8dc03519fd4cf60b4b5674fe0547e DIST llvm-project-20.1.1.src.tar.xz.sig 566 BLAKE2B 76c49401d9b8e283fc29586c32fc1b5205d76b3b83d0f99aa2ac09a63b058478e08588dcfbfc728110172b639eeaf04a884f4e6d707b94cad0dbf2d0dcb30a4f SHA512 469b03f3ddbe56b074724375b09a45ee2730bee0ba4b25f64f93d93ef609c33d39136f051c216a74a35d98a70ffcd3d7507e38d19a20d5006c29a954ca32813b +DIST llvm-project-21eeca3db0341fef4ab4a6464ffe38b2eba5810c.tar.gz 229546432 BLAKE2B e783f08b93498b252741a07fd3aa3383ca93f66688f9bbdb2e11185c660dfff1020ab4a1ca803ab69ab28dc2fd8b5c3855f45c0b77851b8e6edeb0dc5bf6cbd4 SHA512 54420956b36f3bccabea2171a4103ca20d6b136e1d1f7f217e0ec735be4542bbd840ef228c55f3e9103ad2f9fb41393e611d5aaa1521d01fdd163b770b80ba0b diff --git a/dev-python/clang/clang-21.0.0_pre20250329.ebuild b/dev-python/clang/clang-21.0.0_pre20250329.ebuild new file mode 100644 index 000000000000..694150a44a53 --- /dev/null +++ b/dev-python/clang/clang-21.0.0_pre20250329.ebuild @@ -0,0 +1,53 @@ +# Copyright 1999-2025 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +PYTHON_COMPAT=( python3_{10..13} ) +inherit llvm.org python-r1 + +DESCRIPTION="Python bindings for llvm-core/clang" +HOMEPAGE="https://llvm.org/" + +LICENSE="Apache-2.0-with-LLVM-exceptions UoI-NCSA" +SLOT="0" +IUSE="test" +RESTRICT="!test? ( test )" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" + +# The module is opening libclang.so directly, and doing some blasphemy +# on top of it. +DEPEND=" + >=llvm-core/clang-${PV}:* + !llvm-core/llvm:0[clang(-),python(-)] + !llvm-core/clang:0[python(-)] +" +RDEPEND=" + ${DEPEND} + ${PYTHON_DEPS} +" +BDEPEND=" + ${PYTHON_DEPS} + test? ( + llvm-core/clang:${LLVM_MAJOR} + ) +" + +LLVM_COMPONENTS=( clang/bindings/python ) +llvm.org_set_globals + +python_test() { + # tests rely on results from a specific clang version, so override + # the search path + local -x CLANG_LIBRARY_PATH=${BROOT}/usr/lib/llvm/${LLVM_MAJOR}/$(get_libdir) + local -x CLANG_NO_DEFAULT_CONFIG=1 + "${EPYTHON}" -m unittest discover -v || die "Tests fail with ${EPYTHON}" +} + +src_test() { + python_foreach_impl python_test +} + +src_install() { + python_foreach_impl python_domodule clang +}