commit:     c36fb520d47acb77de4b4dc3c8e7ff313696f3a6
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Apr 20 09:38:36 2024 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Apr 20 09:38:36 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c36fb520

dev-python/clang-python: Add 19.0.0_pre20240420 snapshot

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 dev-python/clang-python/Manifest                   |  1 +
 .../clang-python-19.0.0_pre20240420.ebuild         | 53 ++++++++++++++++++++++
 2 files changed, 54 insertions(+)

diff --git a/dev-python/clang-python/Manifest b/dev-python/clang-python/Manifest
index 89fe4a982fb8..bd71f2e58a68 100644
--- a/dev-python/clang-python/Manifest
+++ b/dev-python/clang-python/Manifest
@@ -7,3 +7,4 @@ DIST llvm-project-17.0.6.src.tar.xz.sig 438 BLAKE2B 
186e75b6a0fbfe1e85408589c149
 DIST llvm-project-18.1.4.src.tar.xz 132054668 BLAKE2B 
94bbad3b185fd07cbace4eff79aba80fbdd5e072739250e3927fe1848bcf3f8d355eb1f384e57306707eb702acc7ab01b732590735be7950221607664d04b0a6
 SHA512 
b1b214ae91f3705d8ea345547ad53f1e5d7d884c1eb6958bc41c14ac4b3e407771ccc2b693686ff103c8232c2c3942731d6db9a9cb4f735e6c6a0674739d0b29
 DIST llvm-project-18.1.4.src.tar.xz.sig 566 BLAKE2B 
b74fd219d7bcdf197b4e711cfbb25c40e9d8d2c7341de0215d8c31f330f396e9c166ff63513829cdc9cef349f08238f66a4dc949fa97958a7af496abae369eaa
 SHA512 
4f456edf4fb454815acaef6855b1a0991f229810a32e9369af83388e37f0ef8964308e1e93bd6216024cdd67e86caaadc8d5794467857cc6fe561c9fa6ca7386
 DIST llvm-project-ee284d2da0720dc21191d6f545504cbfcf5dcbcf.tar.gz 208883034 
BLAKE2B 
e37c9f1a6a4d0caa9a3091f979dd09f509d458f8b7b30286c77dd2385aea748b7aac6dd488c79573f82feb655aa321717bd2fb46bba4a12b388b52064f6e13bf
 SHA512 
1335ade87cd2accc47ac47ed2ab302999e375808b158b6c9d31fac9059cbb992d2bdaaadf1fd9a1b37268c1123d43346ea4d150894d6d2e6f80ba790b65b93b1
+DIST llvm-project-f03cd2db91956456f1c5e2da86d3c50183eebd28.tar.gz 209375254 
BLAKE2B 
1d7e043d04323edb64b2ef2309fbcb4f82a959f45391e815133cc0891d5a497bbb81101aab460e9bf67e75aa906e13ad1877c3850829dcad397ed626dc8f2792
 SHA512 
6775e03a44b2133bd4a4b473ab007599321daa19dc7f3cc47f95cf9d110e83e982bf48a6b1d43038b0f0a2c0fef2f689aefd20132b25a90ef19342683e2d2e50

diff --git a/dev-python/clang-python/clang-python-19.0.0_pre20240420.ebuild 
b/dev-python/clang-python/clang-python-19.0.0_pre20240420.ebuild
new file mode 100644
index 000000000000..bef9bf6fddbd
--- /dev/null
+++ b/dev-python/clang-python/clang-python-19.0.0_pre20240420.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{10..12} )
+inherit llvm.org python-r1
+
+DESCRIPTION="Python bindings for sys-devel/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="
+       >=sys-devel/clang-${PV}:*
+       !sys-devel/llvm:0[clang(-),python(-)]
+       !sys-devel/clang:0[python(-)]
+"
+RDEPEND="
+       ${DEPEND}
+       ${PYTHON_DEPS}
+"
+BDEPEND="
+       ${PYTHON_DEPS}
+       test? (
+               sys-devel/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
+}

Reply via email to