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

EAPI=8

# ebuild generated by hackport 0.8.5.1.9999
#hackport: flags: example:examples

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

DESCRIPTION="OAuth 2.0 authentication plugins"
HOMEPAGE="https://github.com/freckle/yesod-auth-oauth2"

LICENSE="MIT"
SLOT="0/${PV}"
KEYWORDS="~amd64"
IUSE="examples"

RDEPEND=">=dev-haskell/aeson-0.6:=[profile?]
	>=dev-haskell/cryptonite-0.25:=[profile?]
	>=dev-haskell/errors-2.3.0:=[profile?]
	>=dev-haskell/hoauth2-1.11.0:=[profile?]
	>=dev-haskell/http-client-0.4.0:=[profile?]
	>=dev-haskell/http-conduit-2.0:=[profile?]
	>=dev-haskell/http-types-0.8:=[profile?]
	>=dev-haskell/memory-0.14.18:=[profile?]
	>=dev-haskell/microlens-0.4.10:=[profile?]
	>=dev-haskell/safe-exceptions-0.1.7.0:=[profile?]
	>=dev-haskell/text-0.7:=[profile?]
	>=dev-haskell/unliftio-0.2.12:=[profile?]
	>=dev-haskell/uri-bytestring-0.3.2.2:=[profile?]
	>=dev-haskell/yesod-auth-1.6.0:=[profile?]
	>=dev-haskell/yesod-core-1.6.0:=[profile?]
	>=dev-lang/ghc-9.0.2:=
	examples? ( >=dev-haskell/aeson-pretty-0.8.8:=[profile?]
			>=dev-haskell/load-env-0.2.1.0:=[profile?]
			>=dev-haskell/warp-3.3.5:=[profile?]
			>=dev-haskell/yesod-1.6.0.1:=[profile?] )
"
DEPEND="${RDEPEND}
	>=dev-haskell/cabal-3.4.1.0
	test? ( >=dev-haskell/hspec-2.7.1 )
"

src_configure() {
	haskell-cabal_src_configure \
		$(cabal_flag examples example)
}