From: Michał Górny Date: Thu, 6 Apr 2017 12:47:20 +0000 (+0200) Subject: sys-devel/clang: Enable support for Z3 backend in -9999 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=958e93248a7304267883968e2fc8e58a14f07cdb;p=gentoo.git sys-devel/clang: Enable support for Z3 backend in -9999 --- diff --git a/sys-devel/clang/clang-9999.ebuild b/sys-devel/clang/clang-9999.ebuild index c28114fd1a91..05f378ffda76 100644 --- a/sys-devel/clang/clang-9999.ebuild +++ b/sys-devel/clang/clang-9999.ebuild @@ -27,11 +27,15 @@ LICENSE="UoI-NCSA" SLOT="5" KEYWORDS="" IUSE="debug default-compiler-rt default-libcxx +doc multitarget - +static-analyzer test xml elibc_musl kernel_FreeBSD ${ALL_LLVM_TARGETS[*]}" + +static-analyzer test xml z3 elibc_musl kernel_FreeBSD + ${ALL_LLVM_TARGETS[*]}" RDEPEND=" ~sys-devel/llvm-${PV}:${SLOT}=[debug=,${LLVM_TARGET_USEDEPS// /,},${MULTILIB_USEDEP}] - static-analyzer? ( dev-lang/perl:* ) + static-analyzer? ( + dev-lang/perl:* + z3? ( sci-mathematics/z3:0= ) + ) xml? ( dev-libs/libxml2:2=[${MULTILIB_USEDEP}] ) ${PYTHON_DEPS}" # configparser-3.2 breaks the build (3.3 or none at all are fine) @@ -170,6 +174,9 @@ multilib_src_configure() { -DCLANG_ENABLE_ARCMT=$(usex static-analyzer) -DCLANG_ENABLE_STATIC_ANALYZER=$(usex static-analyzer) + # z3 is not multilib-friendly + -DCLANG_ANALYZER_BUILD_Z3=$(multilib_native_usex z3) + -DZ3_INCLUDE_DIR="${EPREFIX}/usr/include/z3" ) use test && mycmakeargs+=( -DLLVM_MAIN_SRC_DIR="${WORKDIR}/llvm" diff --git a/sys-devel/clang/metadata.xml b/sys-devel/clang/metadata.xml index 38b8ec4ab6ab..03502538f638 100644 --- a/sys-devel/clang/metadata.xml +++ b/sys-devel/clang/metadata.xml @@ -31,5 +31,6 @@ Conformance with C/C++/ObjC and their variants Use libc++ instead of libstdc++ as the default stdlib for clang Build all host targets (default: host only) Install the Clang static analyzer + Enable the static analyzer constraint manager backend using sci-mathematics/z3