# Copyright 1999-2025 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

# ebuild generated by hackport 0.9.0.0.9999

CABAL_FEATURES="lib profile haddock hoogle hscolour"
inherit haskell-cabal

DESCRIPTION="The GHC API, decoupled from GHC versions"
HOMEPAGE="https://github.com/digital-asset/ghc-lib"

LICENSE="BSD"
SLOT="0/${PV}"
KEYWORDS="~amd64"
IUSE="+threaded-rts"

#dev-haskell/ghc-internal:=[profile?]
RDEPEND="
	dev-haskell/parsec:=[profile?]
	>=dev-lang/ghc-9.10.1:=
"
DEPEND="${RDEPEND}
	>=dev-haskell/alex-3.1
	>=dev-haskell/cabal-3.12.0.0
	|| ( ( >=dev-haskell/happy-1.20 <dev-haskell/happy-1.21 )
		|| ( ( >=dev-haskell/happy-2.1.2 <dev-haskell/happy-2.2 )
			~dev-haskell/happy-2.0.2 ) )
"

src_configure() {
	haskell-cabal_src_configure \
		$(cabal_flag threaded-rts threaded-rts)
}