diff options
author | Sergei Trofimovich <slyfox@gentoo.org> | 2014-01-19 08:23:36 +0000 |
---|---|---|
committer | Sergei Trofimovich <slyfox@gentoo.org> | 2014-01-19 08:23:36 +0000 |
commit | 8c13357964c059621b04bdf3245b27d96dfbe839 (patch) | |
tree | eb5c4d89c20157778ebb053d13cae6f7061456e9 /eclass/ghc-package.eclass | |
parent | Version bump. (diff) | |
download | gentoo-2-8c13357964c059621b04bdf3245b27d96dfbe839.tar.gz gentoo-2-8c13357964c059621b04bdf3245b27d96dfbe839.tar.bz2 gentoo-2-8c13357964c059621b04bdf3245b27d96dfbe839.zip |
Add 'ghc-supports-interpreter' helper to detect interpreter support.
Diffstat (limited to 'eclass/ghc-package.eclass')
-rw-r--r-- | eclass/ghc-package.eclass | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/eclass/ghc-package.eclass b/eclass/ghc-package.eclass index 3a9d3956fa19..ec6072d54853 100644 --- a/eclass/ghc-package.eclass +++ b/eclass/ghc-package.eclass @@ -1,6 +1,6 @@ -# Copyright 1999-2013 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/eclass/ghc-package.eclass,v 1.37 2013/05/11 12:46:32 slyfox Exp $ +# $Header: /var/cvsroot/gentoo-x86/eclass/ghc-package.eclass,v 1.38 2014/01/19 08:23:36 slyfox Exp $ # @ECLASS: ghc-package.eclass # @MAINTAINER: @@ -111,11 +111,18 @@ ghc-supports-smp() { # @FUNCTION: ghc-supports-dynamic-by-default # @DESCRIPTION: -# checks if ghc link against shared haskell libraries by default +# checks if ghc links against shared haskell libraries by default ghc-supports-dynamic-by-default() { $(ghc-getghc) --info | grep "Dynamic by default" | grep -q "YES" } +# @FUNCTION: ghc-supports-interpreter +# @DESCRIPTION: +# checks if ghc has interpreter mode (aka GHCi) +# It usually means that ghc supports for template haskell. +ghc-supports-interpreter() { + $(ghc-getghc) --info | grep "Have interpreter" | grep -q "YES" +} # @FUNCTION: ghc-extractportageversion # @DESCRIPTION: |