commit:     2e2db0878d2e38cc3a76236fdbb57e4ccb84aebc
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat May 20 06:38:22 2023 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat May 20 06:55:58 2023 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2e2db087

app-crypt/sequoia-sq: use llvm.eclass for bindgen

Just like 1fd5803705bc3bc5ede5559d08b6e4c57a201fbf. Could bump the crates
like gyakovlev said but we're about to do that for a bump anyway.

Closes: https://bugs.gentoo.org/894358
Signed-off-by: Sam James <sam <AT> gentoo.org>

 app-crypt/sequoia-sq/sequoia-sq-0.28.0.ebuild | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/app-crypt/sequoia-sq/sequoia-sq-0.28.0.ebuild 
b/app-crypt/sequoia-sq/sequoia-sq-0.28.0.ebuild
index e50b539faf2b..80703b5860dd 100644
--- a/app-crypt/sequoia-sq/sequoia-sq-0.28.0.ebuild
+++ b/app-crypt/sequoia-sq/sequoia-sq-0.28.0.ebuild
@@ -419,7 +419,10 @@ CRATES="
        zeroize_derive-1.3.2
 "
 
-inherit bash-completion-r1 cargo
+# TODO: Should be able to try 16 in next release after 0.28.0
+LLVM_MAX_SLOT=15
+
+inherit bash-completion-r1 cargo llvm
 
 DESCRIPTION="CLI of the Sequoia OpenPGP implementation"
 HOMEPAGE="https://sequoia-pgp.org/ https://gitlab.com/sequoia-pgp/sequoia";
@@ -448,10 +451,16 @@ DEPEND="
        ${COMMON_DEPEND}
 "
 RDEPEND="${COMMON_DEPEND}"
+# Clang needed for bindgen
 BDEPEND="
+       <sys-devel/clang-$((${LLVM_MAX_SLOT} + 1))
        virtual/pkgconfig
 "
 
+llvm_check_deps() {
+       has_version -b "sys-devel/clang:${LLVM_SLOT}"
+}
+
 src_compile() {
        cd sq || die
        # Setting CARGO_TARGET_DIR is required to have the build system

Reply via email to