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

EAPI=8

# ebuild generated by hackport 0.6.3

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

DESCRIPTION="JSON Object Signing and Encryption Library"
HOMEPAGE="https://github.com/tekul/jose-jwt"
SRC_URI="https://hackage.haskell.org/package/${P}/${P}.tar.gz"

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

RESTRICT=test # Ambiguous ‘Data.Vector’: AC-Vector-Fancy-2.4.0 vector-0.12.0.1

RDEPEND=">=dev-haskell/aeson-0.8.0.2:=[profile?]
	>=dev-haskell/attoparsec-0.12.0.0:=[profile?]
	>=dev-haskell/cereal-0.4:=[profile?]
	>=dev-haskell/cryptonite-0.19:=[profile?]
	dev-haskell/either:=[profile?]
	>=dev-haskell/memory-0.10:=[profile?]
	>=dev-haskell/mtl-2.1.3.1:=[profile?]
	>=dev-haskell/text-0.11:=[profile?]
	>=dev-haskell/transformers-compat-0.4:=[profile?]
	>=dev-haskell/unordered-containers-0.2:=[profile?]
	>=dev-haskell/vector-0.10:=[profile?]
	>=dev-lang/ghc-7.8.2:=
"
DEPEND="${RDEPEND}
	>=dev-haskell/cabal-1.16
	test? ( dev-haskell/cryptonite
		>=dev-haskell/either-4.0
		>=dev-haskell/hspec-1.6
		>=dev-haskell/hunit-1.2
		>=dev-haskell/quickcheck-2.4
		doctest? ( >=dev-haskell/doctest-0.9.11 ) )
"

src_configure() {
	haskell-cabal_src_configure \
		$(cabal_flag doctest doctest)
}