commit:     ac7c28cf7c9d9946f1957534463e4c9fc54fa679
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 14 19:02:53 2023 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Fri Apr 14 19:06:28 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ac7c28cf

dev-python/clang-python: Add 17.0.0_pre20230414 snapshot

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

 dev-python/clang-python/Manifest                   |  1 +
 .../clang-python-17.0.0_pre20230414.ebuild         | 54 ++++++++++++++++++++++
 2 files changed, 55 insertions(+)

diff --git a/dev-python/clang-python/Manifest b/dev-python/clang-python/Manifest
index bea3a70b3746..0fd5905e2df6 100644
--- a/dev-python/clang-python/Manifest
+++ b/dev-python/clang-python/Manifest
@@ -5,3 +5,4 @@ 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.1.src.tar.xz 117990772 BLAKE2B 
298189ce6d7245711e5bd3e03fa74d603dda5a458463ca0cb261fe6949290c46a70abbd1ad1c556e08da3adc5df577305e267c1135214b900d78502e39b46bc5
 SHA512 
98fc11c0ad90d5e5a2cb123b497b89a1583fe7f91b3ff05c335037801ef66cbfab08f6d2eff539f0da238e9685d4bc7a9fb2578e28864fc9e9357b84129cefaa
 DIST llvm-project-16.0.1.src.tar.xz.sig 566 BLAKE2B 
06c03d789e63ab30bba4c56ba9ec91400d804448482d6a7fd395252b3b9166a5ee7a42a94c2074aa0d1809a3327f993d8932211f3fc05ad281db64c17b2a7094
 SHA512 
f42db28eb8280db06b1c78fa7a7aaea3a79499cecee1a64ce18c49b90c755b3a78fc93f01d1855887c7918ccc927c3b6147cfc916520f05d4cef65381ca6fe60
+DIST llvm-project-5c60a08c696c0420ddc5fdad5b8e50a7528cb3bf.tar.gz 182291041 
BLAKE2B 
f5997611e0293df515d4494d14895cc8fbe22b536f5c419e4ad7d098acbf2b1046ceb332d865eacdae0b7fa1a77b78090551976835dd1b95b5270c9f6e12e410
 SHA512 
6cda8e55b4fc70e94838c772c56213c811affda96fb98a03d432348f995a313447d0e0e84533350e1fda3162d82633b260ccd8e3b1d59d3216187b44dc5556fb

diff --git a/dev-python/clang-python/clang-python-17.0.0_pre20230414.ebuild 
b/dev-python/clang-python/clang-python-17.0.0_pre20230414.ebuild
new file mode 100644
index 000000000000..5ec556a2ca20
--- /dev/null
+++ b/dev-python/clang-python/clang-python-17.0.0_pre20230414.ebuild
@@ -0,0 +1,54 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{9..11} )
+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"
+KEYWORDS=""
+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