From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 613E3138359 for ; Tue, 21 Jul 2020 15:50:48 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 97C41E09A2; Tue, 21 Jul 2020 15:50:47 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 73AF0E09A2 for ; Tue, 21 Jul 2020 15:50:47 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 8332E34F1DC for ; Tue, 21 Jul 2020 15:50:45 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id B074B2ED for ; Tue, 21 Jul 2020 15:50:28 +0000 (UTC) From: "Andreas Sturmlechner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Andreas Sturmlechner" Message-ID: <1595346612.d402f6a2790e3383890aefc340ff7e0b96cee949.asturm@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-cpp/eigen/, dev-cpp/eigen/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-cpp/eigen/eigen-3.3.7-r1.ebuild dev-cpp/eigen/files/eigen-3.3.7-gentoo-cmake.patch X-VCS-Directories: dev-cpp/eigen/ dev-cpp/eigen/files/ X-VCS-Committer: asturm X-VCS-Committer-Name: Andreas Sturmlechner X-VCS-Revision: d402f6a2790e3383890aefc340ff7e0b96cee949 X-VCS-Branch: master Date: Tue, 21 Jul 2020 15:50:28 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 0ffa1a46-1368-479a-8a9f-694317bf34f7 X-Archives-Hash: ed459e395983a268d69951e12601ad79 commit: d402f6a2790e3383890aefc340ff7e0b96cee949 Author: Andreas Sturmlechner gentoo org> AuthorDate: Tue Jul 21 13:21:45 2020 +0000 Commit: Andreas Sturmlechner gentoo org> CommitDate: Tue Jul 21 15:50:12 2020 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d402f6a2 dev-cpp/eigen: EAPI-7 bump, switch to cmake.eclass - Update HOMEPAGE - Drop IUSE="c++11", build was broken anyway with it disabled - Drop obsolete slot 0 blocker - Sort dependencies - Drop useless src_unpack(), just define ${S} instead - Properly configure CMAKEPACKAGE_INSTALL_DIR instead of manual doins - configure in src_configure, compile in src_compile, drop src_test() - Drop obsolete -g2 removal - Consolidate and improve conditional !test seds - Replace CMAKE_BUILD_TYPE override sed with patch - Change FindEigen3.cmake module install path Package-Manager: Portage-3.0.0, Repoman-2.3.23 Signed-off-by: Andreas Sturmlechner gentoo.org> dev-cpp/eigen/eigen-3.3.7-r1.ebuild | 100 +++++++++++++++++++++ dev-cpp/eigen/files/eigen-3.3.7-gentoo-cmake.patch | 24 +++++ 2 files changed, 124 insertions(+) diff --git a/dev-cpp/eigen/eigen-3.3.7-r1.ebuild b/dev-cpp/eigen/eigen-3.3.7-r1.ebuild new file mode 100644 index 00000000000..ed987bda82b --- /dev/null +++ b/dev-cpp/eigen/eigen-3.3.7-r1.ebuild @@ -0,0 +1,100 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +FORTRAN_NEEDED="test" +inherit cmake cuda fortran-2 + +DESCRIPTION="C++ template library for linear algebra" +HOMEPAGE="http://eigen.tuxfamily.org/index.php?title=Main_Page" +SRC_URI="https://bitbucket.org/eigen/eigen/get/${PV}.tar.bz2 -> ${P}.tar.bz2" + +LICENSE="MPL-2.0" +SLOT="3" +KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux" +IUSE="cpu_flags_arm_neon cpu_flags_ppc_altivec cpu_flags_ppc_vsx cuda debug doc openmp test" #zvector + +RESTRICT="!test? ( test )" + +BDEPEND=" + doc? ( + app-doc/doxygen[dot] + dev-texlive/texlive-bibtexextra + dev-texlive/texlive-fontsextra + dev-texlive/texlive-fontutils + dev-texlive/texlive-latex + dev-texlive/texlive-latexextra + ) + test? ( virtual/pkgconfig ) +" +DEPEND=" + cuda? ( dev-util/nvidia-cuda-toolkit ) + 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/scotch + sci-libs/spqr + sci-libs/superlu + sci-libs/umfpack + virtual/opengl + ) +" +# Missing: +# METIS-5 +# GOOGLEHASH + +S="${WORKDIR}/${PN}-${PN}-323c052e1731" + +PATCHES=( "${FILESDIR}"/${P}-gentoo-cmake.patch ) + +src_prepare() { + cmake_src_prepare + + cmake_comment_add_subdirectory demos + + if ! use test; then + sed -e "/add_subdirectory(test/s/^/#DONOTCOMPILE /g" \ + -e "/add_subdirectory(blas/s/^/#DONOTCOMPILE /g" \ + -e "/add_subdirectory(lapack/s/^/#DONOTCOMPILE /g" \ + -i CMakeLists.txt || die + fi + + use cuda && cuda_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DCMAKEPACKAGE_INSTALL_DIR="${EPREFIX}"/usr/$(get_libdir)/cmake/${PN}${SLOT} + ) + use test && mycmakeargs+=( + -DEIGEN_TEST_CXX11=ON + -DEIGEN_TEST_NOQT=ON + -DEIGEN_TEST_ALTIVEC=$(usex cpu_flags_ppc_altivec) + -DEIGEN_TEST_CUDA=$(usex cuda) + -DEIGEN_TEST_OPENMP=$(usex openmp) + -DEIGEN_TEST_NEON64=$(usex cpu_flags_arm_neon) + -DEIGEN_TEST_VSX=$(usex cpu_flags_ppc_vsx) + ) + cmake_src_configure +} + +src_compile() { + cmake_src_compile + use doc && cmake_src_compile doc + if use test; then + cmake_src_compile blas + cmake_src_compile buildtests + fi +} + +src_install() { + use doc && local HTML_DOCS=( "${BUILD_DIR}"/doc/html/. ) + cmake_src_install +} diff --git a/dev-cpp/eigen/files/eigen-3.3.7-gentoo-cmake.patch b/dev-cpp/eigen/files/eigen-3.3.7-gentoo-cmake.patch new file mode 100644 index 00000000000..0389cd3b933 --- /dev/null +++ b/dev-cpp/eigen/files/eigen-3.3.7-gentoo-cmake.patch @@ -0,0 +1,24 @@ +Let us properly override with CMAKE_BUILD_TYPE=Gentoo + +--- a/CMakeLists.txt 2018-12-11 18:57:55.000000000 +0100 ++++ b/CMakeLists.txt 2020-07-21 16:43:33.467680534 +0200 +@@ -14,18 +14,7 @@ + set(Eigen_BINARY_DIR ${Eigen3_BINARY_DIR}) + + # guard against bad build-type strings +- +-if (NOT CMAKE_BUILD_TYPE) +- set(CMAKE_BUILD_TYPE "Release") +-endif() +- +-string(TOLOWER "${CMAKE_BUILD_TYPE}" cmake_build_type_tolower) +-if( NOT cmake_build_type_tolower STREQUAL "debug" +- AND NOT cmake_build_type_tolower STREQUAL "release" +- AND NOT cmake_build_type_tolower STREQUAL "relwithdebinfo") +- message(FATAL_ERROR "Unknown build type \"${CMAKE_BUILD_TYPE}\". Allowed values are Debug, Release, RelWithDebInfo (case-insensitive).") +-endif() +- ++# yeah no. + + ############################################################################# + # retrieve version infomation #