Skip to content

Commit

Permalink
sys-devel/clang: Enable support for Z3 backend in -9999
Browse files Browse the repository at this point in the history
  • Loading branch information
mgorny committed Apr 6, 2017
1 parent f630116 commit 958e932
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
11 changes: 9 additions & 2 deletions sys-devel/clang/clang-9999.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down Expand Up @@ -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"
Expand Down
1 change: 1 addition & 0 deletions sys-devel/clang/metadata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,6 @@ Conformance with C/C++/ObjC and their variants</longdescription>
<flag name="default-libcxx">Use libc++ instead of libstdc++ as the default stdlib for clang</flag>
<flag name="multitarget">Build all host targets (default: host only)</flag>
<flag name="static-analyzer">Install the Clang static analyzer</flag>
<flag name="z3">Enable the static analyzer constraint manager backend using <pkg>sci-mathematics/z3</pkg></flag>
</use>
</pkgmetadata>

0 comments on commit 958e932

Please sign in to comment.