# Maintainer: Celeste <cielesti@protonmail.com>
maintainer="Celeste <cielesti@protonmail.com>"
pkgname=ocaml5-integers
pkgver=0.7.0
pkgrel=0
pkgdesc="Various signed and unsigned integer types for OCaml"
url="https://github.com/ocamllabs/ocaml-integers"
arch="all"
license="MIT"
depends="ocaml5-compiler-libs"
makedepends="dune ocaml5"
subpackages="$pkgname-doc"
source="https://github.com/ocamllabs/ocaml-integers/archive/$pkgver/ocaml-integers-$pkgver.tar.gz
	remove-stdlib-shims.patch
	"
builddir="$srcdir/ocaml-integers-$pkgver"

build() {
	dune build --release --verbose
}

check() {
	dune runtest --build-dir=.testenv --verbose
}

package() {
	dune install --destdir="$pkgdir"

	mv -v "$pkgdir"/usr/share/doc/integers "$pkgdir"/usr/share/doc/$pkgname
}

sha512sums="
f71bf73af2e4e0dd5bd039b28bce1fdabfb199ada1836d694814aa6d0c1c2d205531fbfc05581082b2dbb1e9cc0948e594915d5ad6a1cfa1dbffa9e44a7a7450  ocaml-integers-0.7.0.tar.gz
e5c7bf6444ae6ee4935c3ecffacfaf1001506efd6669fa5921c6c0d8023d5e735a24c5b04a1074b9b259066314b5901e9253b1c3d08dcb0d0535056ec9ec8856  remove-stdlib-shims.patch
"
