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

EAPI=6

# ebuild generated by hackport 0.5.6.9999

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

DESCRIPTION="On-line accumulation of rank-based statistics"
HOMEPAGE="https://github.com/futurice/haskell-tdigest#readme"
SRC_URI="mirror://hackage/packages/archive/${PN}/${PV}/${P}.tar.gz"

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

RDEPEND=">=dev-haskell/base-compat-0.10.1:=[profile?] <dev-haskell/base-compat-0.11:=[profile?]
	>=dev-haskell/reducers-3.12.2:=[profile?] <dev-haskell/reducers-3.13:=[profile?]
	>=dev-haskell/semigroupoids-5.2.2:=[profile?]
	>=dev-haskell/semigroups-0.18.4:=[profile?]
	>=dev-haskell/vector-0.12.0.1:=[profile?] <dev-haskell/vector-0.13:=[profile?]
	>=dev-haskell/vector-algorithms-0.7.0.1:=[profile?]
	>=dev-lang/ghc-7.8.2:=
"
DEPEND="${RDEPEND}
	>=dev-haskell/cabal-1.18.1.3
	>=dev-haskell/cabal-doctest-1.0.6 <dev-haskell/cabal-doctest-1.1
	test? ( >=dev-haskell/doctest-0.11.1 <dev-haskell/doctest-0.17
		>=dev-haskell/tasty-0.11.0.4
		>=dev-haskell/tasty-quickcheck-0.8.4 <dev-haskell/tasty-quickcheck-0.11 )
"

src_prepare() {
	default

	cabal_chdeps \
		'base                >=4.7      && <4.12' 'base                >=4.7' \
		'semigroupoids       >=5.2.2    && <5.4' 'semigroupoids       >=5.2.2' \
		'semigroups          >=0.18.4   && <0.19' 'semigroups          >=0.18.4' \
		'vector-algorithms   >=0.7.0.1  && <0.8' 'vector-algorithms   >=0.7.0.1' \
		'tasty            >=0.11.0.4 && <1.2' 'tasty            >=0.11.0.4'
}