forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Closes: https://bugs.gentoo.org/673128 Package-Manager: Portage-2.3.52, Repoman-2.3.12 Signed-off-by: Andreas Sturmlechner <[email protected]>
- Loading branch information
Showing
2 changed files
with
100 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
DIST eigen-3.2.8.tar.bz2 1161201 BLAKE2B 35bace5138f601e73d56412e87bf591ef2f96778050b0a2a4fc8f1e75f02498fb4eb80bf79988dd4bd6b985945a122d44581ccedd925f398f7d282790da06385 SHA512 53c27ba530c985dfef52188e03273eeef33abbc67e3f150cacd3371c8b9ddbd399228730595821c4c56c061d109cf509266c1dab2b8a7c730902cbd6fb18c100 | ||
DIST eigen-3.3.5.tar.bz2 1663467 BLAKE2B 7f4b6339f8cea815004057361734e53129b5bde45c9c310eab87f0aa20da90e46dd67359e669f8b36477339df7bd7c8bd8eb18baaf0f1a779372ec3623c50aca SHA512 740ed41862c1e422a751b205513754e9c7bd04cc8ad4e3b08e2ccd1c1d30dea43a90896bc8eecd0cb4253b4adf803a814ddd48d6166fb5a53f507cf3e6940a38 | ||
DIST eigen-3.3.7.tar.bz2 1665168 BLAKE2B 544d35d1c7a4125affa094c6aa372c2aeca4e99bc60c496ff393d538c1c467b454491a772121450e3a1a43a582d073b4b7584918354d0b9175121fde88947c4b SHA512 c12bfd034d0a1112bf2df3f773ad98f36b2b53fbbfceac5f143ee1793322746fb8a6546d7db7da2a1000da6a535bd8cea0c4125b549afc90a6570743b02dcf3d |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,99 @@ | ||
# Copyright 1999-2018 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=6 | ||
|
||
FORTRAN_NEEDED="test" | ||
inherit cmake-utils cuda fortran-2 | ||
|
||
DESCRIPTION="C++ template library for linear algebra" | ||
HOMEPAGE="http://eigen.tuxfamily.org/" | ||
SRC_URI="https://bitbucket.org/eigen/eigen/get/${PV}.tar.bz2 -> ${P}.tar.bz2" | ||
|
||
LICENSE="MPL-2.0" | ||
SLOT="3" | ||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux" | ||
IUSE="altivec c++11 cuda debug doc neon openmp test" #zvector vsx | ||
RESTRICT="!test? ( test )" | ||
|
||
RDEPEND="!dev-cpp/eigen:0" | ||
DEPEND=" | ||
doc? ( app-doc/doxygen[dot,latex] ) | ||
test? ( | ||
dev-libs/gmp:0 | ||
dev-libs/mpfr:0 | ||
media-libs/freeglut | ||
media-libs/glew | ||
sci-libs/adolc[sparse] | ||
sci-libs/cholmod | ||
sci-libs/fftw:3.0 | ||
sci-libs/pastix | ||
sci-libs/umfpack | ||
sci-libs/scotch | ||
sci-libs/spqr | ||
sci-libs/superlu | ||
virtual/opengl | ||
virtual/pkgconfig | ||
cuda? ( dev-util/nvidia-cuda-toolkit ) | ||
) | ||
" | ||
# Missing: | ||
# METIS-5 | ||
# GOOGLEHASH | ||
|
||
src_unpack() { | ||
default | ||
mv ${PN}* ${P} || die | ||
} | ||
|
||
src_prepare() { | ||
cmake-utils_src_prepare | ||
|
||
sed -e 's:-g2::g' \ | ||
-i cmake/EigenConfigureTesting.cmake || die | ||
|
||
sed -e "/add_subdirectory(demos/d" \ | ||
-i CMakeLists.txt || die | ||
|
||
if ! use test; then | ||
sed -e "/add_subdirectory(test/d" \ | ||
-i CMakeLists.txt || die | ||
|
||
sed -e "/add_subdirectory(blas/d" \ | ||
-e "/add_subdirectory(lapack/d" \ | ||
-i CMakeLists.txt || die | ||
fi | ||
sed -e "/Unknown build type/d" \ | ||
-i CMakeLists.txt || die | ||
|
||
use cuda && cuda_src_prepare | ||
} | ||
|
||
src_compile() { | ||
cmake-utils_src_compile | ||
use doc && cmake-utils_src_compile doc | ||
} | ||
|
||
src_test() { | ||
local mycmakeargs=( | ||
-DEIGEN_TEST_NOQT=ON | ||
-DEIGEN_TEST_ALTIVEC="$(usex altivec)" | ||
-DEIGEN_TEST_CXX11="$(usex c++11)" | ||
-DEIGEN_TEST_CUDA="$(usex cuda)" | ||
-DEIGEN_TEST_OPENMP="$(usex openmp)" | ||
-DEIGEN_TEST_NEON64="$(usex neon)" | ||
) | ||
cmake-utils_src_configure | ||
cmake-utils_src_compile blas | ||
cmake-utils_src_compile buildtests | ||
cmake-utils_src_test | ||
} | ||
|
||
src_install() { | ||
use doc && local HTML_DOCS=( "${BUILD_DIR}"/doc/html/. ) | ||
cmake-utils_src_install | ||
|
||
# Debian installs it and some projects started using it. | ||
insinto /usr/share/cmake/Modules/ | ||
doins "${S}/cmake/FindEigen3.cmake" | ||
} |