blob: 3448694d2b845ad658432f83df064d51d92ec86d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=5
inherit git-r3 cmake-utils
DESCRIPTION="Fast symbolic manipulation library, written in C++"
HOMEPAGE="https://github.com/sympy/symengine"
SRC_URI=""
EGIT_REPO_URI="https://github.com/sympy/symengine.git"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
IUSE="boost openmp threads"
REQUIRED_USE="?? ( openmp threads )"
RDEPEND="
dev-libs/jemalloc
boost? ( dev-libs/boost )"
DEPEND="${RDEPEND}"
CMAKE_BUILD_TYPE=Release
pkg_pretend() {
if use openmp && [[ ${MERGE_TYPE} != binary ]]; then
if [[ $(tc-getCC) == *gcc ]] && ! tc-has-openmp; then
ewarn "OpenMP is not available in your current selected gcc"
die "need openmp capable gcc"
fi
fi
}
src_configure() {
local mycmakeargs=(
-DCMAKE_INSTALL_PREFIX:PATH="${EPREFIX}"/usr
$(cmake-utils_use_with boost)
$(cmake-utils_use_with openmp)
)
if use threads; then
mycmakeargs+=(
-DWITH_TCMALLOC:BOOL=ON
-DWITH_PTHREAD:BOOL=ON
-DWITH_SYMENGINE_THREAD_SAFE:BOOL=ON
)
fi
cmake-utils_src_configure
}
|