commit:     eb5d6d5e83c9ce811323f665d72f42c69cc36087
Author:     Tiziano Müller <dev-zero <AT> gentoo <DOT> org>
AuthorDate: Thu Mar 17 14:45:31 2016 +0000
Commit:     Tiziano Müller <dev-zero <AT> gentoo <DOT> org>
CommitDate: Thu Mar 17 14:45:31 2016 +0000
URL:        https://gitweb.gentoo.org/dev/dev-zero.git/commit/?id=eb5d6d5e

sci-chemistry/cp2k: fix some issues with the openmp flag

 sci-chemistry/cp2k/cp2k-3.0.ebuild | 9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/sci-chemistry/cp2k/cp2k-3.0.ebuild 
b/sci-chemistry/cp2k/cp2k-3.0.ebuild
index 1d2218c..c589efb 100644
--- a/sci-chemistry/cp2k/cp2k-3.0.ebuild
+++ b/sci-chemistry/cp2k/cp2k-3.0.ebuild
@@ -18,10 +18,11 @@ SRC_URI="mirror://sourceforge/${PN}/${P}.tar.bz2"
 LICENSE="GPL-2"
 SLOT="0"
 KEYWORDS="~amd64"
-IUSE="+fftw openmp"
+IUSE="+fftw +openmp"
 
 RDEPEND="virtual/blas
-       fftw? ( sci-libs/fftw:3.0=[fortran,openmp?,threads] )"
+       fftw? ( openmp? ( sci-libs/fftw:3.0=[fortran,openmp] )
+               !openmp? ( sci-libs/fftw:3.0=[fortran,threads] ) )"
 DEPEND="${RDEPEND}
        virtual/pkgconfig
        ${PYTHON_DEPS}"
@@ -41,9 +42,9 @@ src_configure() {
 
        if use fftw ; then
                if use openmp ; then
-                       libs+=($(pkg-config --libs fftw3))
-               else
                        libs+=($(pkg-config --libs fftw3_omp))
+               else
+                       libs+=($(pkg-config --libs fftw3_threads))
                fi
                defines+=(-D__FFTW3)
                echo ${defines[*]}

Reply via email to