From: "Martin Mokrejs" <mmokrejs@fold.natur.cuni.cz>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/sci:master commit in: sci-biology/megahit/
Date: Tue, 10 Jan 2017 01:00:48 +0000 (UTC) [thread overview]
Message-ID: <1484010037.cbe0d928b5c7dbe615e129da4d5079f46324aef8.mmokrejs@gentoo> (raw)
commit: cbe0d928b5c7dbe615e129da4d5079f46324aef8
Author: Martin Mokrejš <mmokrejs <AT> fold <DOT> natur <DOT> cuni <DOT> cz>
AuthorDate: Tue Jan 10 01:00:37 2017 +0000
Commit: Martin Mokrejs <mmokrejs <AT> fold <DOT> natur <DOT> cuni <DOT> cz>
CommitDate: Tue Jan 10 01:00:37 2017 +0000
URL: https://gitweb.gentoo.org/proj/sci.git/commit/?id=cbe0d928
sci-biology/megahit: distinguish openmp compiler switches
Package-Manager: Portage-2.3.3, Repoman-2.3.1
sci-biology/megahit/megahit-9999.ebuild | 14 +++++++++++++-
1 file changed, 13 insertions(+), 1 deletion(-)
diff --git a/sci-biology/megahit/megahit-9999.ebuild b/sci-biology/megahit/megahit-9999.ebuild
index def7fd6..a23d2c2 100644
--- a/sci-biology/megahit/megahit-9999.ebuild
+++ b/sci-biology/megahit/megahit-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2016 Gentoo Foundation
+# Copyright 1999-2017 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$
@@ -23,8 +23,20 @@ RDEPEND="${DEPEND}
# use make use_gpu=1 to compile it and turn on --use-gpu to activate GPU acceleration when running megahit
+pkg_setup() {
+ use openmp && ! tc-has-openmp && die "Please switch to an openmp compatible compiler"
+}
+
src_prepare(){
default
+ if [[ $(tc-getCXX) =~ g++ ]]; then
+ local eopenmp=-fopenmp
+ elif [[ $(tc-getCXX) =~ cxx ]]; then
+ local eopenmp=-openmp
+ sed -e "s#-fopenmp#-openmp#" -i Makefile || die
+ else
+ elog "Cannot detect compiler type so not setting openmp support"
+ fi
sed -e "s#^CXXFLAGS = -g -O2#CXXFLAGS = ${CFLAGS}#" -i Makefile || die
}
next reply other threads:[~2017-01-10 1:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-10 1:00 Martin Mokrejs [this message]
-- strict thread matches above, loose matches on Subject: below --
2021-03-06 12:17 [gentoo-commits] proj/sci:master commit in: sci-biology/megahit/ Andrew Ammerlaan
2018-04-22 22:34 Martin Mokrejs
2016-04-10 21:23 Martin Mokrejs
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1484010037.cbe0d928b5c7dbe615e129da4d5079f46324aef8.mmokrejs@gentoo \
--to=mmokrejs@fold.natur.cuni.cz \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox